| 731 | //----------------------------------------------------------------------------- |
| 732 | |
| 733 | void GuiTSCtrl::drawLine( Point3F p0, Point3F p1, const ColorI &color, F32 width ) |
| 734 | { |
| 735 | if ( !mSaveFrustum.clipSegment( p0, p1 ) ) |
| 736 | return; |
| 737 | |
| 738 | MathUtils::mProjectWorldToScreen( p0, &p0, mSaveViewport, mSaveModelview, mSaveProjection ); |
| 739 | MathUtils::mProjectWorldToScreen( p1, &p1, mSaveViewport, mSaveModelview, mSaveProjection ); |
| 740 | |
| 741 | p0.x = mClampF( p0.x, 0.0f, mSaveViewport.extent.x ); |
| 742 | p0.y = mClampF( p0.y, 0.0f, mSaveViewport.extent.y ); |
| 743 | p1.x = mClampF( p1.x, 0.0f, mSaveViewport.extent.x ); |
| 744 | p1.y = mClampF( p1.y, 0.0f, mSaveViewport.extent.y ); |
| 745 | p0.z = p1.z = 0.0f; |
| 746 | |
| 747 | _drawLine( p0, p1, color, width ); |
| 748 | } |
| 749 | |
| 750 | //----------------------------------------------------------------------------- |
| 751 |
no test coverage detected