From 7ddfe918c6d779a31b845e2e3f2d8055d1384402 Mon Sep 17 00:00:00 2001 From: Jacek Date: Mon, 6 Jan 2020 14:36:57 -0600 Subject: [PATCH] Reserve space for animation samplers in serialization --- tiny_gltf.h | 1 + 1 file changed, 1 insertion(+) diff --git a/tiny_gltf.h b/tiny_gltf.h index e2bd4a6..9405656 100644 --- a/tiny_gltf.h +++ b/tiny_gltf.h @@ -6074,6 +6074,7 @@ static void SerializeGltfAnimation(Animation &animation, json &o) { { json samplers; + JsonReserveArray(samplers, animation.samplers.size()); for (unsigned int i = 0; i < animation.samplers.size(); ++i) { json sampler; AnimationSampler gltfSampler = animation.samplers[i];