hello

well i'd like to tesselate an object using the tesseletor of glu and the recover the vertex given to store them

the problem is that i don't know how to recover them? when my callback function is called? which parameteres are given to this function?

here is my code :

and in my callbask function i would like to insert those vertex to a .3ds file using lib3dsCode :My3ds = lib3ds_file_new(); GLUtesselator *tessobj; tessobj = gluNewTess(); gluTessCallback(tessobj, GLU_TESS_EDGE_FLAG, NULL); gluTessCallback(tessobj, GLU_TESS_VERTEX, vertex_fn); for (int i=0; i<model.ncares; i++){ gluTessBeginPolygon(tessobj, NULL); gluTessBeginContour(tessobj); for (int j=0; j<model.cares[i].nverts; j++){ gluTessVertex(tessobj, model.cares[i].verts[j], vertex_data[j]); } gluTessEndContour(tessobj); gluTessEndPolygon(tessobj); } gluDeleteTess(tessobj);

thanksCode :void *vertex_fn(){ Lib3dsMesh *mesh; mech->pointL = vertex_data; // how to recover the coordinates (vertex_data)? // insert a face after 3 given vertex // or insert a point corresponding to the vertex? lib3ds_file_insert_mesh(My3ds, mech); }