Interface GL2

All Superinterfaces:
GL
All Known Subinterfaces:
GL3, GL4
All Known Implementing Classes:
AndroidGL, IosGL, LwjglGL

public interface GL2 extends GL
GL functions only available on vanilla desktop OpenGL 2.
  • Field Details

  • Method Details

    • glAlphaFunc

      void glAlphaFunc(int func, float ref)

      Reference Page - This function is deprecated and unavailable in the Core profile

      The alpha test discards a fragment conditionally based on the outcome of a comparison between the incoming fragment’s alpha value and a constant value. The comparison is enabled or disabled with the generic Enable and Disable commands using the symbolic constant ALPHA_TEST. When disabled, it is as if the comparison always passes. The test is controlled with this method.
      Parameters:
      func - a symbolic constant indicating the alpha test function. One of: NEVER ALWAYS LESS LEQUAL EQUAL GEQUAL GREATER NOTEQUAL
      ref - a reference value clamped to the range [0, 1]. When performing the alpha test, the GL will convert the reference value to the same representation as the fragment's alpha value (floating-point or fixed-point).
    • glPointSize

      void glPointSize(float size)

      Reference Page

      Controls the rasterization of points if no vertex, tessellation control, tessellation evaluation, or geometry shader is active. The default point size is 1.0.

      Parameters:
      size - the request size of a point.
    • glPolygonMode

      void glPolygonMode(int face, int mode)

      Reference Page

      Controls the interpretation of polygons for rasterization.

      FILL is the default mode of polygon rasterization. Note that these modes affect only the final rasterization of polygons: in particular, a polygon's vertices are lit, and the polygon is clipped and possibly culled before these modes are applied. Polygon antialiasing applies only to the FILL state of PolygonMode. For POINT or LINE, point antialiasing or line segment antialiasing, respectively, apply.

      Parameters:
      face - the face for which to set the rasterizing method. One of: FRONT BACK FRONT_AND_BACK
      mode - the rasterization mode. One of: POINT LINE FILL
    • glDrawBuffer

      void glDrawBuffer(int mode)

      Reference Page

      Defines the color buffer to which fragment color zero is written.

      Parameters:
      mode - the color buffer to draw to.
    • glReadBuffer

      void glReadBuffer(int mode)

      Reference Page

      Defines the color buffer from which values are obtained.

      Parameters:
      mode - the color buffer to read from.
    • glCompressedTexImage3D

      void glCompressedTexImage3D(int target, int level, int internalFormat, int width, int height, int depth, int border, ByteBuffer data)

      Reference Page

      Specifies a three-dimensional texture image in a compressed format.

      Parameters:
      target - the target texture.
      level - the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image.
      internalFormat - the format of the compressed image data.
      width - the width of the texture image
      height - the height of the texture image
      depth - the depth of the texture image
      border - must be 0
      data - a pointer to the compressed image data
    • glCompressedTexSubImage3D

      void glCompressedTexSubImage3D(int target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, ByteBuffer data)

      Reference Page

      Respecifies only a cubic subregion of an existing 3D texel array, with incoming data stored in a specific compressed image format.

      Parameters:
      target - the target texture.
      level - the level-of-detail number. Level 0 is the base image level. Level n is the nth mipmap reduction image.
      xoffset - a texel offset in the x direction within the texture array.
      yoffset - a texel offset in the y direction within the texture array.
      zoffset - a texel offset in the z direction within the texture array.
      width - the width of the texture subimage.
      height - the height of the texture subimage.
      depth - the depth of the texture subimage.
      format - the format of the compressed image data stored at address data.
      data - a pointer to the compressed image data.
    • glTexImage3D

      void glTexImage3D(int target, int level, int internalFormat, int width, int height, int depth, int border, int format, int type, ByteBuffer data)

      Reference Page

      Specifies a three-dimensional texture image.

      Parameters:
      target - the texture target.
      level - the level-of-detail number.
      internalFormat - the texture internal format.
      width - the texture width.
      height - the texture height.
      depth - the texture depth.
      border - the texture border width.
      format - the texel data format.
      type - the texel data type.
      data - the texel data.
    • glTexSubImage3D

      void glTexSubImage3D(int target, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int format, int type, ByteBuffer data)

      Reference Page

      Respecifies a cubic subregion of an existing 3D texel array. No change is made to the internalformat, width, height, depth, or border parameters of the specified texel array, nor is any change made to texel values outside the specified subregion.

      Parameters:
      target - the texture target.
      level - the level-of-detail-number.
      xoffset - the x coordinate of the texel subregion.
      yoffset - the y coordinate of the texel subregion.
      zoffset - the z coordinate of the texel subregion.
      width - the subregion width.
      height - the subregion height.
      depth - the subregion depth.
      format - the pixel data format.
      type - the pixel data type.
      data - the pixel data.