differ vertexNormal and triangleNormal

This commit is contained in:
Anakin 2017-01-23 13:49:29 +01:00
parent 10718f2269
commit 0a9103fdc5
2 changed files with 3 additions and 3 deletions

View File

@ -23,7 +23,7 @@ struct VertexData
{
QVector3D position;
QVector2D texCoord;
QVector3D normal;
QVector3D vertexNormal;
};
struct Segment {

View File

@ -510,7 +510,7 @@ void MshFile::analyseSegmChunks(Model * dataDestination, std::list<ChunkHeader*>
for (unsigned int i = new_segment->vertices.size(); i != tmp_size; i--)
for (unsigned int j = 0; j < 3; j++)
new_segment->vertices[i - 1].normal[j] = 0;
new_segment->vertices[i - 1].vertexNormal[j] = 0;
}
else if (tmp_size > new_segment->vertices.size())
{
@ -520,7 +520,7 @@ void MshFile::analyseSegmChunks(Model * dataDestination, std::list<ChunkHeader*>
for (unsigned int i = 0; i < tmp_size; i++)
for (unsigned int j = 0; j < 3; j++)
m_file.read(F2V(new_segment->vertices[i].normal[j]), sizeof(float));
m_file.read(F2V(new_segment->vertices[i].vertexNormal[j]), sizeof(float));
}