class GpuProgram

Inherits: IReflectable

Contains a GPU program such as vertex or fragment program which gets compiled from the provided source code.

Public

Methods

~GpuProgram

virtual ~GpuProgram() noexcept

Initialize

virtual void Initialize()

Initializes the object.

The object should not be used before this is called.

IsSupported

virtual bool IsSupported() const

Returns whether this program can be supported on the current renderer and hardware.

IsCompiled

virtual bool IsCompiled() const

Returns true if program was successfully compiled.

GetCompileErrorMessage

virtual String GetCompileErrorMessage() const

Returns an error message returned by the compiler, if the compilation failed.

SetAdjacencyInfoRequired

virtual void SetAdjacencyInfoRequired(bool required)

Sets whether this geometry program requires adjacency information from the input primitives.

IsAdjacencyInfoRequired

virtual bool IsAdjacencyInfoRequired() const

Returns whether this geometry program requires adjacency information from the input primitives.

GetType

GpuProgramType GetType() const

Type of GPU program (for example fragment, vertex).

GetParameterDescription

SPtr<GpuProgramParameterDescription> GetParameterDescription() const

Returns description of all parameters in this GPU program.

GetVertexInputDescription

SPtr<VertexDescription> GetVertexInputDescription() const

Returns a list of vertex elements that a vertex program expects as inputs.

Only relevant for vertex programs.

GetBytecode

SPtr<GpuProgramBytecode> GetBytecode() const

Returns the compiled bytecode of this program.

staticGetRttiStatic

static RTTIType *GetRttiStatic()

GetRtti

RTTIType *GetRtti() const override

Returns an interface you can use to access class' Run Time Type Information.

Protected

Constructors

GpuProgram

GpuProgram(const GpuProgramCreateInformation &createInformation)

Fields

mNeedsAdjacencyInfo

bool mNeedsAdjacencyInfo

mIsCompiled

bool mIsCompiled

mCompileMessages

String mCompileMessages

mParametersDescription

SPtr<GpuProgramParameterDescription> mParametersDescription

mVertexInputDescription

SPtr<VertexDescription> mVertexInputDescription

mType

mLanguage

String mLanguage

mName

String mName

mEntryPoint

String mEntryPoint

mSource

String mSource

mBytecode

SPtr<GpuProgramBytecode> mBytecode