mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
solid capsule renderfix. +/- halfhieght, not full, and need to do vector, not point-multiplication for the verts
This commit is contained in:
parent
05f8d8b5f1
commit
110d815b39
1 changed files with 3 additions and 3 deletions
|
|
@ -1153,9 +1153,9 @@ void GFXDrawUtil::_drawSolidCapsule( const GFXStateBlockDesc &desc, const Point3
|
|||
for (S32 i=0; i<numPoints + 1; i++)
|
||||
{
|
||||
S32 imod = i % numPoints;
|
||||
verts[2 * i].point = Point3F( circlePoints[imod].x * radius, circlePoints[imod].y * radius, height );
|
||||
verts[2 * i].point = Point3F( circlePoints[imod].x * radius, circlePoints[imod].y * radius, height/2 );
|
||||
verts[2 * i].color = color;
|
||||
verts[2 * i + 1].point = Point3F( circlePoints[imod].x * radius, circlePoints[imod].y * radius, -height );
|
||||
verts[2 * i + 1].point = Point3F( circlePoints[imod].x * radius, circlePoints[imod].y * radius, -height/2 );
|
||||
verts[2 * i + 1].color = color;
|
||||
}
|
||||
|
||||
|
|
@ -1163,7 +1163,7 @@ void GFXDrawUtil::_drawSolidCapsule( const GFXStateBlockDesc &desc, const Point3
|
|||
|
||||
// Apply xfm if we were passed one.
|
||||
for ( U32 i = 0; i < totalNumPnts; i++ )
|
||||
mat.mulP( verts[i].point );
|
||||
mat.mulV( verts[i].point );
|
||||
|
||||
// Apply position offset
|
||||
for ( U32 i = 0; i < totalNumPnts; i++ )
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue