MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / renderLinearPath

Method renderLinearPath

Engine/source/Verve/VPath/VPathEditor.cpp:1678–1699  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1676}
1677
1678void VPathEditor::renderLinearPath( VPath *pPath, const ColorI &pColor )
1679{
1680 if ( pPath->mNodeList.size() < 2 )
1681 {
1682 // No Lines.
1683 return;
1684 }
1685
1686 PrimBuild::color( pColor );
1687 PrimBuild::begin( GFXLineStrip, ( pPath->mNodeList.size() + 1 ) );
1688
1689 for ( VPathNodeIterator itr = pPath->mNodeList.begin(); itr != pPath->mNodeList.end(); itr++ )
1690 {
1691 // Apply Vertex.
1692 PrimBuild::vertex3fv( ( *itr )->getWorldPosition() );
1693 }
1694
1695 // Loop Back.
1696 PrimBuild::vertex3fv( pPath->mNodeList.front()->getWorldPosition() );
1697
1698 PrimBuild::end();
1699}
1700
1701void VPathEditor::renderBezierPath( VPath *pPath, const ColorI &pColor )
1702{

Callers

nothing calls this directly

Calls 9

beginFunction · 0.85
endFunction · 0.85
colorFunction · 0.50
vertex3fvFunction · 0.50
sizeMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
getWorldPositionMethod · 0.45
frontMethod · 0.45

Tested by

no test coverage detected