ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

Stark::Gfx::Texture Class Reference

An abstract texture. More...

#include <texture.h>

Inheritance diagram for Stark::Gfx::Texture:

List of all members.

Public Types

enum  SamplingFilter { kNearest, kLinear }

Public Member Functions

 Texture ()
virtual ~Texture ()
virtual void bind () const =0
 Make the texture active.
virtual void update (const Graphics::Surface *surface, const byte *palette=nullptr)=0
 Define or update the texture pixel data.
virtual void setSamplingFilter (SamplingFilter filter)=0
 Set the filter used when sampling the texture.
virtual void setLevelCount (uint32 count)=0
 Define the total number of levels of details.
virtual void addLevel (uint32 level, const Graphics::Surface *surface, const byte *palette=nullptr)=0
 Add a detail level to the texture.
uint32 width () const
 Get the texture width.
uint32 height () const
 Get the texture height.

Protected Attributes

uint32 _width
uint32 _height

Detailed Description

An abstract texture.

Definition at line 38 of file texture.h.


Member Enumeration Documentation

Enumerator:
kNearest 
kLinear 

Definition at line 43 of file texture.h.


Constructor & Destructor Documentation

Stark::Gfx::Texture::Texture (  ) 

Definition at line 30 of file texture.cpp.

Stark::Gfx::Texture::~Texture (  )  [virtual]

Definition at line 35 of file texture.cpp.


Member Function Documentation

virtual void Stark::Gfx::Texture::addLevel ( uint32  level,
const Graphics::Surface surface,
const byte palette = nullptr 
) [pure virtual]

Add a detail level to the texture.

Implemented in Stark::Gfx::OpenGlTexture.

virtual void Stark::Gfx::Texture::bind (  )  const [pure virtual]

Make the texture active.

Implemented in Stark::Gfx::OpenGlTexture.

uint32 Stark::Gfx::Texture::height (  )  const [inline]

Get the texture height.

Definition at line 73 of file texture.h.

virtual void Stark::Gfx::Texture::setLevelCount ( uint32  count  )  [pure virtual]

Define the total number of levels of details.

Must be called before adding levels

Implemented in Stark::Gfx::OpenGlTexture.

virtual void Stark::Gfx::Texture::setSamplingFilter ( SamplingFilter  filter  )  [pure virtual]

Set the filter used when sampling the texture.

Implemented in Stark::Gfx::OpenGlTexture.

virtual void Stark::Gfx::Texture::update ( const Graphics::Surface surface,
const byte palette = nullptr 
) [pure virtual]

Define or update the texture pixel data.

Implemented in Stark::Gfx::OpenGlTexture.

uint32 Stark::Gfx::Texture::width (  )  const [inline]

Get the texture width.

Definition at line 70 of file texture.h.


Member Data Documentation

Definition at line 77 of file texture.h.

Definition at line 76 of file texture.h.


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


Generated on Sat Sep 14 2019 05:05:00 for ResidualVM by doxygen 1.7.1
curved edge   curved edge