GLMAPINVALIDATERANGEBIT
GL_MAP_INVALIDATE_RANGE_BIT is a bit flag used in OpenGL as part of the glMapBufferRange API. It indicates that the contents of the specified range of a buffer’s data store may be discarded when the mapping occurs, allowing the implementation to avoid preserving or reading the previous data for that range.
When mapping a buffer, this flag is typically combined with other map options such as GL_MAP_WRITE_BIT. The
Usage considerations include ensuring that the mapped range is entirely within the bounds of the buffer, and
Compatibility and origin: GL_MAP_INVALIDATE_RANGE_BIT is part of the ARB_map_buffer_range extension and is supported in OpenGL core
Example: glMapBufferRange(GL_ARRAY_BUFFER, offset, length, GL_MAP_WRITE_BIT | GL_MAP_INVALIDATE_RANGE_BIT); followed by writes to the returned pointer, and glUnmapBuffer(GL_ARRAY_BUFFER).