Oriented Particles UV Correction

With Permission from Jeff Faust.

   // AFX CODE BLOCK (bug-fix) <<
   // this fix re-orders the UV coords to produce a consistent orientation
   // with oriented particles in TGE.
This commit is contained in:
Azaezel 2014-12-22 18:05:43 -06:00
parent 84430a46a8
commit 8c979a6d7b

View file

@ -1825,22 +1825,22 @@ void ParticleEmitter::setupOriented( Particle *part,
lVerts->point = start + crossDir;
lVerts->color = partCol;
// Here and below, we copy UVs from particle datablock's texCoords (oriented)
lVerts->texCoord = part->dataBlock->texCoords[0];
lVerts->texCoord = part->dataBlock->texCoords[1];
++lVerts;
lVerts->point = start - crossDir;
lVerts->color = partCol;
lVerts->texCoord = part->dataBlock->texCoords[1];
lVerts->texCoord = part->dataBlock->texCoords[2];
++lVerts;
lVerts->point = end - crossDir;
lVerts->color = partCol;
lVerts->texCoord = part->dataBlock->texCoords[2];
lVerts->texCoord = part->dataBlock->texCoords[3];
++lVerts;
lVerts->point = end + crossDir;
lVerts->color = partCol;
lVerts->texCoord = part->dataBlock->texCoords[3];
lVerts->texCoord = part->dataBlock->texCoords[0];
++lVerts;
}