All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
HgiGL Class Referencefinal

OpenGL implementation of the Hydra Graphics Interface. More...

+ Inheritance diagram for HgiGL:

Public Member Functions

HGIGL_API HgiGLDevice * GetPrimaryDevice () const
 
HGIGL_API
HgiGraphicsEncoderUniquePtr 
CreateGraphicsEncoder (HgiGraphicsEncoderDesc const &desc) override
 Returns a graphics encoder for temporary use that is ready to execute draw commands. More...
 
HGIGL_API HgiBlitEncoderUniquePtr CreateBlitEncoder () override
 Returns a blit encoder for temporary use that is ready to execute resource copy commands. More...
 
HGIGL_API HgiTextureHandle CreateTexture (HgiTextureDesc const &desc) override
 Create a texture in rendering backend. More...
 
HGIGL_API void DestroyTexture (HgiTextureHandle *texHandle) override
 Destroy a texture in rendering backend. More...
 
HGIGL_API HgiBufferHandle CreateBuffer (HgiBufferDesc const &desc) override
 Create a buffer in rendering backend. More...
 
HGIGL_API void DestroyBuffer (HgiBufferHandle *bufHandle) override
 Destroy a buffer in rendering backend. More...
 
HGIGL_API HgiShaderFunctionHandle CreateShaderFunction (HgiShaderFunctionDesc const &desc) override
 Create a new shader function. More...
 
HGIGL_API void DestroyShaderFunction (HgiShaderFunctionHandle *shaderFunctionHandle) override
 Destroy a shader function. More...
 
HGIGL_API HgiShaderProgramHandle CreateShaderProgram (HgiShaderProgramDesc const &desc) override
 Create a new shader program. More...
 
HGIGL_API void DestroyShaderProgram (HgiShaderProgramHandle *shaderProgramHandle) override
 Destroy a shader program. More...
 
HGIGL_API HgiResourceBindingsHandle CreateResourceBindings (HgiResourceBindingsDesc const &desc) override
 Create a new resource binding object. More...
 
HGIGL_API void DestroyResourceBindings (HgiResourceBindingsHandle *resHandle) override
 Destroy a resource binding object. More...
 
HGIGL_API HgiPipelineHandle CreatePipeline (HgiPipelineDesc const &pipeDesc) override
 Create a new pipeline state object. More...
 
HGIGL_API void DestroyPipeline (HgiPipelineHandle *pipeHandle) override
 Destroy a pipeline state object. More...
 
HGIGL_API TfToken const & GetAPIName () const override
 Return the name of the api (e.g. "OpenGL") More...
 
HGIGL_API void StartFrame () override
 Called at the start of a new rendering frame. More...
 
HGIGL_API void EndFrame () override
 Called at the end of a rendering frame. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from Hgi
static HGI_API HgiGetPlatformDefaultHgi ()
 Helper function to return a Hgi object for the current platform. More...
 
- Protected Member Functions inherited from Hgi
HGI_API uint64_t GetUniqueId ()
 
template<class T >
void DestroyObject (HgiHandle< T > *handle)
 

Detailed Description

OpenGL implementation of the Hydra Graphics Interface.

Definition at line 41 of file hgi.h.

Member Function Documentation

HGIGL_API HgiBlitEncoderUniquePtr CreateBlitEncoder ( )
overridevirtual

Returns a blit encoder for temporary use that is ready to execute resource copy commands.

BlitEncoder is a lightweight object that should be re-acquired each frame (don't hold onto it after EndEncoding). This blit encoder can only be used in a single thread.

Implements Hgi.

HGIGL_API HgiBufferHandle CreateBuffer ( HgiBufferDesc const &  desc)
overridevirtual

Create a buffer in rendering backend.

Implements Hgi.

HGIGL_API HgiGraphicsEncoderUniquePtr CreateGraphicsEncoder ( HgiGraphicsEncoderDesc const &  desc)
overridevirtual

Returns a graphics encoder for temporary use that is ready to execute draw commands.

GraphicsEncoder is a lightweight object that should be re-acquired each frame (don't hold onto it after EndEncoding). This encoder should only be used in the thread that created it.

Implements Hgi.

HGIGL_API HgiPipelineHandle CreatePipeline ( HgiPipelineDesc const &  pipeDesc)
overridevirtual

Create a new pipeline state object.

Implements Hgi.

HGIGL_API HgiResourceBindingsHandle CreateResourceBindings ( HgiResourceBindingsDesc const &  desc)
overridevirtual

Create a new resource binding object.

Implements Hgi.

HGIGL_API HgiShaderFunctionHandle CreateShaderFunction ( HgiShaderFunctionDesc const &  desc)
overridevirtual

Create a new shader function.

Implements Hgi.

HGIGL_API HgiShaderProgramHandle CreateShaderProgram ( HgiShaderProgramDesc const &  desc)
overridevirtual

Create a new shader program.

Implements Hgi.

HGIGL_API HgiTextureHandle CreateTexture ( HgiTextureDesc const &  desc)
overridevirtual

Create a texture in rendering backend.

Implements Hgi.

HGIGL_API void DestroyBuffer ( HgiBufferHandle bufHandle)
overridevirtual

Destroy a buffer in rendering backend.

Implements Hgi.

HGIGL_API void DestroyPipeline ( HgiPipelineHandle pipeHandle)
overridevirtual

Destroy a pipeline state object.

Implements Hgi.

HGIGL_API void DestroyResourceBindings ( HgiResourceBindingsHandle resHandle)
overridevirtual

Destroy a resource binding object.

Implements Hgi.

HGIGL_API void DestroyShaderFunction ( HgiShaderFunctionHandle shaderFunctionHandle)
overridevirtual

Destroy a shader function.

Implements Hgi.

HGIGL_API void DestroyShaderProgram ( HgiShaderProgramHandle shaderProgramHandle)
overridevirtual

Destroy a shader program.

Note that this does NOT automatically destroy the shader functions in the program since shader functions may be used by more than one program.

Implements Hgi.

HGIGL_API void DestroyTexture ( HgiTextureHandle texHandle)
overridevirtual

Destroy a texture in rendering backend.

Implements Hgi.

HGIGL_API void EndFrame ( )
inlineoverridevirtual

Called at the end of a rendering frame.

Implements Hgi.

Definition at line 110 of file hgi.h.

HGIGL_API TfToken const& GetAPIName ( ) const
overridevirtual

Return the name of the api (e.g. "OpenGL")

Implements Hgi.

HGIGL_API void StartFrame ( )
inlineoverridevirtual

Called at the start of a new rendering frame.

Implements Hgi.

Definition at line 107 of file hgi.h.


The documentation for this class was generated from the following file: