Crazy Eddies GUI System  0.7.9
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
CEGUI::Renderer Class Referenceabstract

Abstract class defining the basic required interface for Renderer objects. More...

Inherited by CEGUI::Direct3D10Renderer, CEGUI::Direct3D11Renderer, CEGUI::Direct3D9Renderer, CEGUI::DirectFBRenderer, CEGUI::IrrlichtRenderer, CEGUI::NullRenderer, CEGUI::OgreRenderer, and CEGUI::OpenGLRenderer.

Public Member Functions

virtual RenderingRootgetDefaultRenderingRoot ()=0
 Return the default rendering root for the renderer. The default rendering root is typically a RenderingRoot that targets the entire screen (or rendering window). More...
 
virtual GeometryBuffercreateGeometryBuffer ()=0
 Create a new GeometryBuffer and return a reference to it. You should remove the GeometryBuffer from any RenderQueues and call destroyGeometryBuffer when you want to destroy the GeometryBuffer. More...
 
virtual void destroyGeometryBuffer (const GeometryBuffer &buffer)=0
 Destroy a GeometryBuffer that was returned when calling the createGeometryBuffer function. Before destroying any GeometryBuffer you should ensure that it has been removed from any RenderQueue that was using it. More...
 
virtual void destroyAllGeometryBuffers ()=0
 Destroy all GeometryBuffer objects created by this Renderer.
 
virtual TextureTargetcreateTextureTarget ()=0
 Create a TextureTarget that can be used to cache imagery; this is a RenderTarget that does not lose it's content from one frame to another. More...
 
virtual void destroyTextureTarget (TextureTarget *target)=0
 Function that cleans up TextureTarget objects created with the createTextureTarget function. More...
 
virtual void destroyAllTextureTargets ()=0
 Destory all TextureTarget objects created by this Renderer.
 
virtual TexturecreateTexture ()=0
 Create a 'null' Texture object. More...
 
virtual TexturecreateTexture (const String &filename, const String &resourceGroup)=0
 Create a Texture object using the given image file. More...
 
virtual TexturecreateTexture (const Size &size)=0
 Create a Texture object with the given pixel dimensions as specified by size. More...
 
virtual void destroyTexture (Texture &texture)=0
 Destroy a Texture object that was previously created by calling the createTexture functions. More...
 
virtual void destroyAllTextures ()=0
 Destroy all Texture objects created by this Renderer.
 
virtual void beginRendering ()=0
 Perform any operations required to put the system into a state ready for rendering operations to begin.
 
virtual void endRendering ()=0
 Perform any operations required to finalise rendering.
 
virtual void setDisplaySize (const Size &size)=0
 Set the size of the display or host window in pixels for this Renderer object. More...
 
virtual const SizegetDisplaySize () const =0
 Return the size of the display or host window in pixels. More...
 
virtual const Vector2getDisplayDPI () const =0
 Return the resolution of the display or host window in dots per inch. More...
 
virtual uint getMaxTextureSize () const =0
 Return the pixel size of the maximum supported texture. More...
 
virtual const StringgetIdentifierString () const =0
 Return identification string for the renderer module. More...
 
virtual ~Renderer ()
 Destructor.
 

Detailed Description

Abstract class defining the basic required interface for Renderer objects.

Objects derived from Renderer are the means by which the GUI system interfaces with specific rendering technologies. To use a rendering system or API to draw CEGUI imagery requires that an appropriate Renderer object be available.

Member Function Documentation

virtual GeometryBuffer& CEGUI::Renderer::createGeometryBuffer ( )
pure virtual

Create a new GeometryBuffer and return a reference to it. You should remove the GeometryBuffer from any RenderQueues and call destroyGeometryBuffer when you want to destroy the GeometryBuffer.

Returns
GeometryBuffer object.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual Texture& CEGUI::Renderer::createTexture ( )
pure virtual

Create a 'null' Texture object.

Returns
A newly created Texture object. The returned Texture object has no size or imagery associated with it.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual Texture& CEGUI::Renderer::createTexture ( const String filename,
const String resourceGroup 
)
pure virtual

Create a Texture object using the given image file.

Parameters
filenameString object that specifies the path and filename of the image file to use when creating the texture.
resourceGroupString objet that specifies the resource group identifier to be passed to the resource provider when loading the texture file filename.
Returns
A newly created Texture object. The initial content of the texture memory is the requested image file.
Note
Due to possible limitations of the underlying hardware, API or engine, the final size of the texture may not match the size of the loaded file. You can check the ultimate sizes by querying the Texture object after creation.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual Texture& CEGUI::Renderer::createTexture ( const Size size)
pure virtual

Create a Texture object with the given pixel dimensions as specified by size.

Parameters
sizeSize object that describes the desired texture size.
Returns
A newly created Texture object. The initial contents of the texture memory is undefined.
Note
Due to possible limitations of the underlying hardware, API or engine, the final size of the texture may not match the requested size. You can check the ultimate sizes by querying the Texture object after creation.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual TextureTarget* CEGUI::Renderer::createTextureTarget ( )
pure virtual

Create a TextureTarget that can be used to cache imagery; this is a RenderTarget that does not lose it's content from one frame to another.

If the renderer is unable to offer such a thing, 0 should be returned.
Returns
Pointer to a TextureTarget object that is suitable for caching imagery, or 0 if the renderer is unable to offer such a thing.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual void CEGUI::Renderer::destroyGeometryBuffer ( const GeometryBuffer buffer)
pure virtual

Destroy a GeometryBuffer that was returned when calling the createGeometryBuffer function. Before destroying any GeometryBuffer you should ensure that it has been removed from any RenderQueue that was using it.

Parameters
bufferThe GeometryBuffer object to be destroyed.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual void CEGUI::Renderer::destroyTexture ( Texture texture)
pure virtual

Destroy a Texture object that was previously created by calling the createTexture functions.

Parameters
textureTexture object to be destroyed.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual void CEGUI::Renderer::destroyTextureTarget ( TextureTarget target)
pure virtual

Function that cleans up TextureTarget objects created with the createTextureTarget function.

Parameters
targetA pointer to a TextureTarget object that was previously returned from a call to createTextureTarget.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual RenderingRoot& CEGUI::Renderer::getDefaultRenderingRoot ( )
pure virtual

Return the default rendering root for the renderer. The default rendering root is typically a RenderingRoot that targets the entire screen (or rendering window).

Returns
RenderingRoot object that is the default RenderingSurface provided by the Renderer.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual const Vector2& CEGUI::Renderer::getDisplayDPI ( ) const
pure virtual

Return the resolution of the display or host window in dots per inch.

Returns
Vector2 object that describes the resolution of the display or host window in DPI.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual const Size& CEGUI::Renderer::getDisplaySize ( ) const
pure virtual

Return the size of the display or host window in pixels.

Returns
Size object describing the pixel dimesntions of the current display or host window.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual const String& CEGUI::Renderer::getIdentifierString ( ) const
pure virtual

Return identification string for the renderer module.

Returns
String object holding text that identifies the Renderer in use.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual uint CEGUI::Renderer::getMaxTextureSize ( ) const
pure virtual

Return the pixel size of the maximum supported texture.

Returns
Size of the maximum supported texture in pixels.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.

virtual void CEGUI::Renderer::setDisplaySize ( const Size size)
pure virtual

Set the size of the display or host window in pixels for this Renderer object.

This is intended to be called by the System as part of the notification
process when display size changes are notified to it via the
System::notifyDisplaySizeChanged function.
Note
The Renderer implementation should not use this function other than to perform internal state updates on the Renderer and related objects.
Parameters
sizeSize object describing the dimesions of the current or host window in pixels.

Implemented in CEGUI::OgreRenderer, CEGUI::OpenGLRenderer, CEGUI::Direct3D11Renderer, CEGUI::IrrlichtRenderer, CEGUI::Direct3D9Renderer, CEGUI::Direct3D10Renderer, CEGUI::NullRenderer, and CEGUI::DirectFBRenderer.