infinite map

This commit is contained in:
Vinzenz Schroeter 2024-04-12 18:32:10 +02:00
parent 7213318838
commit 461a9139c2
20 changed files with 101 additions and 69 deletions

View file

@ -8,6 +8,7 @@ public sealed class Cp437Grid(ushort width, ushort height)
private readonly ByteGrid _byteGrid = new(width, height);
public ushort Height { get; } = height;
public ushort Width { get; } = width;
internal Memory<byte> Data => _byteGrid.Data;

View file

@ -6,9 +6,9 @@ public interface IDisplayConnection
ValueTask SendCp437DataAsync(ushort x, ushort y, Cp437Grid grid);
ValueTask SendCharBrightnessAsync(ushort x, ushort y, ByteGrid luma);
ValueTask SendBrightnessAsync(byte brightness);
ValueTask SendCharBrightnessAsync(ushort x, ushort y, ByteGrid luma);
ValueTask SendHardResetAsync();

View file

@ -1,6 +1,6 @@
namespace DisplayCommands.Internals;
internal enum DisplayCommand: ushort
internal enum DisplayCommand : ushort
{
Clear = 0x0002,
Cp437Data = 0x0003,
@ -8,10 +8,10 @@ internal enum DisplayCommand: ushort
Brightness = 0x0007,
HardReset = 0x000b,
FadeOut = 0x000d,
BitmapLegacy = 0x0010,
[Obsolete("ignored by display code")] BitmapLegacy = 0x0010,
BitmapLinear = 0x0012,
BitmapLinearWin = 0x0013,
BitmapLinearAnd = 0x0014,
BitmapLinearOr = 0x0015,
BitmapLinearXor = 0x0016,
}
}