glConvolutionParameterEXT(3G) OpenGL Reference glConvolutionParameterEXT(3G)
NAME
glConvolutionParameterfEXT, glConvolutionParameteriEXT,
glConvolutionParameterfvEXT, glConvolutionParameterivEXT - set
convolution parameters
C SPECIFICATION
void glConvolutionParameterfEXT( GLenum target,
GLenum pname,
GLfloat params )
void glConvolutionParameteriEXT( GLenum target,
GLenum pname,
GLint params )
PARAMETERS
target The target for the convolution parameter. Must be one of
GLCONVOLUTION1DEXT, GLCONVOLUTION2DEXT, or
GLSEPARABLE2DEXT.
pname The parameter to be set. Must be GLCONVOLUTIONBORDERMODEEXT.
params The parameter value. Must be GLREDUCEEXT.
C SPECIFICATION
void glConvolutionParameterfvEXT( GLenum target,
GLenum pname,
const GLfloat *params )
void glConvolutionParameterivEXT( GLenum target,
GLenum pname,
const GLint *params )
PARAMETERS
target
The target for the convolution parameter. Must be one of
GLCONVOLUTION1DEXT, GLCONVOLUTION2DEXT, or
GLSEPARABLE2DEXT.
pname
The parameter to be set. Must be one of
GLCONVOLUTIONBORDERMODEEXT, GLCONVOLUTIONFILTERSCALEEXT, or
GLCONVOLUTIONFILTERBIASEXT.
params
The parameter value. Must be GLREDUCEEXT if pname is
GLCONVOLUTIONBORDERMODEEXT. Otherwise, must be a vector of four
values (for red, green, blue, and alpha, respectively) to be used
for scaling (when pname is GLCONVOLUTIONFILTERSCALEEXT) or for
biasing (when pname is GLCONVOLUTIONFILTERBIASEXT) a convolution
filter kernel.
Page 1
glConvolutionParameterEXT(3G) OpenGL Reference glConvolutionParameterEXT(3G)
DESCRIPTION
glConvolutionParameterEXT sets the value of a convolution parameter.
target selects the convolution filter to be affected:
GLCONVOLUTION1DEXT, GLCONVOLUTION2DEXT, or GLSEPARABLE2DEXT for
the 1D, 2D, or separable 2D filter, respectively.
pname selects the parameter to be changed.
GLCONVOLUTIONFILTERSCALEEXT and GLCONVOLUTIONFILTERBIASEXT affect
the definition of the convolution filter kernel; see
glConvolutionFilter1DEXT, glConvolutionFilter2DEXT, and
glSeparableFilter2DEXT for details. In these cases, params is an array
of four values to be applied to red, green, blue, and alpha values
respectively.
A pname value of GLCONVOLUTIONBORDERMODEEXT controls the convolution
border mode. Currently the only acceptable parameter value is
GLREDUCEEXT. When this mode is in effect, the image resulting from
convolution is smaller than the source image. If the filter width is Wf
and height is Hf, and the source image width is Ws and height is Hs, then
the convolved image width will be Ws-Wf+1 and height will be Hs-Hf+1.
(If this reduction would generate an image with zero or negative width
and/or height, the output is simply null, with no error generated.) The
coordinates of the image resulting from convolution are zero through Ws-
Wf in width and zero through Hs-Hf in height.
NOTES
In cases where errors can result from the specification of invalid image
dimensions, it is the dimensions after convolution that are tested, not
the dimensions of the source image. For example, glTexImage1D requires
power-of-two image size. When REDUCE_EXT border mode is in effect
(currently this is always true), the source image must be larger than the
final power-of-two size by one less than the size of the 1D filter
kernel.
ERRORS
GLINVALIDENUM is generated if target is not one of the allowable
values.
GLINVALIDENUM is generated if pname is not one of the allowable values.
GLINVALIDENUM is generated if pname is GLCONVOLUTIONBORDERMODEEXT
and params is not GLREDUCEEXT.
GLINVALIDOPERATION is generated if glConvolutionParameterEXT is
executed between the execution of glBegin and the corresponding execution
of glEnd.
ASSOCIATED GETS
glGetConvolutionParameterEXT
Page 2
glConvolutionParameterEXT(3G) OpenGL Reference glConvolutionParameterEXT(3G)
SEE ALSO
glConvolutionFilter1DEXT, glConvolutionFilter2DEXT,
glSeparableFilter2DEXT, glGetConvolutionParameterEXT.
Page 3