C SPECIFICATION

       void GLAPIENTRY glTexParameterf( GLenum target,
                                        GLenum pname,
                                        GLfloat param )
       void GLAPIENTRY glTexParameteri( GLenum target,
                                        GLenum pname,
                                        GLint param )



PARAMETERS

       target  Specifies  the   target   texture,   which   must   be   either
               GL_TEXTURE_1D, GL_TEXTURE_2D, or GL_TEXTURE_3D.

       pname   Specifies  the symbolic name of a single-valued texture parame-
               ter.  pname can be one of the following: GL_TEXTURE_MIN_FILTER,
               GL_TEXTURE_MAG_FILTER,  GL_TEXTURE_MIN_LOD, GL_TEXTURE_MAX_LOD,
               GL_TEXTURE_BASE_LEVEL, GL_TEXTURE_MAX_LEVEL, GL_TEXTURE_WRAP_S,
               GL_TEXTURE_WRAP_T, GL_TEXTURE_WRAP_R, or GL_TEXTURE_PRIORITY.

       param   Specifies the value of pname.


C SPECIFICATION

       void GLAPIENTRY glTexParameterfv( GLenum target,
                                         GLenum pnam )
       void GLAPIENTRY glTexParameteriv( GLenum target,
                                         GLenum pnam )



PARAMETERS

       target Specifies   the   target   texture,   which   must   be   either
              GL_TEXTURE_1D, GL_TEXTURE_2D or GL_TEXTURE_3D.

       pnam   Specifies the symbolic name of a texture parameter.  pnam can be
              one      of      the      following:      GL_TEXTURE_MIN_FILTER,
              GL_TEXTURE_MAG_FILTER,  GL_TEXTURE_MIN_LOD,  GL_TEXTURE_MAX_LOD,
              GL_TEXTURE_BASE_LEVEL,  GL_TEXTURE_MAX_LEVEL, GL_TEXTURE_WRAP_S,
              GL_TEXTURE_WRAP_T,  GL_TEXTURE_WRAP_R,  GL_TEXTURE_BORDER_COLOR,
              or GL_TEXTURE_PRIORITY.


       Specifies a pointer to an array where the value or values of pnam
              are stored.


DESCRIPTION

       Texture  mapping  is a technique that applies an image onto an object's
       surface as if the image were a decal or  cellophane  shrink-wrap.   The
       image is created in texture space, with an (s, t) coordinate system.  A
       texture is a one- or two-dimensional image and a set of parameters that
       determine how samples are derived from the image.

                 dimensions 2nx2m, there are max(n,m)+1  mipmaps.   The  first
                 mipmap  is the original texture, with dimensions 2nx2m.  Each
                 subsequent mipmap has dimensions 2k-1x2l-1, where  2kx2l  are
                 the  dimensions  of  the previous mipmap, until either k=0 or
                 l=0.  At that point, subsequent mipmaps have dimension 1x2l-1
                 or  2k-1x1  until  the final mipmap, which has dimension 1x1.
                 To  define  the  mipmaps,  call  glTexImage1D,  glTexImage2D,
                 glTexImage3D,  glCopyTexImage1D, or glCopyTexImage2D with the
                 level argument indicating the order of the mipmaps.  Level  0
                 is  the  original  texture;  level  max(n,m) is the final 1x1
                 mipmap.

                  supplies a function for minifying the texture as one of  the
                 following:

                 GL_NEAREST
                           Returns  the  value  of the texture element that is
                           nearest (in Manhattan distance) to  the  center  of
                           the pixel being textured.

                 GL_LINEAR Returns  the  weighted  average of the four texture
                           elements that are closest  to  the  center  of  the
                           pixel  being  textured.   These  can include border
                           texture  elements,  depending  on  the  values   of
                           GL_TEXTURE_WRAP_S and GL_TEXTURE_WRAP_T, and on the
                           exact mapping.

                 GL_NEAREST_MIPMAP_NEAREST
                           Chooses the mipmap that most  closely  matches  the
                           size  of  the  pixel  being  textured  and uses the
                           GL_NEAREST criterion (the texture  element  nearest
                           to  the  center  of the pixel) to produce a texture
                           value.

                 GL_LINEAR_MIPMAP_NEAREST
                           Chooses the mipmap that most  closely  matches  the
                           size  of  the  pixel  being  textured  and uses the
                           GL_LINEAR criterion (a weighted average of the four
                           texture  elements that are closest to the center of
                           the pixel) to produce a texture value.

                 GL_NEAREST_MIPMAP_LINEAR
                           Chooses the two mipmaps that most closely match the
                           size  of  the  pixel  being  textured  and uses the
                           GL_NEAREST criterion (the texture  element  nearest
                           to  the  center  of the pixel) to produce a texture
                           value from each mipmap.  The final texture value is
                           a weighted average of those two values.

                 GL_LINEAR_MIPMAP_LINEAR
                           Chooses the two mipmaps that most closely match the
                           size of the  pixel  being  textured  and  uses  the

       GL_TEXTURE_MAG_FILTER
                 The texture magnification function is  used  when  the  pixel
                 being textured maps to an area less than or equal to one tex-
                 ture element.  It sets the texture magnification function  to
                 either  GL_NEAREST  or  GL_LINEAR  (see below). GL_NEAREST is
                 generally faster than GL_LINEAR, but it can produce  textured
                 images with sharper edges because the transition between tex-
                 ture elements  is  not  as  smooth.   The  initial  value  of
                 GL_TEXTURE_MAG_FILTER is GL_LINEAR.

                 GL_NEAREST
                           Returns  the  value  of the texture element that is
                           nearest (in Manhattan distance) to  the  center  of
                           the pixel being textured.

                 GL_LINEAR Returns  the  weighted  average of the four texture
                           elements that are closest  to  the  center  of  the
                           pixel  being  textured.   These  can include border
                           texture  elements,  depending  on  the  values   of
                           GL_TEXTURE_WRAP_S and GL_TEXTURE_WRAP_T, and on the
                           exact mapping.



       GL_TEXTURE_MIN_LOD
                 Sets the minimum level-of-detail parameter.   This  floating-
                 point value limits the selection of highest resolution mipmap
                 (lowest mipmap level). The initial value is -1000.


       GL_TEXTURE_MAX_LOD
                 Sets the maximum level-of-detail parameter.   This  floating-
                 point  value  limits  the  selection of the lowest resolution
                 mipmap (highest mipmap level). The initial value is 1000.


       GL_TEXTURE_BASE_LEVEL
                 Specifies the index of the lowest defined mipmap level.  This
                 is an integer value. The initial value is 0.


       GL_TEXTURE_MAX_LEVEL
                 Sets  the  index of the highest defined mipmap level. This is
                 an integer value. The initial value is 1000.


       GL_TEXTURE_WRAP_S
                 Sets the wrap parameter for texture coordinate  s  to  either
                 GL_CLAMP,  GL_CLAMP_TO_EDGE, or GL_REPEAT.  GL_CLAMP causes s
                 coordinates to be clamped to the range [0,1]  and  is  useful
                 for preventing wrapping artifacts when mapping a single image
                 to GL_REPEAT.

       GL_TEXTURE_WRAP_R
                 Sets the wrap parameter for texture coordinate  r  to  either
                 GL_CLAMP, GL_CLAMP_TO_EDGE, or GL_REPEAT.  See the discussion
                 under GL_TEXTURE_WRAP_S.  Initially, GL_TEXTURE_WRAP_R is set
                 to GL_REPEAT.

       GL_TEXTURE_BORDER_COLOR
                 Sets a border color.
                  contains  four  values  that  comprise the RGBA color of the
                 texture border.  Integer  color  components  are  interpreted
                 linearly such that the most positive integer maps to 1.0, and
                 the most negative integer  maps  to  -1.0.   The  values  are
                 clamped  to  the  range  [0,1] when they are specified.  Ini-
                 tially, the border color is (0, 0, 0, 0).

       GL_TEXTURE_PRIORITY
                 Specifies the texture residence  priority  of  the  currently
                 bound  texture.   Permissible values are in the range [0, 1].
                 See glPrioritizeTextures and glBindTexture for more  informa-
                 tion.


NOTES

       GL_TEXTURE_3D,          GL_TEXTURE_MIN_LOD,         GL_TEXTURE_MAX_LOD,
       GL_TEXTURE_BASE_LEVEL, and GL_TEXTURE_MAX_LEVEL are only  available  if
       the GL version is 1.2 or greater.

       Suppose  that a program has enabled texturing (by calling glEnable with
       argument GL_TEXTURE_1D, GL_TEXTURE_2D, or GL_TEXTURE_3D)  and  has  set
       GL_TEXTURE_MIN_FILTER  to  one of the functions that requires a mipmap.
       If either the dimensions of the texture images currently defined  (with
       previous    calls    to   glTexImage1D,   glTexImage2D,   glTexImage3D,
       glCopyTexImage1D,  or  glCopyTexImage2D)  do  not  follow  the   proper
       sequence  for  mipmaps  (described  above),  or there are fewer texture
       images defined than are needed, or the set of texture images have  dif-
       fering  numbers of texture components, then it is as if texture mapping
       were disabled.

       Linear filtering accesses the four nearest texture elements only in  2D
       textures.   In  1D  textures, linear filtering accesses the two nearest
       texture elements.

       When the GL_ARB_multitexture  extension  is  supported,  glTexParameter
       specifies the texture parameters for the active texture unit, specified
       by calling glActiveTextureARB.


ERRORS

       GL_INVALID_ENUM is generated if target  or  pnam  is  not  one  of  the
       accepted defined values.

       GL_INVALID_ENUM  is  generated if  should have a defined constant value
       glTexImage3D, glTexSubImage1D, glTexSubImage2D, glTexSubImage3D





                                                            GLTEXPARAMETER(3G)

Man(1) output converted with man2html