RatioScaleMode is a scaling mode which maintains the game's aspect ratio. When you shrink or grow the window, the width and height of the game will adjust, either scaling the game or adding black bars as needed.

This is the default scaling mode used by HaxeFlixel.


@:value({ fillScreen : false })new(fillScreen:Bool = false)



Whether to cut the excess side to fill the screen or always display everything.

Inherited Variables

Defined by BaseScaleMode

@:value(CENTER)horizontalAlign:FlxHorizontalAlign = CENTER

read onlyoffset:FlxPoint

read onlyscale:FlxPoint

@:value(CENTER)verticalAlign:FlxVerticalAlign = CENTER

Inherited Methods

Defined by BaseScaleMode

onMeasure(Width:Int, Height:Int):Void