PDA

View Full Version : gluBeginCurve() Problem



sdyajian
11-01-2007, 03:17 AM
hi there,

I have a barrier with the function gluBeginCurve()

[CODE]
for(i=0; i<140; i++){
gluBeginCurve(theNurb[i]);

gluNurbsCurve(theNurb[i], 8, knot, 3, &ctrlpoints[i][0][0], 4, GL_MAP1_VERTEX_3);

gluEndCurve(theNurb[i]);

}
[\CODE]

the code above can be built, but that responses "access violation at **.exe 0x2392jikm".

I do not think i misuse the pointer here, I declare the variants in the seperate class.

[CODE]
for(i=0; i<140; i++){
for(j=0; j<20; j++){
gluBeginCurve(theNurb[i*20+j]);

gluNurbsCurve(theNurb[i*20+j], 8, knot, 3, &ctrlpoints[i][0][0], 4, GL_MAP1_VERTEX_3);

gluEndCurve(theNurb[i*20+j]);
}
}
the above code is my favorite design, but it response the same problem with the one level iteration.


Please give me a hand on that......

cheers,
Yang
[\CODE]

This bullet is forwarded from the Beginner's Section, because there is no response.

ZbuffeR
11-01-2007, 03:51 AM
No need to do multiple cross post (http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=userposts&id=20884)
You will not have more answers by repeadting your question again and again.
And your code blocks are wrong, the end slash should be in the other direction, like this /

Instead, concentrate on advices that were already given to you.
If continue to have problems, continue on one single post.