Category: 2D Overlay
Syntax:
b2dCreateCircle:Int(fill:Int, radius:Int, segments:Int)
Int
Creates circle image (rasterized texture, returns handle for b2dDrawImage).
Takes radius (circle radius in pixels, positive integer), segments (smoothness quality, higher=smoother, 3-128 range), fill (1=filled circle, 0=outline only).
Returns image handle (positive integer, use with b2dDrawImage/b2dSetColor/b2dSetScale/b2dSetRotation, etc), returns 0 on failure.
View detailed documentation online
; Create a smooth filled green circle circle = b2dCreateCircle(50, 32, 1) ; Draw it at screen position with color b2dSetColor(0, 255, 0) b2dDrawImage(circle, 400, 300) ; Can also scale and rotate b2dSetScale(2.0, 2.0) b2dSetRotation(45.0) b2dDrawImage(circle, 600, 300) ; Free when done b2dFreeImage(circle)
BambooBasic © 2026 Michael Denathorn