@@ -399,24 +399,22 @@ namespace Mahakam
399399 MeshData meshData (vertexCount, std::move (indices));
400400
401401 if (positionOffset)
402- meshData.SetVertices (VertexType::Position, ShaderDataType::Float3, positions.data ());
402+ meshData.SetVertices (VertexType::Position, positions.data ());
403403 if (texcoordOffset)
404- meshData.SetVertices (VertexType::TexCoords, ShaderDataType::Float2, texcoords.data ());
404+ meshData.SetVertices (VertexType::TexCoords, texcoords.data ());
405405 if (normalOffset)
406- meshData.SetVertices (VertexType::Normals, ShaderDataType::Float3, normals.data ());
406+ meshData.SetVertices (VertexType::Normals, normals.data ());
407407 if (tangentOffset)
408- meshData.SetVertices (VertexType::Tangents, ShaderDataType::Float4, tangents.data ());
408+ meshData.SetVertices (VertexType::Tangents, tangents.data ());
409409 if (colorOffset)
410- meshData.SetVertices (VertexType::Colors, ShaderDataType::Float4, colors.data ());
410+ meshData.SetVertices (VertexType::Colors, colors.data ());
411411 if (boneIDOffset && boneWeightOffset)
412412 {
413- meshData.SetVertices (VertexType::BoneIDs, ShaderDataType::Int4, boneIDs.data ());
414- meshData.SetVertices (VertexType::BoneWeights, ShaderDataType::Float4, boneWeights.data ());
413+ meshData.SetVertices (VertexType::BoneIDs, boneIDs.data ());
414+ meshData.SetVertices (VertexType::BoneWeights, boneWeights.data ());
415415 }
416416
417- Ref<SubMesh> mesh = SubMesh::Create (std::move (meshData));
418-
419- skinnedMesh->Meshes .push_back (mesh);
417+ skinnedMesh->Meshes .push_back (SubMesh::Create (std::move (meshData)));
420418 }
421419
422420 // Extract nodes and bones
@@ -589,9 +587,9 @@ namespace Mahakam
589587
590588 // Interleave vertices
591589 MeshData meshData (vertexCount, std::move (indices));
592- meshData.SetVertices (VertexType::Position, ShaderDataType::Float3, positions.data ());
593- meshData.SetVertices (VertexType::TexCoords, ShaderDataType::Float2, uvs.data ());
594- meshData.SetVertices (VertexType::Normals, ShaderDataType::Float3, normals.data ());
590+ meshData.SetVertices (VertexType::Position, positions.data ());
591+ meshData.SetVertices (VertexType::TexCoords, uvs.data ());
592+ meshData.SetVertices (VertexType::Normals, normals.data ());
595593 // meshData.SetVertices(VertexType::Tangents, ShaderDataType::Float4, tangents.data());
596594
597595 Ref<SubMesh> mesh = SubMesh::Create (std::move (meshData));
@@ -651,10 +649,10 @@ namespace Mahakam
651649
652650 // Interleave vertices
653651 MeshData meshData (vertexCount, std::move (indices));
654- meshData.SetVertices (VertexType::Position, ShaderDataType::Float3, positions.data ());
655- meshData.SetVertices (VertexType::TexCoords, ShaderDataType::Float2, uvs.data ());
656- meshData.SetVertices (VertexType::Normals, ShaderDataType::Float3, normals.data ());
657- meshData.SetVertices (VertexType::Tangents, ShaderDataType::Float4, tangents.data ());
652+ meshData.SetVertices (VertexType::Position, positions.data ());
653+ meshData.SetVertices (VertexType::TexCoords, uvs.data ());
654+ meshData.SetVertices (VertexType::Normals, normals.data ());
655+ meshData.SetVertices (VertexType::Tangents, tangents.data ());
658656
659657 Ref<SubMesh> mesh = SubMesh::Create (std::move (meshData));
660658
@@ -714,10 +712,10 @@ namespace Mahakam
714712
715713 // Interleave vertices
716714 MeshData meshData (vertexCount, std::move (indices));
717- meshData.SetVertices (VertexType::Position, ShaderDataType::Float3, positions.data ());
718- meshData.SetVertices (VertexType::TexCoords, ShaderDataType::Float2, uvs.data ());
719- meshData.SetVertices (VertexType::Normals, ShaderDataType::Float3, normals.data ());
720- meshData.SetVertices (VertexType::Tangents, ShaderDataType::Float4, tangents.data ());
715+ meshData.SetVertices (VertexType::Position, positions.data ());
716+ meshData.SetVertices (VertexType::TexCoords, uvs.data ());
717+ meshData.SetVertices (VertexType::Normals, normals.data ());
718+ meshData.SetVertices (VertexType::Tangents, tangents.data ());
721719
722720 Ref<SubMesh> mesh = SubMesh::Create (std::move (meshData));
723721
@@ -813,10 +811,10 @@ namespace Mahakam
813811
814812 // Interleave vertices
815813 MeshData meshData (vertexCount, std::move (indices));
816- meshData.SetVertices (VertexType::Position, ShaderDataType::Float3, positions.data ());
817- meshData.SetVertices (VertexType::TexCoords, ShaderDataType::Float2, uvs.data ());
818- meshData.SetVertices (VertexType::Normals, ShaderDataType::Float3, normals.data ());
819- meshData.SetVertices (VertexType::Tangents, ShaderDataType::Float4, tangents.data ());
814+ meshData.SetVertices (VertexType::Position, positions.data ());
815+ meshData.SetVertices (VertexType::TexCoords, uvs.data ());
816+ meshData.SetVertices (VertexType::Normals, normals.data ());
817+ meshData.SetVertices (VertexType::Tangents, tangents.data ());
820818
821819 Ref<SubMesh> mesh = SubMesh::Create (std::move (meshData));
822820
0 commit comments