'\" t .\" Title: glUnmapBuffer .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: 01/03/2018 .\" Manual: [FIXME: manual] .\" Source: [FIXME: source] .\" Language: English .\" .TH "GLUNMAPBUFFER" "3G" "01/03/2018" "[FIXME: source]" "[FIXME: manual]" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" glUnmapBuffer, glUnmapNamedBuffer \- release the mapping of a buffer object\*(Aqs data store into the client\*(Aqs address space .SH "C SPECIFICATION" .HP \w'GLboolean\ glUnmapBuffer('u .BI "GLboolean glUnmapBuffer(GLenum\ " "target" ");" .HP \w'GLboolean\ glUnmapNamedBuffer('u .BI "GLboolean glUnmapNamedBuffer(GLuint\ " "buffer" ");" .SH "PARAMETERS" .PP \fItarget\fR .RS 4 Specifies the target to which the buffer object is bound for \fBglUnmapBuffer\fR, which must be one of the buffer binding targets in the following table: .TS allbox tab(:); lB lB. T{ \fBBuffer Binding Target\fR T}:T{ \fBPurpose\fR T} .T& l l l l l l l l l l l l l l l l l l l l l l l l l l l l. T{ \fBGL_ARRAY_BUFFER\fR T}:T{ Vertex attributes T} T{ \fBGL_ATOMIC_COUNTER_BUFFER\fR T}:T{ Atomic counter storage T} T{ \fBGL_COPY_READ_BUFFER\fR T}:T{ Buffer copy source T} T{ \fBGL_COPY_WRITE_BUFFER\fR T}:T{ Buffer copy destination T} T{ \fBGL_DISPATCH_INDIRECT_BUFFER\fR T}:T{ Indirect compute dispatch commands T} T{ \fBGL_DRAW_INDIRECT_BUFFER\fR T}:T{ Indirect command arguments T} T{ \fBGL_ELEMENT_ARRAY_BUFFER\fR T}:T{ Vertex array indices T} T{ \fBGL_PIXEL_PACK_BUFFER\fR T}:T{ Pixel read target T} T{ \fBGL_PIXEL_UNPACK_BUFFER\fR T}:T{ Texture data source T} T{ \fBGL_QUERY_BUFFER\fR T}:T{ Query result buffer T} T{ \fBGL_SHADER_STORAGE_BUFFER\fR T}:T{ Read\-write storage for shaders T} T{ \fBGL_TEXTURE_BUFFER\fR T}:T{ Texture data buffer T} T{ \fBGL_TRANSFORM_FEEDBACK_BUFFER\fR T}:T{ Transform feedback buffer T} T{ \fBGL_UNIFORM_BUFFER\fR T}:T{ Uniform block storage T} .TE .sp 1 .RE .PP \fIbuffer\fR .RS 4 Specifies the name of the buffer object for \fBglUnmapNamedBuffer\fR\&. .RE .SH "DESCRIPTION" .PP \fBglUnmapBuffer\fR and \fBglUnmapNamedBuffer\fR unmap (release) any mapping of a specified buffer object into the client\*(Aqs address space (see \fBglMapBufferRange\fR() and \fBglMapBuffer\fR())\&. .PP If a mapping is not unmapped before the corresponding buffer object\*(Aqs data store is used by the GL, an error will be generated by any GL command that attempts to dereference the buffer object\*(Aqs data store, unless the buffer was successfully mapped with \fBGL_MAP_PERSISTENT_BIT\fR (see \fBglMapBufferRange\fR())\&. When a data store is unmapped, the mapped pointer becomes invalid\&. .PP \fBglUnmapBuffer\fR returns \fBGL_TRUE\fR unless the data store contents have become corrupt during the time the data store was mapped\&. This can occur for system\-specific reasons that affect the availability of graphics memory, such as screen mode changes\&. In such situations, \fBGL_FALSE\fR is returned and the data store contents are undefined\&. An application must detect this rare condition and reinitialize the data store\&. .PP A buffer object\*(Aqs mapped data store is automatically unmapped when the buffer object is deleted or its data store is recreated with \fBglBufferData\fR())\&. .SH "NOTES" .PP If an error is generated, \fBglUnmapBuffer\fR returns \fBGL_FALSE\fR\&. .PP The \fBGL_ATOMIC_COUNTER_BUFFER\fR target is accepted only if the GL version is 4\&.2 or greater\&. .PP The \fBGL_DISPATCH_INDIRECT_BUFFER\fR and \fBGL_SHADER_STORAGE_BUFFER\fR targets are available only if the GL version is 4\&.3 or greater\&. .PP The \fBGL_QUERY_BUFFER\fR target is available only if the GL version is 4\&.4 or greater\&. .SH "ERRORS" .PP \fBGL_INVALID_ENUM\fR is generated by \fBglUnmapBuffer\fR if \fItarget\fR is not one of the buffer binding targets listed above\&. .PP \fBGL_INVALID_OPERATION\fR is generated by \fBglUnmapBuffer\fR if zero is bound to \fItarget\fR\&. .PP \fBGL_INVALID_OPERATION\fR is generated by \fBglUnmapNamedBuffer\fR if \fIbuffer\fR is not the name of an existing buffer object\&. .PP \fBGL_INVALID_OPERATION\fR is generated if the buffer object is not in a mapped state\&. .SH "ASSOCIATED GETS" .PP \fBglGetBufferParameter\fR() with argument \fBGL_BUFFER_MAPPED\fR\&. .SH "VERSION SUPPORT" .TS allbox tab(:); lB cB s s s s s s s s s s s lB cB cB cB cB cB cB cB cB cB cB cB cB. T{ T}:T{ \fBOpenGL Version\fR T} T{ \fBFunction / Feature Name\fR T}:T{ \fB2\&.0\fR T}:T{ \fB2\&.1\fR T}:T{ \fB3\&.0\fR T}:T{ \fB3\&.1\fR T}:T{ \fB3\&.2\fR T}:T{ \fB3\&.3\fR T}:T{ \fB4\&.0\fR T}:T{ \fB4\&.1\fR T}:T{ \fB4\&.2\fR T}:T{ \fB4\&.3\fR T}:T{ \fB4\&.4\fR T}:T{ \fB4\&.5\fR T} .T& l c c c c c c c c c c c c l c c c c c c c c c c c c. T{ \fBglUnmapBuffer\fR T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T} T{ \fBglUnmapNamedBuffer\fR T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ ✔ T} .TE .sp 1 .SH "SEE ALSO" .PP \fBglBufferData\fR(), \fBglDeleteBuffers\fR(), \fBglMapBuffer\fR(), \fBglMapBufferRange\fR() .SH "COPYRIGHT" .PP Copyright \(co 2005 Addison\-Wesley\&. Copyright \(co 2010\-2014 Khronos Group\&. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1\&.0, 8 June 1999\&. \m[blue]\fBhttp://opencontent\&.org/openpub/\fR\m[]\&. .SH "COPYRIGHT" .br Copyright \(co 2005 Addison-Wesley Group .br Copyright \(co 2010-2014 Khronos Group .br