Graphics: Add support of skins to InstancedRenderable + big clean up

This commit is contained in:
Lynix
2017-01-09 01:52:00 +01:00
parent d2ee4744a9
commit 6b949afb9b
21 changed files with 579 additions and 504 deletions

View File

@@ -62,7 +62,7 @@ namespace Nz
for (unsigned int i = 0; i < submeshCount; ++i)
{
const SkeletalMesh* mesh = static_cast<const SkeletalMesh*>(m_mesh->GetSubMesh(i));
const Material* material = m_materials[mesh->GetMaterialIndex()];
const Material* material = GetMaterial(mesh->GetMaterialIndex());
MeshData meshData;
meshData.indexBuffer = mesh->GetIndexBuffer();
@@ -261,17 +261,6 @@ namespace Nz
return SkeletalModelLoader::LoadFromStream(this, stream, params);
}
/*!
* \brief Resets the model
*/
void SkeletalModel::Reset()
{
Model::Reset();
m_skeleton.Destroy();
}
/*!
* \brief Sets the animation for the model
* \return true If successful