Castor3D  ..
Public Member Functions | Protected Member Functions | Friends | List of all members
Castor3D::FrameBufferAttachment Class Referenceabstract

Description of an attachment between a frame buffer and a render buffer. More...

+ Inheritance diagram for Castor3D::FrameBufferAttachment:

Public Member Functions

virtual C3D_API Castor::PxBufferBaseSPtr GetBuffer () const =0
 
C3D_API Castor::PxBufferBaseSPtr DownloadBuffer ()
 Downloads the render buffer data. More...
 
virtual C3D_API bool Blit (FrameBufferSPtr p_buffer, Castor::Rectangle const &p_rectSrc, Castor::Rectangle const &p_rectDst, eINTERPOLATION_MODE p_interpolation)=0
 Blit this attachment's buffer into the given one. More...
 
eATTACHMENT_POINT GetAttachmentPoint () const
 
eATTACHMENT_TYPE GetAttachmentType () const
 
uint8_t GetAttachmentIndex () const
 

Protected Member Functions

C3D_API FrameBufferAttachment (eATTACHMENT_TYPE p_type)
 Constructor. More...
 
virtual C3D_API ~FrameBufferAttachment ()
 Destructor. More...
 
C3D_API bool Attach (eATTACHMENT_POINT p_attachment, uint8_t p_index, FrameBufferSPtr p_frameBuffer)
 Attaches the render buffer to the given frame buffer, at given attachment point. More...
 
C3D_API bool Attach (eATTACHMENT_POINT p_attachment, FrameBufferSPtr p_frameBuffer)
 Attaches the render buffer to the given frame buffer, at given attachment point. More...
 
C3D_API void Detach ()
 Detaches the render buffer from the frame buffer. More...
 
virtual C3D_API bool DoAttach (FrameBufferSPtr p_frameBuffer)=0
 Attaches the render buffer to the given frame buffer, at given attachment point. More...
 
virtual C3D_API void DoDetach ()=0
 Detaches the render buffer from the frame buffer. More...
 
bool HasFrameBuffer ()
 
FrameBufferSPtr GetFrameBuffer ()
 

Friends

class FrameBuffer
 

Detailed Description

Description of an attachment between a frame buffer and a render buffer.

Author
Sylvain DOREMUS
Version
0.7.0.0
Date
12/11/2012

Constructor & Destructor Documentation

◆ FrameBufferAttachment()

C3D_API Castor3D::FrameBufferAttachment::FrameBufferAttachment ( eATTACHMENT_TYPE  p_type)
protected

Constructor.

Parameters
[in]p_typeThe attachment type.

◆ ~FrameBufferAttachment()

virtual C3D_API Castor3D::FrameBufferAttachment::~FrameBufferAttachment ( )
protectedvirtual

Destructor.

Member Function Documentation

◆ Attach() [1/2]

C3D_API bool Castor3D::FrameBufferAttachment::Attach ( eATTACHMENT_POINT  p_attachment,
uint8_t  p_index,
FrameBufferSPtr  p_frameBuffer 
)
protected

Attaches the render buffer to the given frame buffer, at given attachment point.

Parameters
[in]p_attachmentThe attachment point
[in]p_indexThe attachment index
[in]p_frameBufferThe frame buffer
Returns
true if OK

◆ Attach() [2/2]

C3D_API bool Castor3D::FrameBufferAttachment::Attach ( eATTACHMENT_POINT  p_attachment,
FrameBufferSPtr  p_frameBuffer 
)
protected

Attaches the render buffer to the given frame buffer, at given attachment point.

Parameters
[in]p_attachmentThe attachment point
[in]p_frameBufferThe frame buffer
Returns
true if OK

◆ Blit()

virtual C3D_API bool Castor3D::FrameBufferAttachment::Blit ( FrameBufferSPtr  p_buffer,
Castor::Rectangle const &  p_rectSrc,
Castor::Rectangle const &  p_rectDst,
eINTERPOLATION_MODE  p_interpolation 
)
pure virtual

Blit this attachment's buffer into the given one.

Remarks
Interpolation for depth or stencil buffer must be eINTERPOLATION_MODE_NEAREST
Parameters
[in]p_bufferThe destination buffer
[in]p_rectSrcThe source rectangle
[in]p_rectDstThe destination rectangle
[in]p_interpolationThe interpolation to apply if the image is stretched
Returns
true if successful

◆ Detach()

C3D_API void Castor3D::FrameBufferAttachment::Detach ( )
protected

Detaches the render buffer from the frame buffer.

◆ DoAttach()

virtual C3D_API bool Castor3D::FrameBufferAttachment::DoAttach ( FrameBufferSPtr  p_frameBuffer)
protectedpure virtual

Attaches the render buffer to the given frame buffer, at given attachment point.

Parameters
[in]p_frameBufferThe frame buffer
Returns
true if OK

◆ DoDetach()

virtual C3D_API void Castor3D::FrameBufferAttachment::DoDetach ( )
protectedpure virtual

Detaches the render buffer from the frame buffer.

◆ DownloadBuffer()

C3D_API Castor::PxBufferBaseSPtr Castor3D::FrameBufferAttachment::DownloadBuffer ( )

Downloads the render buffer data.

Returns
The data buffer.

◆ GetAttachmentIndex()

uint8_t Castor3D::FrameBufferAttachment::GetAttachmentIndex ( ) const
inline
Returns
The attachment index.

◆ GetAttachmentPoint()

eATTACHMENT_POINT Castor3D::FrameBufferAttachment::GetAttachmentPoint ( ) const
inline
Returns
The attachment point

◆ GetAttachmentType()

eATTACHMENT_TYPE Castor3D::FrameBufferAttachment::GetAttachmentType ( ) const
inline
Returns
The attachment type.

◆ GetBuffer()

virtual C3D_API Castor::PxBufferBaseSPtr Castor3D::FrameBufferAttachment::GetBuffer ( ) const
pure virtual
Returns
The data buffer.

Implemented in Castor3D::RenderBufferAttachment, and Castor3D::TextureAttachment.

◆ GetFrameBuffer()

FrameBufferSPtr Castor3D::FrameBufferAttachment::GetFrameBuffer ( )
inlineprotected
Returns
The attached frame buffer.

◆ HasFrameBuffer()

bool Castor3D::FrameBufferAttachment::HasFrameBuffer ( )
inlineprotected
Returns
true if there is an attached frame buffer.

Friends And Related Function Documentation

◆ FrameBuffer

friend class FrameBuffer
friend

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