coding standard: type formatting and variable names

This commit is contained in:
Howard Stearns 2015-04-29 15:19:40 -07:00
parent 59ed63027b
commit 1255d46140
3 changed files with 17 additions and 17 deletions

View file

@ -165,13 +165,13 @@ QVector<OBJFace> OBJFace::triangulate() {
}
return newFaces;
}
void OBJFace::addFrom(OBJFace const * f, int i) { // add using data from f at index i
vertexIndices.append(f->vertexIndices[i]);
if (f->textureUVIndices.count() > 0) { // Any at all. Runtime error if not consistent.
textureUVIndices.append(f->textureUVIndices[i]);
void OBJFace::addFrom(const OBJFace* face, int index) { // add using data from f at index i
vertexIndices.append(face->vertexIndices[index]);
if (face->textureUVIndices.count() > 0) { // Any at all. Runtime error if not consistent.
textureUVIndices.append(face->textureUVIndices[index]);
}
if (f->normalIndices.count() > 0) {
normalIndices.append(f->normalIndices[i]);
if (face->normalIndices.count() > 0) {
normalIndices.append(face->normalIndices[index]);
}
}

View file

@ -41,7 +41,7 @@ public:
// Even though FBXMeshPart can handle quads, it would be messy to try to keep track of mixed-size faces, so we treat everything as triangles.
QVector<OBJFace> triangulate();
private:
void addFrom(OBJFace const * f, int i);
void addFrom(const OBJFace* face, int index);
};
class OBJReader {