Fix ASCII rasterizer scaling for CLI
Signed-off-by: Hans Kokx <hans.d.kokx@gmail.com>
This commit is contained in:
@@ -47,19 +47,21 @@ class ColoredChar {
|
||||
}
|
||||
|
||||
class AsciiRasterizer extends Rasterizer {
|
||||
final AsciiTheme activeTheme = AsciiThemes.blocks;
|
||||
AsciiRasterizer({
|
||||
this.activeTheme = AsciiThemes.blocks,
|
||||
this.aspectMultiplier = 1.0,
|
||||
this.verticalStretch = 1.0,
|
||||
});
|
||||
|
||||
AsciiTheme activeTheme = AsciiThemes.blocks;
|
||||
|
||||
late List<List<ColoredChar>> _screen;
|
||||
late WolfEngine _engine;
|
||||
|
||||
// Terminal characters are usually twice as tall as they are wide.
|
||||
// We override the base multiplier to squish sprites horizontally.
|
||||
@override
|
||||
double get aspectMultiplier => 1.0;
|
||||
|
||||
// Squish the entire 3D projection vertically by 50% to counteract tall terminal fonts
|
||||
final double aspectMultiplier;
|
||||
@override
|
||||
double get verticalStretch => 1.0;
|
||||
final double verticalStretch;
|
||||
|
||||
// Intercept the base render call to initialize our text grid
|
||||
@override
|
||||
|
||||
Reference in New Issue
Block a user