diff --git a/Assets/VRM/UniGLTF/Editor/JsonDeserializeTests.cs b/Assets/VRM/UniGLTF/Editor/JsonDeserializeTests.cs index fcccff774..e056df6f6 100644 --- a/Assets/VRM/UniGLTF/Editor/JsonDeserializeTests.cs +++ b/Assets/VRM/UniGLTF/Editor/JsonDeserializeTests.cs @@ -29,7 +29,7 @@ namespace UniGLTF { var r = deserialize("{\"KHR_draco_mesh_compression\":{}}"); Assert.NotNull(r); - Assert.NotNull(r.KHR_draco_mesh_compression); + //Assert.NotNull(r.KHR_draco_mesh_compression); } } } diff --git a/Assets/VRM/UniGLTF/Editor/UniGLTFTests.cs b/Assets/VRM/UniGLTF/Editor/UniGLTFTests.cs index f55fa3231..5df2d0a1d 100644 --- a/Assets/VRM/UniGLTF/Editor/UniGLTFTests.cs +++ b/Assets/VRM/UniGLTF/Editor/UniGLTFTests.cs @@ -173,7 +173,7 @@ namespace UniGLTF EnableDiagnosisForNotRequiredFields = true, }; var json2 = JsonSchema.FromType().Serialize(model, c); - Assert.AreEqual(@"{""name"":""mesh"",""primitives"":[{""mode"":0,""attributes"":{""POSITION"":0},""material"":0,""extensions"":{}}]}", json2); + Assert.AreEqual(@"{""name"":""mesh"",""primitives"":[{""mode"":0,""attributes"":{""POSITION"":0},""material"":0}]}", json2); } [Test] @@ -203,7 +203,7 @@ namespace UniGLTF EnableDiagnosisForNotRequiredFields = true, }; var json2 = JsonSchema.FromType().Serialize(model, c); - Assert.AreEqual(@"{""mode"":0,""attributes"":{""POSITION"":0},""material"":0,""extras"":{""targetNames"":[""aaa""]},""extensions"":{}}", json2); + Assert.AreEqual(@"{""mode"":0,""attributes"":{""POSITION"":0},""material"":0,""extras"":{""targetNames"":[""aaa""]}}", json2); } [Test] diff --git a/Assets/VRM/UniGLTF/Scripts/Format/ExtensionsAndExtras/KHR_draco_mesh_compression.cs b/Assets/VRM/UniGLTF/Scripts/Format/ExtensionsAndExtras/KHR_draco_mesh_compression.cs index b304bc0a3..1e4b9ae48 100644 --- a/Assets/VRM/UniGLTF/Scripts/Format/ExtensionsAndExtras/KHR_draco_mesh_compression.cs +++ b/Assets/VRM/UniGLTF/Scripts/Format/ExtensionsAndExtras/KHR_draco_mesh_compression.cs @@ -4,24 +4,9 @@ using UniJSON; namespace UniGLTF { - [Serializable] - public class glTF_KHR_draco_mesh_compression : JsonSerializableBase - { - [JsonSchema(Required = true, Minimum = 0)] - public int bufferView = -1; - public glTFAttributes attributes; - - protected override void SerializeMembers(GLTFJsonFormatter f) - { - //throw new NotImplementedException(); - } - } - [Serializable] public partial class glTFPrimitives_extensions : ExtensionsBase { - public glTF_KHR_draco_mesh_compression KHR_draco_mesh_compression; - [JsonSerializeMembers] void SerializeMembers_draco(GLTFJsonFormatter f) { diff --git a/Assets/VRM/UniGLTF/Scripts/Format/glTFMesh.cs b/Assets/VRM/UniGLTF/Scripts/Format/glTFMesh.cs index 526837b9f..315041653 100644 --- a/Assets/VRM/UniGLTF/Scripts/Format/glTFMesh.cs +++ b/Assets/VRM/UniGLTF/Scripts/Format/glTFMesh.cs @@ -116,7 +116,7 @@ namespace UniGLTF public glTFPrimitives_extras extras = new glTFPrimitives_extras(); [JsonSchema(SkipSchemaComparison = true)] - public glTFPrimitives_extensions extensions = new glTFPrimitives_extensions(); + public glTFPrimitives_extensions extensions = null; protected override void SerializeMembers(GLTFJsonFormatter f) { @@ -128,10 +128,6 @@ namespace UniGLTF { f.Key("targets"); f.GLTFValue(targets); } - if (extensions.KHR_draco_mesh_compression != null) - { - f.Key("extensions"); f.GLTFValue(extensions); - } if (extras.targetNames.Count > 0) { f.Key("extras"); f.GLTFValue(extras);