GLContext

Description

abstract class Tinman.Engine.API.GLContext

Derived from

GraphicsContext abstract
IRenderContextDependent

Extended by

OpenGLContext sealed
OpenGLESContext sealed

Abstract base class for IGraphicsContext implementations that use a GL-style API.

Public / Attributes

Debug​Frequent​Error​Checks


[DebugHelper] [ShutdownClear]
public static attribute DebugFrequentErrorChecks → (bool)

Perform GL error checks with GLBase.ErrorReset2 more often?

Protected / Constructors

GLContext


protected constructor GLContext → (3)

name in : string

[not-empty]
See IGraphicsContext.Name.

renderContext in : RenderContext own

[not-null]
The GL render context.

multiSample in : MultiSampleType

The maximum multi-sample setting to use.

Creates a new instance of GraphicsContext.

Protected / Methods

Compute​Video​Memory


[Pure]
protected method ComputeVideoMemory → (1)

memory in : int32

The video memory size that has been provided externally (in megabytes) or 0 to try to determine the amount of video memory automatically.

returns → int32

The amount of video memory, in megabytes.

Computes the amount of available video memory.

Frame​Buffer​Apply


protected method FrameBufferApply → (1)

targets in : RenderTargets

The render target set.

Applies the given render targets in.

Frame​Buffer​Object​Create


[OwnerReturn]
protected abstract method FrameBufferObjectCreate → (1)

targets in : RenderTargets

The render target set.

returns → int32

The framebuffer object.

Creates a framebuffer object for the given render target set.

Frame​Buffer​Object​Delete


protected abstract method FrameBufferObjectDelete → (1)

fbo in : int32 own

The framebuffer object.

Deletes the given framebuffer object.

Frame​Buffer​Object​Set


protected abstract method FrameBufferObjectSet → (1)

fbo in : int32

The framebuffer object or 0 for the default framebuffer.

Applies the given framebuffer object for subsequent use.

Input​Layout​Apply_​Buffer


protected method InputLayoutApply_Buffer → (3)

buffer in : IGeometryBuffer

The mapping or null.

instanceCount in : int32

The instance count.

firstInstance in : int32

The base instance.

returns → RangeI

The instance range or RangeI.Zero if the geometry is not instanced.

Applies the given buffer in to the input layout.

Vertex​Array​Object​Create


[OwnerReturn]
protected abstract method VertexArrayObjectCreate → (3)

buffer in : IGeometryBuffer

The geometry buffer (vertex / index buffer)..

program in : int32

The program name (vertex attribute locations).

mapping in : Mapping2D<int32>

Mapping between vertex elements and attribute location.

returns → int32

The created vertex array object.

Creates a vertex array object for the given input.

Vertex​Array​Object​Delete


protected abstract method VertexArrayObjectDelete → (1)

vao in : int32 own

The vertex array object.

Deletes the given vertex array object.

Vertex​Array​Object​Set


protected abstract method VertexArrayObjectSet → (1)

vao in : int32

The vertex array object or 0 for none.

Applies the given vertex array object for subsequent use.

Protected / Attributes

multi​Sample


protected attribute multiSample → (int32)

The maximum multi-sample count or 0 if multi-sampling is not available.

render​Context


[Owner]
protected attribute renderContext → (RenderContext)

The GL render context.