Model loader now takes into account submeshes transform

This commit is contained in:
antopilo
2024-09-27 01:39:40 -04:00
parent e18dbd292f
commit 28bbb255c5
5 changed files with 56 additions and 16 deletions

View File

@@ -194,10 +194,6 @@ Ref<Nuake::Texture> ThumbnailManager::GenerateThumbnail(const std::string& path,
ModelComponent& modelComp = scene->CreateEntity("Mesh").AddComponent<ModelComponent>();
modelComp.ModelResource = ResourceLoader::LoadModel(file->GetRelativePath());
AABB aabb = modelComp.ModelResource->GetMeshes()[0]->GetAABB();
Vector3 middlePoint = aabb.Max / 2.0f;
scene->Update(0.01f);
scene->Draw(*m_ShadedFramebuffer.get());
}