From 58ab95be2f9a645c2d4c98474b03fa3da4bc1bc4 Mon Sep 17 00:00:00 2001 From: Selmar Kok Date: Thu, 31 Oct 2019 15:08:03 +0100 Subject: [PATCH] only serialize doublesided if it is not the default value --- tiny_gltf.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tiny_gltf.h b/tiny_gltf.h index d09d83b..06f77f1 100644 --- a/tiny_gltf.h +++ b/tiny_gltf.h @@ -6002,7 +6002,8 @@ static void SerializeGltfMaterial(Material &material, json &o) { SerializeStringProperty("alphaMode", material.alphaMode, o); } - JsonAddMember(o, "doubleSided", json(material.doubleSided)); + if(material.doubleSided != false) + JsonAddMember(o, "doubleSided", json(material.doubleSided)); if (material.normalTexture.index > -1) { json texinfo;