Commit current work

This commit is contained in:
SirLynix
2022-05-13 17:48:35 +02:00
committed by Jérôme Leclercq
parent a7ab2fbaf4
commit b8ea79c40e
12 changed files with 619 additions and 641 deletions

View File

@@ -25,12 +25,6 @@ namespace Nz
{
bool MeshParams::IsValid() const
{
if (matrix == Matrix4f::Zero())
{
NazaraError("Invalid matrix");
return false;
}
if (!vertexDeclaration)
{
NazaraError("The vertex declaration can't be null");
@@ -87,8 +81,7 @@ namespace Nz
std::shared_ptr<IndexBuffer> indexBuffer;
std::shared_ptr<VertexBuffer> vertexBuffer;
Matrix4f matrix(primitive.matrix);
matrix *= params.matrix;
Matrix4f matrix = Matrix4f::ConcatenateTransform(primitive.matrix, Matrix4f::Transform(params.vertexOffset, params.vertexRotation, params.vertexScale));
const std::shared_ptr<VertexDeclaration>& declaration = params.vertexDeclaration;