#include <OgreRenderTarget.hh>
Public Member Functions | |
virtual | ~OgreRenderTarget () |
Ogre::Viewport * | AddViewport (Ogre::Camera *_viewport) |
virtual unsigned int | AntiAliasing () const |
virtual math::Color | BackgroundColor () const override |
Get the background color of the render target. This should be the same as the scene background color. | |
virtual Ogre::Camera * | Camera () const |
virtual void | Copy (Image &_image) const override |
Write rendered image to given Image. The RenderTarget will convert the underlying image to the specified format listed in the given Image. However if the given image is not of the correct size no work will be done. Calling this function before an image has been rendered will result in undefined behavior. | |
virtual void | Destroy () override=0 |
Destroy any resources associated with this object. Invoking any other functions after destroying an object will result in undefined behavior. | |
virtual void | PostRender () override |
Post process this object and any of its children after rendering. | |
virtual void | PreRender () override |
Prepare this object and any of its children for rendering. This should be called for each object in a scene just before rendering, which can be achieved by a single call to Scene::PreRender. | |
virtual void | Render () |
virtual Ogre::RenderTarget * | RenderTarget () const =0 |
virtual void | SetAntiAliasing (unsigned int _aa) |
void | SetAutoUpdated (const bool _value) |
virtual void | SetBackgroundColor (math::Color _color) |
virtual void | SetCamera (Ogre::Camera *_camera) |
void | SetMaterial (MaterialPtr _material) |
Set a material to render on every object. This method is used for special cases like the render target of a depth camera. | |
void | SetUpdate (const bool _value) |
virtual void | SetVisibilityMask (uint32_t _mask) |
Set visibility mask for the viewport associated with this render target. | |
Ogre::Viewport * | Viewport (const int _viewportId) const |
Public Member Functions inherited from BaseRenderTarget< OgreObject > | |
BaseRenderTarget () | |
virtual | ~BaseRenderTarget () |
virtual void | AddRenderPass (const RenderPassPtr &_pass) override |
Add a render pass to the render target. | |
virtual PixelFormat | Format () const override |
Set the render target image format. | |
virtual unsigned int | Height () const override |
Get render target height in pixels. | |
virtual void | PreRender (const CameraPtr &_camera) override |
See Object::PreRender. This function will call Object::PreRender but with the added bonus that it has access to the camera that is about to render. | |
virtual bool | Reinterpretable () const override |
See SetFormat() | |
void | RemoveAllRenderPasses () override |
Remove all render passes from the render target. | |
virtual void | RemoveRenderPass (const RenderPassPtr &_pass) override |
Remove a render pass from the render target. | |
virtual RenderPassPtr | RenderPassByIndex (unsigned int _index) const override |
Get a render pass by index. | |
virtual unsigned int | RenderPassCount () const override |
Get the number of render passes applied to the render target. | |
virtual void | SetFormat (PixelFormat _format, bool _reinterpretable=false) override |
Set the render target image format. | |
virtual void | SetHeight (const unsigned int _height) override |
Set the render target height in pixels. | |
virtual void | SetWidth (const unsigned int _width) override |
Set the render target width in pixels. | |
virtual unsigned int | Width () const override |
Get render target width in pixels. | |
Public Member Functions inherited from RenderTarget | |
virtual | ~RenderTarget () |
Destructor. | |
virtual void | PreRender ()=0 |
Prepare this object and any of its children for rendering. This should be called for each object in a scene just before rendering, which can be achieved by a single call to Scene::PreRender. | |
Public Member Functions inherited from Object | |
virtual | ~Object () |
Destructor. | |
virtual unsigned int | Id () const =0 |
Get the object ID. This ID will be unique across all objects inside a given scene, but necessarily true for objects across different scenes. | |
virtual std::string | Name () const =0 |
Get the object name. This name will be unique across all objects inside a given scene, but necessarily true for objects across different scenes. | |
virtual ScenePtr | Scene () const =0 |
Get the Scene that created this object. | |
Public Member Functions inherited from OgreObject | |
virtual | ~OgreObject () |
virtual ScenePtr | Scene () const |
Public Member Functions inherited from BaseObject | |
virtual | ~BaseObject () |
virtual unsigned int | Id () const override |
virtual std::string | Name () const override |
Protected Member Functions | |
OgreRenderTarget () | |
virtual void | RebuildImpl () override |
void | RebuildMaterial () |
Re-initializes render target material to apply a material to everything in the scene. Does nothing if no material has been set. | |
virtual void | RebuildTarget ()=0 |
virtual void | RebuildViewport () |
virtual void | UpdateBackgroundColor () |
virtual void | UpdateRenderPassChain () |
Update render pass chain if changes were made. | |
Protected Member Functions inherited from BaseRenderTarget< OgreObject > | |
virtual void | Rebuild () |
Protected Member Functions inherited from OgreObject | |
OgreObject () | |
Protected Member Functions inherited from BaseObject | |
BaseObject () | |
virtual void | Init () |
virtual void | Load () |
Protected Attributes | |
unsigned int | antiAliasing = 4 |
bool | colorDirty = true |
MaterialPtr | material |
a material used by for the render target | |
OgreRenderTargetMaterialPtr | materialApplicator |
Helper class that applies the material to the render target. | |
Ogre::ColourValue | ogreBackgroundColor |
Ogre::Camera * | ogreCamera = nullptr |
Ogre::Viewport * | ogreViewport = nullptr |
uint32_t | visibilityMask = GZ_VISIBILITY_ALL |
visibility mask associated with this render target | |
Protected Attributes inherited from BaseRenderTarget< OgreObject > | |
PixelFormat | format |
unsigned int | height |
bool | reinterpretable |
bool | renderPassDirty |
Flag to indicate if render pass need to be rebuilt. | |
std::vector< RenderPassPtr > | renderPasses |
A chain of render passes applied to the render target. | |
bool | targetDirty |
unsigned int | width |
Protected Attributes inherited from OgreObject | |
OgreScenePtr | scene |
Protected Attributes inherited from BaseObject | |
unsigned int | id |
std::string | name |
Constructor & Destructor Documentation
◆ OgreRenderTarget()
|
protected |
◆ ~OgreRenderTarget()
|
virtual |
Member Function Documentation
◆ AddViewport()
Ogre::Viewport * AddViewport | ( | Ogre::Camera * | _viewport | ) |
◆ AntiAliasing()
|
virtual |
◆ BackgroundColor()
|
overridevirtual |
Get the background color of the render target. This should be the same as the scene background color.
- Returns
- Render target background color.
Reimplemented from BaseRenderTarget< OgreObject >.
◆ Camera()
|
virtual |
◆ Copy()
|
overridevirtual |
Write rendered image to given Image. The RenderTarget will convert the underlying image to the specified format listed in the given Image. However if the given image is not of the correct size no work will be done. Calling this function before an image has been rendered will result in undefined behavior.
- Parameters
-
[out] _image Image to which output will be written
Implements RenderTarget.
◆ Destroy()
|
overridepure virtual |
Destroy any resources associated with this object. Invoking any other functions after destroying an object will result in undefined behavior.
Implements Object.
Implemented in OgreRenderWindow, and OgreRenderTexture.
◆ PostRender()
|
overridevirtual |
Post process this object and any of its children after rendering.
Reimplemented from BaseRenderTarget< OgreObject >.
Reimplemented in OgreRenderTexture.
◆ PreRender()
|
overridevirtual |
Prepare this object and any of its children for rendering. This should be called for each object in a scene just before rendering, which can be achieved by a single call to Scene::PreRender.
Reimplemented from BaseRenderTarget< OgreObject >.
Reimplemented in OgreRenderTexture.
◆ RebuildImpl()
|
overrideprotectedvirtual |
Implements BaseRenderTarget< OgreObject >.
◆ RebuildMaterial()
|
protected |
Re-initializes render target material to apply a material to everything in the scene. Does nothing if no material has been set.
◆ RebuildTarget()
|
protectedpure virtual |
Implemented in OgreRenderWindow, and OgreRenderTexture.
◆ RebuildViewport()
|
protectedvirtual |
◆ Render()
|
virtual |
◆ RenderTarget()
|
pure virtual |
Implemented in OgreRenderWindow, and OgreRenderTexture.
◆ SetAntiAliasing()
|
virtual |
◆ SetAutoUpdated()
void SetAutoUpdated | ( | const bool | _value | ) |
◆ SetBackgroundColor()
|
virtual |
◆ SetCamera()
|
virtual |
◆ SetMaterial()
void SetMaterial | ( | MaterialPtr | _material | ) |
Set a material to render on every object. This method is used for special cases like the render target of a depth camera.
- Parameters
-
[in] _material The material to render
◆ SetUpdate()
void SetUpdate | ( | const bool | _value | ) |
◆ SetVisibilityMask()
|
virtual |
Set visibility mask for the viewport associated with this render target.
- Parameters
-
[in] _mask Visibility mask
◆ UpdateBackgroundColor()
|
protectedvirtual |
◆ UpdateRenderPassChain()
|
protectedvirtual |
Update render pass chain if changes were made.
◆ Viewport()
Ogre::Viewport * Viewport | ( | const int | _viewportId | ) | const |
Member Data Documentation
◆ antiAliasing
|
protected |
◆ colorDirty
|
protected |
◆ material
|
protected |
a material used by for the render target
◆ materialApplicator
|
protected |
Helper class that applies the material to the render target.
◆ ogreBackgroundColor
|
protected |
◆ ogreCamera
|
protected |
◆ ogreViewport
|
protected |
◆ visibilityMask
|
protected |
visibility mask associated with this render target
The documentation for this class was generated from the following file: