Class GLClassExtensions
Class extensions that are used by OpenGL rendering backends.
public static class GLClassExtensions
- Inheritance
-
GLClassExtensions
- Inherited Members
Methods
GetBufferUsageHint(BufferMode)
Get the buffer usage hint for a certain buffer mode.
public static BufferUsage GetBufferUsageHint(this BufferMode mode)
Parameters
modeBufferModeThe buffer mode.
Returns
- BufferUsage
OpenGL buffer usage hints.
GetGLBuffer(BufferResource)
Get the GL buffer associated with this buffer resource.
public static GLObject GetGLBuffer(this BufferResource buffer)
Parameters
bufferBufferResourceThe buffer resource to get the GL buffer for.
Returns
- GLObject
The GLObject that tracks the GL buffer.
Exceptions
- Exception
The buffer resource has no memory associated with it.
SetVertexAttrib(AttributeBindingEx, int)
public static void SetVertexAttrib(this AttributeBindingEx binding, int location)
Parameters
bindingAttributeBindingExlocationint
ToDrawElementsType(ElementBufferType)
public static DrawElementsType ToDrawElementsType(this ElementBufferType type)
Parameters
typeElementBufferType
Returns
ToVertexAttribPointerType(AttributeType)
Convert ReFuel AttributeType to OpenGL VertexAttribPointerType.
public static VertexAttribPointerType ToVertexAttribPointerType(this AttributeType type)
Parameters
typeAttributeTypeThe vertex attribute value type.
Returns
- VertexAttribPointerType
The OpenGL vertex attribute value type.
Exceptions
- ArgumentOutOfRangeException
Unrecognized vertex attribute type.