[ Previous | Next | Contents | Glossary | Home | Search ]
OpenGL 1.1 for AIX: Reference Manual

gluLoadSamplingMatrices Subroutine

Purpose

Loads non-uniform rational B-spline (NURBS) sampling and culling matrices.

Library

OpenGL C bindings library: libGL.a

C Syntax

void gluLoadSamplingMatrices(GLUnurbsObj *nobj, 
   const GLfloat ModelMatrix[16], 
   const GLfloat ProjectionMatrix[16], 
   const GLint Viewport[4])

Description

The gluLoadSamplingMatrices subroutine uses the ModelMatrix, ProjectionMatrix, and Viewport parameters to recompute the sampling and culling matrices stored in the nobj parameter. The sampling matrix determines how finely a NURBS surface or curve must be tessellated to satisfy the sampling tolerance (as determined by the GLU_SAMPLING_TOLERANCE property). The culling matrix determines whether a NURBS curve or surface should be culled before rendering (when the GLU_CULLING property is turned on).

Use of the gluLoadSamplingMatrices subroutine is necessary only if the GLU_AUTO_LOAD_MATRIX property is turned off. (See the gluNurbsProperty subroutine for information on adjusting properties in a NURBS object.) Leaving the GLU_AUTO_LOAD_MATRIX property turned on causes performance slowdown since it necessitates a round-trip to the OpenGL server to fetch the current values of the modelview matrix, projection matrix, and viewport.

Parameters

nobj Specifies the NURBS object created with the gluNewNurbsRenderer subroutine.
ModelMatrix Specifies a modelview matrix, such as from a glGetFloatv call.
ProjectionMatrix Specifies a projection matrix, such as from a glGetFloatv call.
Viewport Specifies a viewport, such as from a glGetIntegerv call.

Files

/usr/include/GL/gl.h Contains C language constraints, variable type definitions, and ANSI function prototypes for OpenGL.

Related Information

The gluGetNurbsProperty subroutine, gluNewNurbsRenderer subroutine, gluNurbsProperty subroutine.

OpenGL Overview.


[ Previous | Next | Contents | Glossary | Home | Search ]