Hi,
I'm having problem combining the OpenGL matrix calls with the EDGELIB 3D model drawing.
Is it possible to set the projection matrix used in EDGELIB to whatever I set in glFrustumx(..)?
Instead of using display->Perspective3D(..) call, I want to set the projection matrix using OpenGL call. I tried:
But the above code doesn't seem to affect the rendering in the display [ClassEDisplay] object.
This is same for the glMultMatrixx(...) call. The rendered 3D model does not get rendered based on the matrix set by OpenGL. Is there a way to make EDGELIB uses the matrix set in OpenGL?
Thanks
Ohan[/quote]
I'm having problem combining the OpenGL matrix calls with the EDGELIB 3D model drawing.
Is it possible to set the projection matrix used in EDGELIB to whatever I set in glFrustumx(..)?
Instead of using display->Perspective3D(..) call, I want to set the projection matrix using OpenGL call. I tried:
- Code:
// Sets up the projection matrix in OpenGL
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
glFrustumx(....);
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
// Renders the 3D turtle
display->SetShading(E3D_GOURAUD | E3D_TEXTURE);
display->BindTexture(&turtle;_tex);
display->SetShading(rendertype_shading[rendertype]);
display->Render(&turtle;);
But the above code doesn't seem to affect the rendering in the display [ClassEDisplay] object.
This is same for the glMultMatrixx(...) call. The rendered 3D model does not get rendered based on the matrix set by OpenGL. Is there a way to make EDGELIB uses the matrix set in OpenGL?
Thanks
Ohan[/quote]