I am trying to get a water filling effect in a circle. For half filled (slider value =50), I can do this . However I am unable to figure out how to do that for any other slider value. :
If there is no solution I will use SD liquid progress but I want to avoid using proprietary code.
water fill 50% of circle:
Dim bc,bc2 As BitmapCreator
bc.Initialize(ImageView1.Width, ImageView1.Height)
bc2.Initialize(bc.mWidth, bc.mHeight)
bc2.FillGradient(Array As Int(xui.Color_ARGB(0,255,255,255), xui.Color_Blue), bc2.TargetRect, "BOTTOM_TOP")
Dim Brush2 As BCBrush = bc.CreateBrushFromBitmapCreator(bc2)
Do While True
Brush2.SrcOffsetY = Brush2.SrcOffsetY - 1dip
bc.DrawArc2(ImageView1.Width/2,ImageView1.Height/2,ImageView1.Width/2-2,Brush2, True, 1dip,0,180)
bc.SetBitmapToImageView(bc.Bitmap, ImageView1)
Sleep(15)
Loop