1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226
|
'\" te
'\"! tbl|eqn | mmdoc
'\"macro stdmacro
.ds Vn Version 1.2
.ds Dt 24 September 1999
.ds Re Release 1.2.1
.ds Dp Jan 14 18:30
.ds Dm 01 evalcoord
.ds Xs 42414 8 evalcoord.gl
.TH GLEVALCOORD 3G
.SH NAME
.B "glEvalCoord1d, glEvalCoord1f, glEvalCoord2d, glEvalCoord2f, glEvalCoord1dv, glEvalCoord1fv, glEvalCoord2dv, glEvalCoord2fv
\- evaluate enabled one- and two-dimensional maps
.EQ
delim $$
.EN
.SH C SPECIFICATION
void \f3glEvalCoord1d\fP(
GLdouble \fIu\fP )
.nf
.fi
void \f3glEvalCoord1f\fP(
GLfloat \fIu\fP )
.nf
.fi
void \f3glEvalCoord2d\fP(
GLdouble \fIu\fP,
.nf
.ta \w'\f3void \fPglEvalCoord2d( 'u
GLdouble \fIv\fP )
.fi
void \f3glEvalCoord2f\fP(
GLfloat \fIu\fP,
.nf
.ta \w'\f3void \fPglEvalCoord2f( 'u
GLfloat \fIv\fP )
.fi
.SH PARAMETERS
.TP \w'\f2u\fP\ \ 'u
\f2u\fP
Specifies a value that is the domain coordinate $u$ to the basis function
defined in a previous \%\f3glMap1\fP or \%\f3glMap2\fP command.
.TP
\f2v\fP
Specifies a value that is the domain coordinate $v$ to the basis function
defined in a previous \%\f3glMap2\fP command.
This argument is not present in a \%\f3glEvalCoord1\fP command.
.SH C SPECIFICATION
void \f3glEvalCoord1dv\fP(
const GLdouble \fI*u\fP )
.nf
.fi
void \f3glEvalCoord1fv\fP(
const GLfloat \fI*u\fP )
.nf
.fi
void \f3glEvalCoord2dv\fP(
const GLdouble \fI*u\fP )
.nf
.fi
void \f3glEvalCoord2fv\fP(
const GLfloat \fI*u\fP )
.nf
.fi
.SH PARAMETERS
.TP
\f2u\fP
Specifies a pointer to an array containing
either one or two domain coordinates.
The first coordinate is $u$.
The second coordinate is $v$,
which is present only in \%\f3glEvalCoord2\fP versions.
.SH DESCRIPTION
\%\f3glEvalCoord1\fP evaluates enabled one-dimensional maps at argument
\f2u\fP.
\%\f3glEvalCoord2\fP does the same for two-dimensional maps using
two domain values,
\f2u\fP and \f2v\fP.
To define a map, call \%\f3glMap1\fP and \%\f3glMap2\fP; to enable and
disable it, call \%\f3glEnable\fP and \%\f3glDisable\fP.
.P
When one of the \%\f3glEvalCoord\fP commands is issued,
all currently enabled maps of the indicated dimension are evaluated.
Then,
for each enabled map,
it is as if the corresponding GL command had been issued with the
computed value.
That is,
if \%\f3GL_MAP1_INDEX\fP or
\%\f3GL_MAP2_INDEX\fP is enabled,
a \%\f3glIndex\fP command is simulated.
If \%\f3GL_MAP1_COLOR_4\fP or
\%\f3GL_MAP2_COLOR_4\fP is enabled,
a \%\f3glColor\fP command is simulated.
If \%\f3GL_MAP1_NORMAL\fP or \%\f3GL_MAP2_NORMAL\fP is enabled,
a normal vector is produced,
and if any of
\%\f3GL_MAP1_TEXTURE_COORD_1\fP,
\%\f3GL_MAP1_TEXTURE_COORD_2\fP,
\%\f3GL_MAP1_TEXTURE_COORD_3\fP,
\%\f3GL_MAP1_TEXTURE_COORD_4\fP,
\%\f3GL_MAP2_TEXTURE_COORD_1\fP,
\%\f3GL_MAP2_TEXTURE_COORD_2\fP,
\%\f3GL_MAP2_TEXTURE_COORD_3\fP, or
\%\f3GL_MAP2_TEXTURE_COORD_4\fP is enabled, then an appropriate \%\f3glTexCoord\fP command is simulated.
.P
For color,
color index,
normal,
and texture coordinates the GL uses evaluated values instead of current values for those evaluations
that are enabled,
and current values otherwise,
However,
the evaluated values do not update the current values.
Thus, if \%\f3glVertex\fP commands are interspersed with \%\f3glEvalCoord\fP
commands, the color,
normal,
and texture coordinates associated with the \%\f3glVertex\fP commands are not
affected by the values generated by the \%\f3glEvalCoord\fP commands,
but only by the most recent
\%\f3glColor\fP,
\%\f3glIndex\fP,
\%\f3glNormal\fP, and
\%\f3glTexCoord\fP commands.
.P
No commands are issued for maps that are not enabled.
If more than one texture evaluation is enabled for a particular dimension
(for example, \%\f3GL_MAP2_TEXTURE_COORD_1\fP and
\%\f3GL_MAP2_TEXTURE_COORD_2\fP),
then only the evaluation of the map that produces the larger
number of coordinates
(in this case, \%\f3GL_MAP2_TEXTURE_COORD_2\fP)
is carried out.
\%\f3GL_MAP1_VERTEX_4\fP overrides \%\f3GL_MAP1_VERTEX_3\fP,
and
\%\f3GL_MAP2_VERTEX_4\fP overrides \%\f3GL_MAP2_VERTEX_3\fP,
in the same manner.
If neither a three- nor a four-component vertex map is enabled for the
specified dimension,
the \%\f3glEvalCoord\fP command is ignored.
.P
If you have enabled automatic normal generation,
by calling \%\f3glEnable\fP with argument \%\f3GL_AUTO_NORMAL\fP,
\%\f3glEvalCoord2\fP generates surface normals analytically,
regardless of the contents or enabling of the \%\f3GL_MAP2_NORMAL\fP map.
Let
.sp
.ce
.EQ
bold m ~=~ {partial bold p} over {partial u} ~times~
{partial bold p} over {partial v}
.EN
.ce 0
.sp
.br
Then the generated normal $ bold n $ is
.br
.ce
$bold n ~=~ bold m over { || bold m || }$
.ce 0
.sp
.br
If automatic normal generation is disabled,
the corresponding normal map \%\f3GL_MAP2_NORMAL\fP,
if enabled,
is used to produce a normal.
If neither automatic normal generation nor a normal map is enabled,
no normal is generated for
\%\f3glEvalCoord2\fP commands.
.SH ASSOCIATED GETS
.nf
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_VERTEX_3\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_VERTEX_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_INDEX\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_COLOR_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_NORMAL\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_TEXTURE_COORD_1\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_TEXTURE_COORD_2\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_TEXTURE_COORD_3\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP1_TEXTURE_COORD_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_VERTEX_3\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_VERTEX_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_INDEX\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_COLOR_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_NORMAL\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_TEXTURE_COORD_1\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_TEXTURE_COORD_2\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_TEXTURE_COORD_3\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_MAP2_TEXTURE_COORD_4\fP
.br
\%\f3glIsEnabled\fP with argument \%\f3GL_AUTO_NORMAL\fP
.br
\%\f3glGetMap\fP
.SH SEE ALSO
\%\f3glBegin(3G)\fP,
\%\f3glColor(3G)\fP,
\%\f3glEnable(3G)\fP,
\%\f3glEvalMesh(3G)\fP,
\%\f3glEvalPoint(3G)\fP,
\%\f3glIndex(3G)\fP,
\%\f3glMap1(3G)\fP,
\%\f3glMap2(3G)\fP,
\%\f3glMapGrid(3G)\fP,
\%\f3glNormal(3G)\fP,
\%\f3glTexCoord(3G)\fP,
\%\f3glVertex(3G)\fP
|