diff --git a/Assets/UniGLTF/Runtime/Extensions/glTFExtensions.cs b/Assets/UniGLTF/Runtime/Extensions/glTFExtensions.cs index 674801c6d..b5bfc72f6 100644 --- a/Assets/UniGLTF/Runtime/Extensions/glTFExtensions.cs +++ b/Assets/UniGLTF/Runtime/Extensions/glTFExtensions.cs @@ -1,46 +1,11 @@ using System; -using System.Linq; using System.Collections.Generic; -using System.Runtime.InteropServices; using UnityEngine; using System.IO; using UniJSON; namespace UniGLTF { - [Serializable, StructLayout(LayoutKind.Sequential, Pack = 1)] - public struct Byte4 - { - public readonly byte x; - public readonly byte y; - public readonly byte z; - public readonly byte w; - public Byte4(byte _x, byte _y, byte _z, byte _w) - { - x = _x; - y = _y; - z = _z; - w = _w; - } - } - - [Serializable, StructLayout(LayoutKind.Sequential, Pack = 1)] - public struct UShort4 - { - public readonly ushort x; - public readonly ushort y; - public readonly ushort z; - public readonly ushort w; - - public UShort4(ushort _x, ushort _y, ushort _z, ushort _w) - { - x = _x; - y = _y; - z = _z; - w = _w; - } - } - public static class glTFExtensions { struct ComponentVec @@ -239,14 +204,6 @@ namespace UniGLTF return index; } - - - - - - - - static Utf8String s_extensions = Utf8String.From("extensions"); static bool UsedExtension(this glTF self, string key) diff --git a/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs b/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs new file mode 100644 index 000000000..7df1446b6 --- /dev/null +++ b/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs @@ -0,0 +1,21 @@ +using System; +using System.Runtime.InteropServices; + +namespace UniGLTF +{ + [Serializable, StructLayout(LayoutKind.Sequential, Pack = 1)] + public struct Byte4 + { + public readonly byte x; + public readonly byte y; + public readonly byte z; + public readonly byte w; + public Byte4(byte _x, byte _y, byte _z, byte _w) + { + x = _x; + y = _y; + z = _z; + w = _w; + } + } +} diff --git a/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs.meta b/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs.meta new file mode 100644 index 000000000..fcbebceec --- /dev/null +++ b/Assets/UniGLTF/Runtime/UniGLTF/IO/Byte4.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7d396586954b6d34a84d9af8638e492e +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs b/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs new file mode 100644 index 000000000..d13c87c93 --- /dev/null +++ b/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs @@ -0,0 +1,22 @@ +using System; +using System.Runtime.InteropServices; + +namespace UniGLTF +{ + [Serializable, StructLayout(LayoutKind.Sequential, Pack = 1)] + public struct UShort4 + { + public readonly ushort x; + public readonly ushort y; + public readonly ushort z; + public readonly ushort w; + + public UShort4(ushort _x, ushort _y, ushort _z, ushort _w) + { + x = _x; + y = _y; + z = _z; + w = _w; + } + } +} diff --git a/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs.meta b/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs.meta new file mode 100644 index 000000000..9c925e07b --- /dev/null +++ b/Assets/UniGLTF/Runtime/UniGLTF/IO/UShort4.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b1f199669bb47f747865a96bcd7bcbfb +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: