mirror of
https://github.com/sampletext32/ParkanPlayground.git
synced 2026-08-15 15:07:48 +04:00
push
This commit is contained in:
@@ -29,6 +29,14 @@ public static class Extensions
|
||||
return BinaryPrimitives.ReadUInt16LittleEndian(buf);
|
||||
}
|
||||
|
||||
public static short ReadInt16LittleEndian(this Stream fs)
|
||||
{
|
||||
Span<byte> buf = stackalloc byte[2];
|
||||
fs.ReadExactly(buf);
|
||||
|
||||
return BinaryPrimitives.ReadInt16LittleEndian(buf);
|
||||
}
|
||||
|
||||
public static float ReadFloatLittleEndian(this Stream fs)
|
||||
{
|
||||
Span<byte> buf = stackalloc byte[4];
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
public record Quaternion(float X, float Y, float Z, float W);
|
||||
|
||||
public record UShortQuaternion(ushort X, ushort Y, ushort Z, ushort W)
|
||||
public record UShortQuaternion(short W, short X, short Y, short Z)
|
||||
{
|
||||
public Quaternion ToRegular()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user