Graphics Reference
In-Depth Information
void
glDeleteSamplers
(GLsizei
n,
const GLuint *
samplers
)
specifies the number of sampler objects to delete
n
an array of unsigned integers that hold
n
sampler object
IDs to delete
samplers
Once sampler object IDs have been generated with
glGenSamplers
,
the application must bind the sampler object to use its state. Sampler
objects are bound to texture units. Binding the sampler object to the
texture unit supersedes any of the state set in the texture object using
glTexParameter[i
|
f][v]
. The function used to bind a sampler object is
glBindSampler
.
void
glBindSampler
(GLenum
unit
, GLuint
sampler
)
specifies the texture unit to bind the sampler object to
unit
the handle to the sampler object to bind
sampler
If the
sampler
passed to
glBindSampler
is 0 (the default sampler),
then the state set for the texture object will be used. The sampler object
state can be set using
glSamplerParameter[f|i][v]
. The parameters
that can be set by
glSamplerParameter[f|i][v]
are the exact
same ones that are set by using
glTexParameter[i
|
f][v]
. The only
difference is that the state is set to the sampler object rather than the
texture object.
void
glSamplerParameteri
(GLuint
sampler,
GLenum
pname,
GLint
param
)
void
glSamplerParameteriv
(GLuint
sampler,
GLenum
pname,
const GLint *
params
)
void
glSamplerParameterf
(GLuint
sampler,
GLenum
pname,
GLfloat
param
)
void
glSamplerParameterfv
(GLuint
sampler,
GLenum
pname,
const GLfloat *
params
)