Static variables

@:value([for (i in 32 ... 256) i])staticfontGlyphs:Array<Int> = [for (i in 32 ... 256) i]

Constructor

new()

Variables

color:Color

The color value is used for geometric primitives, images, and text. Remember to set it back to white to draw images unaltered.

Methods

@:value({ clearColor : null, clear : true })begin(clear:Bool = true, ?clearColor:Color):Void

@:value({ color : null })clear(?color:Color):Void

drawCharacters(text:Array<Int>, start:Int, length:Int, x:Float, y:Float):Void

Draw a single line of characters with the current color, font and fontSize properties.

When drawing into rendertargets, you might have to use a different shader than the default one - use the default shader when drawing into a transparent section of your rendertarget - use a shader with alphaBlendSource = BlendOne when drawing into a non-transparent section of your rendertarget

@:value({ strength : 1.0 })drawLine(x1:Float, y1:Float, x2:Float, y2:Float, strength:Float = 1.0):Void

@:value({ strength : 1.0 })drawRect(x:Float, y:Float, width:Float, height:Float, strength:Float = 1.0):Void

drawString(text:String, x:Float, y:Float):Void

Draw a single line of text with the current color, font and fontSize properties.

When drawing into rendertargets, you might have to use a different shader than the default one - use the default shader when drawing into a transparent section of your rendertarget - use a shader with alphaBlendSource = BlendOne when drawing into a non-transparent section of your rendertarget

drawVideo(video:Video, x:Float, y:Float, width:Float, height:Float):Void

fillRect(x:Float, y:Float, width:Float, height:Float):Void

fillTriangle(x1:Float, y1:Float, x2:Float, y2:Float, x3:Float, y3:Float):Void

pushRotation(angle:FastFloat, centerx:FastFloat, centery:FastFloat):Void

rotate(angle:FastFloat, centerx:FastFloat, centery:FastFloat):Void

scissor(x:Int, y:Int, width:Int, height:Int):Void