Added memory address management
This commit is contained in:
6
BlendFile/ByteArrayExt.cs
Normal file
6
BlendFile/ByteArrayExt.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
namespace BlendFile;
|
||||
|
||||
public static class ByteArrayExt{
|
||||
public static long ToMemAddr(this Byte[] bytes, bool isLittleEndian = true) =>
|
||||
BitConverter.ToInt64(isLittleEndian == BitConverter.IsLittleEndian ? bytes : bytes.Reverse().ToArray(), 0);
|
||||
}
|
||||
Reference in New Issue
Block a user