It should be fast with a minimum amount of calculations. I was thinking of using drawpathrotated to draw paths but I can't get it working. Anyone up for a challenge?
Hi, Everybody! Is It possible in b4a draw a border for panel (with curved corners) in dash-dash or dash-dot style and change style of border dynamically? Thanks for help!
I would like to draw a dashed circle. I have come up with this algorithm which uses initializearc, but it does not feel very efficient. Is there a better way? Dim c As B4XCanvas c.Initialize(xview) ' view to draw on, assume a square Private path As B4XPath Private i As...
I came up with this but I'm not sure it is the most optimized way to do it:
B4X:
Dim p As B4XPath
p.InitializeArc(cx, cy, radius, 0, 15) ' slice measures 15 degrees
For t = 0 To 348 Step 30
cvs.drawpathrotated(p,Colors.Black,False,thickness,t,cx,cy) ' rotate the slice 30 degrees each step
Next
cvs.DrawCircle(cx,cy,radius-(thickness/2),Colors.White,True,0)