extended by BaseEmitter, BitmapText, Backdrop, Tilemap, BaseGraphicList, ColoredRect, Image, NineSlice
Base class for graphics type. Do not use this directly, instead use the classes in haxepunk.graphics.
active : Bool
If the graphic should update.
alpha : Float
Change the opacity of the Image, a value from 0 to 1.
Optional blend mode to use when drawing this image. Use constants from the haxepunk.utils.BlendMode class.
Optional rectangle to clip the portion of this graphic that will be drawn.
flexibleLayer : Bool
If true, this graphic may sometimes "fall through" other textures to reduce the number of draw calls. This can affect layering.
originX : Float
X origin of the graphic, determines transformation point. Defaults to top-left corner.
originY : Float
Y origin of the graphic, determines transformation point. Defaults to top-left corner.
pixelSnapping : Bool
Whether this graphic will be snapped to the nearest whole number pixel
position when rendering. If pixelSnapping is set to
true on the
Camera, snapping will occur regardless of this setting. Some graphics
like Tilemap set this to true by default.
relative : Bool
If the graphic should render at its position relative to its parent Entity's position.
scrollX : Float
X scrollfactor, effects how much the camera offsets the drawn graphic. Can be used for parallax effect, eg. Set to 0 to follow the camera, 0.5 to move at half-speed of the camera, or 1 (default) to stay still.
scrollY : Float
Y scrollfactor, effects how much the camera offsets the drawn graphic. Can be used for parallax effect, eg. Set to 0 to follow the camera, 0.5 to move at half-speed of the camera, or 1 (default) to stay still.
smooth : Bool
If the image should be drawn transformed with pixel smoothing. This will affect drawing performance, but look less pixelly.
Default value: false if HXP.stage.quality is LOW, true otherwise.
visible : Bool
If the graphic should render.
x : Float
y : Float
Renders the graphic, taking extra care to snap pixel locations and lengths to whole number positions. Not all graphics need a separate pixelPerfectRender implementation; by default this will just call render.
The position to draw the graphic.
The camera offset.