Castor3D  ..
Public Member Functions | List of all members
Castor3D::StaticTexture Class Reference

Static texture class. More...

+ Inheritance diagram for Castor3D::StaticTexture:
+ Collaboration diagram for Castor3D::StaticTexture:

Public Member Functions

C3D_API StaticTexture (RenderSystem &p_renderSystem)
 Constructor. More...
 
virtual C3D_API ~StaticTexture ()
 Destructor. More...
 
C3D_API void SetImage (Castor::Point3ui const &p_dimensions, Castor::PxBufferBaseSPtr p_buffer)
 Defines the texture buffer and its dimensions, for a 3D texture or a texture array. More...
 
virtual C3D_API bool Initialise ()
 Initialisation function. More...
 
virtual C3D_API void Cleanup ()
 Cleanup function. More...
 
C3D_API void SetImage (Castor::PxBufferBaseSPtr p_buffer)
 Defines the texture buffer. More...
 
- Public Member Functions inherited from Castor3D::Texture
C3D_API Texture (eTEXTURE_BASE_TYPE p_type, RenderSystem &p_renderSystem, uint8_t p_cpuAccess, uint8_t p_gpuAccess)
 Constructor. More...
 
virtual C3D_API ~Texture ()
 Destructor. More...
 
C3D_API void SetImage (Castor::PxBufferBaseSPtr p_buffer)
 Defines the texture buffer. More...
 
C3D_API bool Bind (uint32_t p_index) const
 Activation function, to tell the GPU it is active. More...
 
C3D_API void Unbind (uint32_t p_index) const
 Deactivation function, to tell the GPU it is inactive. More...
 
virtual C3D_API bool Create ()=0
 Creation function. More...
 
virtual C3D_API void Destroy ()=0
 Destruction function. More...
 
virtual C3D_API uint8_t * Lock (uint32_t p_lock)=0
 Locks image buffer from GPU, allowing modifications into it. More...
 
virtual C3D_API void Unlock (bool p_modified)=0
 Unlocks image buffer from GPU. More...
 
virtual C3D_API void GenerateMipmaps () const =0
 Generate texture mipmaps. More...
 
bool IsInitialised () const
 Retrieves the initialisation status. More...
 
eTEXTURE_BASE_TYPE GetBaseType () const
 Retrieves the texture type. More...
 
eTEXTURE_TYPE GetType () const
 Retrieves the texture dimension. More...
 
void SetType (eTEXTURE_TYPE p_dimension)
 Defines the texture dimension. More...
 
eTEXTURE_MAP_MODE GetMappingMode () const
 Retrieves the texture mapping mode. More...
 
void SetMappingMode (eTEXTURE_MAP_MODE p_eMapMode)
 Defines the texture mapping mode. More...
 
Castor::Size GetDimensions () const
 Retrieves the texture image dimensions. More...
 
uint32_t GetDepth () const
 Retrieves the texture depth. More...
 
Castor::ePIXEL_FORMAT GetPixelFormat () const
 Retrieves the texture pixel format. More...
 
uint32_t GetWidth () const
 Retrieves the texture image width. More...
 
uint32_t GetHeight () const
 Retrieves the texture image height. More...
 
Castor::PxBufferBaseSPtr GetBuffer () const
 Retrieves the texture buffer. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Castor3D::Texture
virtual C3D_API bool DoInitialise ()=0
 API specific initialisation function. More...
 
virtual C3D_API bool DoBind (uint32_t p_index) const =0
 API specific binding function. More...
 
virtual C3D_API void DoUnbind (uint32_t p_index) const =0
 API specific unbinding function. More...
 
 DECLARE_VECTOR (Castor::PxBufferBaseSPtr, PxBuffer)
 
- Protected Attributes inherited from Castor3D::Texture
bool m_initialised
 Initialisation status. More...
 
eTEXTURE_BASE_TYPE m_baseType
 Texture base type. More...
 
eTEXTURE_TYPE m_type
 Texture type. More...
 
eTEXTURE_MAP_MODE m_mapMode
 Texture mapping modes. More...
 
uint32_t m_depth
 3D Texture depth More...
 
Castor::PxBufferBaseSPtr m_pixelBuffer
 Texture pixels, at least at initialisation. More...
 
Castor::ePIXEL_FORMAT m_pixelFormat
 The pixel buffer format. More...
 
Castor::Size m_size
 The pixel buffer dimensions. More...
 
uint8_t m_cpuAccess
 The required CPU access (combination of eACCESS_TYPE). More...
 
uint8_t m_gpuAccess
 The required GPU access (combination of eACCESS_TYPE). More...
 

Detailed Description

Static texture class.

Author
Sylvain DOREMUS
Date
14/02/2010
Remarks
A static texture deletes it's buffer from ram when initialised

Constructor & Destructor Documentation

◆ StaticTexture()

C3D_API Castor3D::StaticTexture::StaticTexture ( RenderSystem p_renderSystem)

Constructor.

Parameters
[in]p_renderSystemThe render system.

◆ ~StaticTexture()

virtual C3D_API Castor3D::StaticTexture::~StaticTexture ( )
virtual

Destructor.

Member Function Documentation

◆ Cleanup()

virtual C3D_API void Castor3D::StaticTexture::Cleanup ( )
virtual

Cleanup function.

Implements Castor3D::Texture.

◆ Initialise()

virtual C3D_API bool Castor3D::StaticTexture::Initialise ( )
virtual

Initialisation function.

Returns
true if OK.

Implements Castor3D::Texture.

◆ SetImage() [1/2]

C3D_API void Castor3D::StaticTexture::SetImage ( Castor::Point3ui const &  p_dimensions,
Castor::PxBufferBaseSPtr  p_buffer 
)

Defines the texture buffer and its dimensions, for a 3D texture or a texture array.

Parameters
[in]p_dimensionsThe texture dimensions
[in]p_bufferThe buffer

◆ SetImage() [2/2]

C3D_API void Castor3D::Texture::SetImage

Defines the texture buffer.

Parameters
[in]p_bufferThe buffer

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