Commit 45dc3fbf authored by Jan Möbius's avatar Jan Möbius
Browse files

Fixed crash with empty spline curve



git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@14785 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 54a0b1ae
......@@ -993,6 +993,10 @@ draw_textured_nurbs( GLState& /*_state*/)
const int numCPs = bsplineCurve_.n_control_points();
int order = bsplineCurve_.degree() + 1;
// gluNurbsSurface seems to crash for knots = 0
if (!numKnots)
return;
// get knotvector
GLfloat *knots = new GLfloat[numKnots];
for (int i = 0; i < numKnots; ++i)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment