Gazebo Gui

API Reference

8.3.0
RenderThreadRhiOpenGL Class Reference

Implementation of RenderThreadRhi for the OpenGL graphics API. More...

#include <MinimalSceneRhiOpenGL.hh>

Public Member Functions

 RenderThreadRhiOpenGL (GzRenderer *_renderer)
 Constructor. More...
 
virtual ~RenderThreadRhiOpenGL () override
 
virtual QOpenGLContext * Context () const override
 OpenGL context to be passed to the render engine. More...
 
virtual std::string Initialize () override
 Carry out initialization. More...
 
virtual void RenderNext (RenderSync *_renderSync) override
 Render when safe. More...
 
virtual void SetContext (QOpenGLContext *_context) override
 Set the OpenGL context to be passed to the render engine. More...
 
virtual void SetSurface (QOffscreenSurface *_surface) override
 Set the offscreen surface to render to. More...
 
virtual void ShutDown () override
 Shutdown the thread and the render engine. More...
 
virtual QOffscreenSurface * Surface () const override
 Offscreen surface to render to. More...
 
virtual void * TexturePtr () const override
 Return a pointer to the graphics API texture Id. More...
 
virtual QSize TextureSize () const override
 Return the size of the texture. More...
 
virtual void Update (rendering::CameraPtr _camera) override
 Update the texture for a camera. More...
 
- Public Member Functions inherited from RenderThreadRhi
virtual ~RenderThreadRhi ()
 Destructor. More...
 

Detailed Description

Implementation of RenderThreadRhi for the OpenGL graphics API.

Constructor & Destructor Documentation

◆ ~RenderThreadRhiOpenGL()

virtual ~RenderThreadRhiOpenGL ( )
overridevirtual

◆ RenderThreadRhiOpenGL()

RenderThreadRhiOpenGL ( GzRenderer _renderer)
explicit

Constructor.

Parameters
[in]_rendererThe gz-rendering renderer

Member Function Documentation

◆ Context()

virtual QOpenGLContext* Context ( ) const
overridevirtual

OpenGL context to be passed to the render engine.

Reimplemented from RenderThreadRhi.

◆ Initialize()

virtual std::string Initialize ( )
overridevirtual

Carry out initialization.

On macOS this must be run on the main thread

Returns
Error message if initialization failed. If empty, no errors occurred.

Implements RenderThreadRhi.

◆ RenderNext()

virtual void RenderNext ( RenderSync *  _renderSync)
overridevirtual

Render when safe.

Parameters
[in]_renderSyncRenderSync to safely synchronize Qt and worker thread (this)

Implements RenderThreadRhi.

◆ SetContext()

virtual void SetContext ( QOpenGLContext *  _context)
overridevirtual

Set the OpenGL context to be passed to the render engine.

Parameters
[in]_contextOpenGL context

Reimplemented from RenderThreadRhi.

◆ SetSurface()

virtual void SetSurface ( QOffscreenSurface *  _surface)
overridevirtual

Set the offscreen surface to render to.

Parameters
[in]_surfaceOff-screen surface format

Reimplemented from RenderThreadRhi.

◆ ShutDown()

virtual void ShutDown ( )
overridevirtual

Shutdown the thread and the render engine.

Implements RenderThreadRhi.

◆ Surface()

virtual QOffscreenSurface* Surface ( ) const
overridevirtual

Offscreen surface to render to.

Reimplemented from RenderThreadRhi.

◆ TexturePtr()

virtual void* TexturePtr ( ) const
overridevirtual

Return a pointer to the graphics API texture Id.

Implements RenderThreadRhi.

◆ TextureSize()

virtual QSize TextureSize ( ) const
overridevirtual

Return the size of the texture.

Implements RenderThreadRhi.

◆ Update()

virtual void Update ( rendering::CameraPtr  _camera)
overridevirtual

Update the texture for a camera.

Parameters
[in]_cameraPointer to the camera providing the texture

Implements RenderThreadRhi.


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