RenderManAll camera/projection parameters are set between RiBegin() and RiWorldBegin(). Any geometric transformations after RiProjection() and before RiWorldBegin() effect the viewing matrix(camera). You must first clear the current matrix by calling RiIdentity(). After RiWorldBegin() all geometric transformations concern the world and object space. |
OpenGLMost camera/projection parameters are set in the reshape() function after a call to glMatrixMode(GL_PROJECTION) and before a call to glMatrixMode(GL_MODELVIEW). You must first clear the current matrix by calling glLoadIdentity(). After glMatrixMode(GL_MODELVIEW) geometric transformations effect the world and object space. |
RiFormat(xres, yres, pixelaspectratio)
RiProjection(type, ...)
RiFrameAspectRatio(frameratio)
RiScreenWindow(left, right, bottom, top)
|
glViewPort(x, y, (GLsizei)width, (GLsizei)height)
glFrustrum(left, right, bottom, top, near, far)
*NOTE - glFrustrum is very tricky to master, and you might feel more comfortable using the Utility Library routine gluPerspective(). gluPerspective(fovy, aspectratio, near, far)
|