1
1
Fork 0
mirror of https://github.com/QB64-Phoenix-Edition/QB64pe.git synced 2024-07-01 13:50:36 +00:00
QB64-PE/internal/help/_glTexSubImage1D__001001001000011.txt
Roland Heyder aeb9c0668b Updates help files for use with new Wiki parser (2nd try)
Note: Many files were removed (not yet existing/empty pages). The parser will try to download them on demand and will auto-generate text for missing pages (eg. most _gl pages).
2022-05-21 00:18:31 +02:00

86 lines
4.8 KiB
Plaintext

{{QBDLDATE:05-20-2022}}
{{QBDLTIME:23:24:01}}
'''_glTexSubImage1D:''' specify a one-dimensional texture subimage
{{PageSyntax}}
SUB _glTexSubImage1D (BYVAL target AS _UNSIGNED LONG, BYVAL level AS LONG, BYVAL xoffset AS LONG, BYVAL width AS LONG, BYVAL format AS _UNSIGNED LONG, BYVAL type AS _UNSIGNED LONG, pixels AS _OFFSET)
void '''_glTexSubImage1D'''(GLenum {{Parameter|target}}, GLint {{Parameter|level}}, GLint {{Parameter|xoffset}}, GLsizei {{Parameter|width}}, GLenum {{Parameter|format}}, GLenum {{Parameter|type}}, const GLvoid * {{Parameter|data}});
; target
: Specifies the target texture. Must be {{KW|_GL_TEXTURE_1D}}.
; level
: Specifies the level-of-detail number. Level 0 is the base image level. Level ''n'' is the ''n''th mipmap reduction image.
; xoffset
: Specifies a texel offset in the x direction within the texture array.
; width
: Specifies the width of the texture subimage.
{{glapi pixeltransferupparams}}
{{PageDescription}}
Texturing maps a portion of a specified texture image onto each graphical primitive for which texturing is enabled. To enable or disable one-dimensional texturing, call {{KW|_glEnable}} and {{KW|_glDisable}} with argument {{KW|_GL_TEXTURE_1D}}.
'''_glTexSubImage1D''' redefines a contiguous subregion of an existing one-dimensional texture image. The texels referenced by {{Parameter|data}} replace the portion of the existing texture array with x indices {{Parameter|xoffset}} and xoffset + width - 1, inclusive. This region may not include any texels outside the range of the texture array as it was originally specified. It is not an error to specify a subtexture with width of 0, but such a specification has no effect.
If a non-zero named buffer object is bound to the {{KW|_GL_PIXEL_UNPACK_BUFFER}} target (see {{KW|_glBindBuffer}}) while a texture image is specified, {{Parameter|data}} is treated as a byte offset into the buffer object's data store.
{{PageNotes}}
{{KW|_glPixelStore}} modes affect texture images.
'''_glTexSubImage1D''' specifies a one-dimensional subtexture for the current texture unit, specified with {{KW|_glActiveTexture}}.
{{PageErrors}}
{{KW|_GL_INVALID_ENUM}} is generated if {{Parameter|target}} is not one of the allowable values.
{{KW|_GL_INVALID_ENUM}} is generated if {{Parameter|format}} is not an accepted format constant.
{{KW|_GL_INVALID_ENUM}} is generated if {{Parameter|type}} is not a type constant.
{{KW|_GL_INVALID_VALUE}} is generated if {{Parameter|level}} is less than 0.
{{KW|_GL_INVALID_VALUE}} may be generated if {{Parameter|level}} is greater than log<sub>2</sub>(''max''), where ''max'' is the returned value of {{KW|_GL_MAX_TEXTURE_SIZE}}.
{{KW|_GL_INVALID_VALUE}} is generated if ''xoffset'' < 0, or if ''xoffset'' + ''width'' > ''w'', where ''w'' is the {{KW|_GL_TEXTURE_WIDTH}}. Note that ''w'' includes twice the border width.
{{KW|_GL_INVALID_VALUE}} is generated if {{Parameter|width}} is less than 0.
{{KW|_GL_INVALID_OPERATION}} is generated if the texture array has not been defined by a previous {{KW|_glTexImage1D}} operation.
{{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|type}} is one of {{KW|_GL_UNSIGNED_BYTE_3_3_2}}, {{KW|_GL_UNSIGNED_BYTE_2_3_3_REV}}, {{KW|_GL_UNSIGNED_SHORT_5_6_5}}, or {{KW|_GL_UNSIGNED_SHORT_5_6_5_REV}} and {{Parameter|format}} is not {{KW|_GL_RGB}}.
{{KW|_GL_INVALID_OPERATION}} is generated if {{Parameter|type}} is one of {{KW|_GL_UNSIGNED_SHORT_4_4_4_4}}, {{KW|_GL_UNSIGNED_SHORT_4_4_4_4_REV}}, {{KW|_GL_UNSIGNED_SHORT_5_5_5_1}}, {{KW|_GL_UNSIGNED_SHORT_1_5_5_5_REV}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8}}, {{KW|_GL_UNSIGNED_INT_8_8_8_8_REV}}, {{KW|_GL_UNSIGNED_INT_10_10_10_2}}, or {{KW|_GL_UNSIGNED_INT_2_10_10_10_REV}} and {{Parameter|format}} is neither {{KW|_GL_RGBA}} nor {{KW|_GL_BGRA}}.
{{KW|_GL_INVALID_OPERATION}} is generated if a non-zero buffer object name is bound to the {{KW|_GL_PIXEL_UNPACK_BUFFER}} target and the buffer object's data store is currently mapped.
{{KW|_GL_INVALID_OPERATION}} is generated if a non-zero buffer object name is bound to the {{KW|_GL_PIXEL_UNPACK_BUFFER}} target and the data would be unpacked from the buffer object such that the memory reads required would exceed the data store size.
{{KW|_GL_INVALID_OPERATION}} is generated if a non-zero buffer object name is bound to the {{KW|_GL_PIXEL_UNPACK_BUFFER}} target and {{Parameter|data}} is not evenly divisible into the number of bytes needed to store in memory a datum indicated by {{Parameter|type}}.
{{PageUseWith}}
{{KW|_glGetTexImage}}
{{KW|_glGet}} with argument {{KW|_GL_PIXEL_UNPACK_BUFFER_BINDING}}
{{PageSeeAlso}}
[[_GL|SUB _GL]]
{{KW|_glActiveTexture}}, {{KW|_glBindTexture}}, {{KW|_glTexSubImage2D}}, {{KW|_glTexSubImage3D}}, {{KW|_glCopyTexImage1D}}, {{KW|_glTexImage1D}}, {{KW|_glTexStorage1D}}, {{KW|_glTextureView}}, {{KW|_glPixelStore}}
{{PageCopyright}}
{{PageNavigation}}