Crazy Eddie's GUI System  0.8.4
CEGUI::GeometryBuffer Class Reference

Abstract class defining the interface for objects that buffer geometry for later rendering. More...

Inherits CEGUI::AllocatedObject< GeometryBuffer >.

Inherited by CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::DirectFBGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::NullGeometryBuffer, CEGUI::OgreGeometryBuffer, CEGUI::OpenGLESGeometryBuffer, and CEGUI::OpenGLGeometryBufferBase.

+ Collaboration diagram for CEGUI::GeometryBuffer:

List of all members.

Public Member Functions

virtual ~GeometryBuffer ()
 Destructor.
virtual void draw () const =0
 Draw the geometry buffered within this GeometryBuffer object.
virtual void setTranslation (const Vector3f &v)=0
 Set the translation to be applied to the geometry in the buffer when it is subsequently rendered.
virtual void setRotation (const Quaternion &r)=0
 Set the rotations to be applied to the geometry in the buffer when it is subsequently rendered.
virtual void setPivot (const Vector3f &p)=0
 Set the pivot point to be used when applying the rotations.
virtual void setClippingRegion (const Rectf &region)=0
 Set the clipping region to be used when rendering this buffer.
virtual void appendVertex (const Vertex &vertex)=0
 Append a single vertex to the buffer.
virtual void appendGeometry (const Vertex *const vbuff, uint vertex_count)=0
 Append a number of vertices from an array to the GeometryBuffer.
virtual void setActiveTexture (Texture *texture)=0
 Set the active texture to be used with all subsequently added vertices.
virtual void reset ()=0
 Clear all buffered data and reset the GeometryBuffer to the default state.
virtual TexturegetActiveTexture () const =0
 Return a pointer to the currently active Texture object. This may return 0 if no texture is set.
virtual uint getVertexCount () const =0
 Return the total number of vertices currently held by this GeometryBuffer object.
virtual uint getBatchCount () const =0
 Return the number of batches of geometry that this GeometryBuffer has split the vertices into.
virtual void setRenderEffect (RenderEffect *effect)=0
 Set the RenderEffect to be used by this GeometryBuffer.
virtual RenderEffectgetRenderEffect ()=0
 Return the RenderEffect object that is assigned to this GeometryBuffer or 0 if none.
virtual void setBlendMode (const BlendMode mode)
 Set the blend mode option to use when rendering this GeometryBuffer.
virtual BlendMode getBlendMode () const
 Return the blend mode that is set to be used for this GeometryBuffer.
virtual void setClippingActive (const bool active)=0
 Set whether clipping will be active for subsequently added vertices.
virtual bool isClippingActive () const =0

Protected Member Functions

 GeometryBuffer ()
 Constructor.

Protected Attributes

BlendMode d_blendMode
 The BlendMode to use when rendering this GeometryBuffer.

Detailed Description

Abstract class defining the interface for objects that buffer geometry for later rendering.


Member Function Documentation

virtual void CEGUI::GeometryBuffer::appendGeometry ( const Vertex *const  vbuff,
uint  vertex_count 
) [pure virtual]

Append a number of vertices from an array to the GeometryBuffer.

Parameters:
vbuffPointer to an array of Vertex objects that describe the vertices that are to be added to the GeometryBuffer.
vertex_countThe number of Vertex objects from the array vbuff that are to be added to the GeometryBuffer.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, CEGUI::DirectFBGeometryBuffer, and CEGUI::OpenGL3GeometryBuffer.

virtual Texture* CEGUI::GeometryBuffer::getActiveTexture ( ) const [pure virtual]

Return a pointer to the currently active Texture object. This may return 0 if no texture is set.

Returns:
Pointer the Texture object that is currently active, or 0 if texturing is not being used.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual uint CEGUI::GeometryBuffer::getBatchCount ( ) const [pure virtual]

Return the number of batches of geometry that this GeometryBuffer has split the vertices into.

Note:
How batching is done will be largely implementation specific, although it would be reasonable to expect that you will have at least one batch of geometry per texture switch.
Returns:
The number of batches of geometry held by the GeometryBuffer.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual BlendMode CEGUI::GeometryBuffer::getBlendMode ( ) const [virtual]

Return the blend mode that is set to be used for this GeometryBuffer.

Returns:
One of the BlendMode enumerated values indicating the blending mode that will be used when rendering all geometry added to this GeometryBuffer object.
virtual void CEGUI::GeometryBuffer::setActiveTexture ( Texture texture) [pure virtual]

Set the active texture to be used with all subsequently added vertices.

Parameters:
texturePointer to a Texture object that shall be used for subsequently added vertices. This may be 0, in which case texturing will be disabled for subsequently added vertices.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setBlendMode ( const BlendMode  mode) [virtual]

Set the blend mode option to use when rendering this GeometryBuffer.

Note:
The blend mode setting is not a 'state' setting, but is used for all geometry added to the buffer regardless of when the blend mode is set.
Parameters:
modeOne of the BlendMode enumerated values indicating the blending mode to be used.

Reimplemented in CEGUI::IrrlichtGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setClippingActive ( const bool  active) [pure virtual]

Set whether clipping will be active for subsequently added vertices.

Parameters:
active
  • true if vertices added after this call should be clipped to the clipping region defined for this GeometryBuffer.
  • false if vertices added after this call should not be clipped (other than to the edges of rendering target.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setPivot ( const Vector3f p) [pure virtual]

Set the pivot point to be used when applying the rotations.

Parameters:
pVector3 describing the location of the pivot point to be used when applying the rotation to the geometry.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setRenderEffect ( RenderEffect effect) [pure virtual]

Set the RenderEffect to be used by this GeometryBuffer.

Parameters:
effectPointer to the RenderEffect to be used during renderng of the GeometryBuffer. May be 0 to remove a previously added RenderEffect.
Note:
When adding a RenderEffect, the GeometryBuffer does not take ownership of, nor make a copy of, the passed RenderEffect - this means you need to be careful not to delete the RenderEffect if it might still be in use!

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setRotation ( const Quaternion r) [pure virtual]

Set the rotations to be applied to the geometry in the buffer when it is subsequently rendered.

Parameters:
rQuaternion describing the rotation to be used.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

virtual void CEGUI::GeometryBuffer::setTranslation ( const Vector3f v) [pure virtual]

Set the translation to be applied to the geometry in the buffer when it is subsequently rendered.

Parameters:
vVector3 describing the three axis translation vector to be used.

Implemented in CEGUI::OgreGeometryBuffer, CEGUI::IrrlichtGeometryBuffer, CEGUI::Direct3D9GeometryBuffer, CEGUI::Direct3D10GeometryBuffer, CEGUI::Direct3D11GeometryBuffer, CEGUI::OpenGLGeometryBufferBase, CEGUI::OpenGLESGeometryBuffer, CEGUI::NullGeometryBuffer, and CEGUI::DirectFBGeometryBuffer.

 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends