A base texture.
More...
Inherits Ref.
Inherited by Texture2DBackend, and TextureCubemapBackend.
|
unsigned int | _ID |
| object id, ScriptSupport need public _ID
|
|
int | _luaID |
| Lua reference id.
|
|
void * | _scriptObject |
| scriptObject, support for swift
|
|
bool | _rooted |
| When true, it means that the object was already rooted.
|
|
◆ updateSamplerDescriptor()
virtual void updateSamplerDescriptor |
( |
const SamplerDescriptor & |
sampler | ) |
|
|
pure virtual |
◆ getBytes()
virtual void getBytes |
( |
std::size_t |
x, |
|
|
std::size_t |
y, |
|
|
std::size_t |
width, |
|
|
std::size_t |
height, |
|
|
bool |
flipImage, |
|
|
std::function< void(const unsigned char *, std::size_t, std::size_t)> |
callback |
|
) |
| |
|
pure virtual |
Read a block of pixels from the drawable texture.
- Parameters
-
x,y | Specify the window coordinates of the first pixel that is read from the drawable texture. This location is the lower left corner of a rectangular block of pixels. |
width,height | Specify the dimensions of the pixel rectangle. width and height of one correspond to a single pixel. |
flipImage | Specifies if needs to flip the image. |
callback | Specifies a call back function to deal with the image. |
Implemented in TextureCubeGL, TextureCubeMTL, Texture2DGL, and TextureMTL.
◆ updateTextureDescriptor()
◆ getTextureFormat()
Get texture format.
- Returns
- Texture format.
◆ getTextureUsage()
TextureUsage getTextureUsage |
( |
| ) |
const |
|
inline |
Get texture usage.
Symbolic constant can be READ, WRITE or RENDER_TARGET.
- Returns
- Texture usage.
◆ getTextureType()
TextureType getTextureType |
( |
| ) |
const |
|
inline |
Get texture type.
Symbolic constant value can be either TEXTURE_2D or TEXTURE_CUBE.
- Returns
- Texture type.
◆ hasMipmaps()
bool hasMipmaps |
( |
| ) |
const |
|
inline |
Check if mipmap had generated before.
- Returns
- true if the mipmap has always generated before, otherwise false.
The documentation for this class was generated from the following file: