Advanced .OBJ loader/viewer

Hi,

I search one .OBJ (Wavefront 3D models) loader/viewer but than can handle free-form curve/surface body statements like this :


cstype rat bspline     
deg 2 2     
surf -1.0 2.5 -2.0 2.0 -9 -8 -7 -6 -5 -4 -3 -2 -1     
parm u -1.00 -1.00 -1.00 2.50 2.50 2.50     
parm v -2.00 -2.00 -2.00 -2.00 -2.00 -2.00     
trim 0.0 2.0 1     
end

But alls sources codes that I have found only handle points, lines, triangles and polygons shapes, nothing about splines or patch :frowning:

Where can I find something like this ?

Take a look at the wiki of .obj : spline are unsuported by most of the loaders. And it sounds normal… OpenGL deals with triangles/quad/line/point. You have to build your own loader and own glsl code (geometry/tesellation shader) to generate a correct geometry (uv too) from your spline datas.

This is why I ask this question :smiley:

This can certainly to be handled via the standard GLU library http://www.glprogramming.com/red/chapter12.html, no ?