Method GL.glTexCoord()


Method glTexCoord

void glTexCoord(float|int|array(float|int) s, float|int|void t, float|int|void r, float|int|void q)

Description

glTexCoord specifies texture coordinates in one, two, three, or four dimensions. glTexCoord sets the current texture coordinates to (s, 0, 0, 1); a call to

glTexCoord sets them to (s, t, 0, 1). Similarly, glTexCoord specifies the texture coordinates as (s, t, r, 1), and glTexCoord defines all four components explicitly as (s, t, r, q).

The current texture coordinates are part of the data that is associated with each vertex and with the current raster position. Initially, the values for s, t, r, and q are (0, 0, 0, 1).

Parameter s

Specify s, t, r, and q texture coordinates. Not all parameters are present in all forms of the command.

Parameter v

Specifies a pointer to an array of one, two, three, or four elements, which in turn specify the s, t, r, and q texture coordinates.