From a7639d5f5af4052850dc065f6255df3a180cd04c Mon Sep 17 00:00:00 2001 From: assiduous Date: Sat, 27 Jun 2020 20:17:27 -0700 Subject: GLTFLoader: updated bound box calculations --- AssetLoader/interface/GLTFLoader.hpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'AssetLoader/interface') diff --git a/AssetLoader/interface/GLTFLoader.hpp b/AssetLoader/interface/GLTFLoader.hpp index b9096d9..e3e9ed0 100644 --- a/AssetLoader/interface/GLTFLoader.hpp +++ b/AssetLoader/interface/GLTFLoader.hpp @@ -144,8 +144,8 @@ struct Mesh std::vector> Primitives; BoundBox BB; - BoundBox AABB; - bool IsValidBB = false; + + bool IsValidBB = false; struct TransformData { @@ -256,7 +256,9 @@ struct Model RefCntAutoPtr pIndexBuffer; Uint32 IndexCount = 0; - float4x4 aabb; + /// Transformation matrix that transforms unit cube [0,1]x[0,1]x[0,1] into + /// axis-aligned bounding box in model space. + float4x4 AABBTransform; std::vector> Nodes; std::vector LinearNodes; -- cgit v1.2.3