From 3e322495f22828409e584af6af4350a2d80c7154 Mon Sep 17 00:00:00 2001 From: Angelo Scandaliato Date: Tue, 27 Sep 2016 11:38:17 -0700 Subject: [PATCH] asset.version from int to string --- code/glTFAssetWriter.inl | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/code/glTFAssetWriter.inl b/code/glTFAssetWriter.inl index 119ebc937..71b47473b 100644 --- a/code/glTFAssetWriter.inl +++ b/code/glTFAssetWriter.inl @@ -282,7 +282,7 @@ namespace glTF { } primitives.PushBack(prim, w.mAl); } - + obj.AddMember("primitives", primitives, w.mAl); } @@ -484,13 +484,15 @@ namespace glTF { } } - + inline void AssetWriter::WriteMetadata() { Value asset; asset.SetObject(); { - asset.AddMember("version", mAsset.asset.version, mAl); + char versionChar[10]; + snprintf(versionChar, sizeof(versionChar), "%d", mAsset.asset.version); + asset.AddMember("version", Value(versionChar, mAl).Move(), mAl); asset.AddMember("generator", Value(mAsset.asset.generator, mAl).Move(), mAl); }