 |
Irrlicht 3D Engine
|
|
Go to the documentation of this file.
5 #ifndef __I_TEXTURE_H_INCLUDED__
6 #define __I_TEXTURE_H_INCLUDED__
132 virtual void unlock() = 0;
virtual const core::dimension2d< u32 > & getSize() const =0
Get dimension (=size) of the texture.
virtual u32 getPitch() const =0
Get pitch of the main texture (in bytes).
virtual void * lock(E_TEXTURE_LOCK_MODE mode=ETLM_READ_WRITE, u32 mipmapLevel=0)=0
Lock function.
E_TEXTURE_CREATION_FLAG getTextureFormatFromFlags(u32 flags)
Helper function, helps to get the desired texture creation format from the flags.
E_TEXTURE_CREATION_FLAG
Enumeration flags telling the video driver in which format textures should be created.
Interface of a Video Driver dependent Texture.
virtual const core::dimension2d< u32 > & getOriginalSize() const =0
Get original size of the texture.
@ ETLM_WRITE_ONLY
Write only. The texture is not downloaded and might be uninitialised.
virtual void regenerateMipMapLevels(void *mipmapData=0)=0
Regenerates the mip map levels of the texture.
virtual bool isRenderTarget() const
Check whether the texture is a render target.
virtual bool hasAlpha() const
Returns if the texture has an alpha channel.
@ ETLM_READ_ONLY
Read only. The texture is downloaded, but not uploaded again.
Base class of most objects of the Irrlicht Engine.
@ ETCF_FORCE_32_BIT_DO_NOT_USE
virtual ECOLOR_FORMAT getColorFormat() const =0
Get the color format of texture.
Used in places where we identify objects by a filename, but don't actually work with the real filenam...
ITexture(const io::path &name)
constructor
@ ETCF_OPTIMIZED_FOR_QUALITY
@ ECF_A8R8G8B8
Default 32 bit color format. 8 bits are used for every component: red, green, blue and alpha.
E_TEXTURE_LOCK_MODE
Enum for the mode for texture locking. Read-Only, write-only or read/write.
@ ETCF_OPTIMIZED_FOR_SPEED
@ ETCF_ALLOW_NON_POWER_2
Allow the Driver to use Non-Power-2-Textures.
@ ETLM_READ_WRITE
The default mode. Texture can be read and written to.
virtual E_DRIVER_TYPE getDriverType() const =0
Get driver type of texture.
Everything in the Irrlicht Engine can be found in this namespace.
unsigned int u32
32 bit unsigned variable.
virtual bool hasMipMaps() const
Check whether the texture has MipMaps.
E_DRIVER_TYPE
An enum for all types of drivers the Irrlicht Engine supports.
const io::SNamedPath & getName() const
Get name of texture (in most cases this is the filename)
virtual void unlock()=0
Unlock function. Must be called after a lock() to the texture.
ECOLOR_FORMAT
An enum for the color format of textures used by the Irrlicht Engine.
@ ECF_A1R5G5B5
16 bit color format used by the software driver.