code generator that automatically switches endianness
This commit is contained in:
parent
e603c154b9
commit
5532c4f5a8
1 changed files with 291 additions and 34 deletions
|
|
@ -1,17 +1,19 @@
|
|||
using System.Runtime.InteropServices;
|
||||
using EndiannessSourceGenerator;
|
||||
|
||||
namespace DisplayCommands.Internals;
|
||||
|
||||
[StructEndianness(IsLittleEndian = false)]
|
||||
[StructLayout(LayoutKind.Sequential, Pack = 16, Size = 10)]
|
||||
internal struct HeaderBitmap
|
||||
internal partial struct HeaderBitmap
|
||||
{
|
||||
public DisplayCommand Command;
|
||||
private ushort _command;
|
||||
|
||||
public ushort Offset;
|
||||
private ushort _offset;
|
||||
|
||||
public ushort Length;
|
||||
private ushort _length;
|
||||
|
||||
public DisplaySubCommand SubCommand;
|
||||
private ushort _subCommand;
|
||||
|
||||
public ushort Reserved;
|
||||
}
|
||||
private ushort _reserved;
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue