IndexBufferGL3

class IndexBufferGL3(val buffer: Int, val indexCount: Int, val type: IndexType, val session: Session?) : IndexBuffer(source)

Represents an OpenGL index buffer

This class encapsulates an index buffer object (IBO) used for storing index data in GPU memory, which is essential for indexed rendering in OpenGL. It provides methods to bind, unbind, write, read, and destroy the buffer.

Constructors

Link copied to clipboard
constructor(buffer: Int, indexCount: Int, type: IndexType, session: Session?)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
val buffer: Int

The OpenGL buffer ID.

Link copied to clipboard
open override val indexCount: Int

The number of indices in the buffer.

Link copied to clipboard
open override val session: Session?

The session associated with the index buffer, if any.

Link copied to clipboard
open override val type: IndexType

The type of indices stored in the buffer (e.g., INT16, INT32).

Functions

Link copied to clipboard
fun bind()
Link copied to clipboard
open override fun close()
Link copied to clipboard
open override fun destroy()
Link copied to clipboard
open override fun read(data: ByteBuffer, offsetInBytes: Int)
Link copied to clipboard
Link copied to clipboard
fun unbind()
Link copied to clipboard
open override fun write(data: ByteBuffer, offsetInBytes: Int)