Private Sub Button1_Click
Dim MeshGradient As B4XMeshGradient
MeshGradient.Initialize
Dim Width As Int = B4XImageView1.mBase.Width
Dim Height As Int = B4XImageView1.mBase.Height
MeshGradient.AddPoint(Width * 0.20, Height * 0.25, RandomColor)
MeshGradient.AddPoint(Width * 0.75, Height * 0.20, RandomColor)
MeshGradient.AddPoint(Width * 0.80, Height * 0.80, RandomColor)
MeshGradient.AddPoint(Width * 0.15, Height * 0.85, RandomColor)
Dim MeshBitmap As B4XBitmap = MeshGradient.Generate(Width, Height)
B4XImageView1.Clear
B4XImageView1.Bitmap = MeshBitmap
B4XImageView1.CornersRadius = 16
B4XImageView1.Update
End Sub