|
| glTexture (PlatformContext &context, const ResourceDescriptor< Texture > &descriptor) |
|
| ~glTexture () override |
|
bool | unload () override |
|
void | clearData (const UColour4 &clearColour, SubRange layerRange, U8 mipLevel) const |
|
ImageReadbackData | readData (U8 mipLevel, const PixelAlignment &pixelPackAlignment) const override |
|
| PROPERTY_R_IW (gl46core::GLuint, textureHandle, GL_NULL_HANDLE) |
|
| Texture (PlatformContext &context, const ResourceDescriptor< Texture > &descriptor) |
|
virtual | ~Texture () override |
|
void | createWithData (const ImageTools::ImageData &imageData, const PixelAlignment &pixelUnpackAlignment) |
| API-dependent loading function that uploads ptr data to the GPU using the specified parameters.
|
|
void | createWithData (const Byte *data, size_t dataSize, const vec2< U16 > &dimensions, const PixelAlignment &pixelUnpackAlignment) |
|
void | createWithData (const Byte *data, size_t dataSize, const vec3< U16 > &dimensions, const PixelAlignment &pixelUnpackAlignment) |
|
void | replaceData (const Byte *data, size_t dataSize, const vec3< U16 > &offset, const vec3< U16 > &range, const PixelAlignment &pixelUnpackAlignment) |
|
void | setSampleCount (U8 newSampleCount) |
| Change the number of MSAA samples for this current texture.
|
|
ImageView | getView () const noexcept |
|
ImageView | getView (TextureType targetType) const noexcept |
|
ImageView | getView (SubRange mipRange) const noexcept |
|
ImageView | getView (SubRange mipRange, SubRange layerRange) const noexcept |
|
ImageView | getView (TextureType targetType, SubRange mipRange) const noexcept |
|
ImageView | getView (TextureType targetType, SubRange mipRange, SubRange layerRange) const noexcept |
|
virtual ImageReadbackData | readData (U8 mipLevel, const PixelAlignment &pixelPackAlignment) const =0 |
|
| PROPERTY_R (TextureDescriptor, descriptor) |
|
| PROPERTY_R (U16, mipCount, 1u) |
| Get the number of mips.
|
|
| PROPERTY_R (U16, width, 0u) |
| Texture width as returned by STB/DDS loader.
|
|
| PROPERTY_R (U16, height, 0u) |
| Texture height as returned by STB/DDS loader.
|
|
| PROPERTY_R (U16, depth, 1u) |
| Depth for TEXTURE_3D, layer count for TEXTURE_1/2D/CUBE_ARRAY. For cube arrays, numSlices = depth * 6u.
|
|
| PROPERTY_R (bool, hasTranslucency, false) |
| If the texture has an alpha channel and at least one pixel is translucent, return true.
|
|
| PROPERTY_R (bool, hasTransparency, false) |
| If the texture has an alpha channel and at least on pixel is fully transparent and no pixels are partially transparent, return true.
|
|
| PROPERTY_R (bool, loadedFromFile, false) |
|
U8 | numChannels () const noexcept |
|
bool | load (PlatformContext &context) override |
| Loading and unloading interface.
|
|
bool | postLoad () override |
|
| CachedResource (const ResourceDescriptorBase &descriptor, std::string_view typeName) |
|
virtual bool | load (PlatformContext &context) |
| Loading and unloading interface.
|
|
virtual bool | postLoad () |
|
virtual bool | unload () |
|
void | setState (ResourceState currentState) final |
|
| Resource (std::string_view resourceName, std::string_view typeName) |
|
ResourceState | getState () const noexcept |
|
| PROPERTY_R (Str< 32 >, typeName) |
|
| PROPERTY_R (Str< 256 >, resourceName) |
|
| GUIDWrapper () noexcept |
|
| GUIDWrapper (const GUIDWrapper &old) noexcept |
|
| GUIDWrapper (GUIDWrapper &&old) noexcept |
|
virtual | ~GUIDWrapper ()=default |
|
FORCE_INLINE I64 | getGUID () const noexcept |
|
GUIDWrapper & | operator= (const GUIDWrapper &old)=delete |
|
GUIDWrapper & | operator= (GUIDWrapper &&other)=delete |
|
virtual | ~GraphicsResource () |
|
GFXDevice & | context () const noexcept |
|
U64 | nameHash () const noexcept |
|
| NonCopyable (const NonCopyable &)=delete |
|
NonCopyable & | operator= (const NonCopyable &)=delete |
|
| NonCopyable (NonCopyable &&)=default |
|
NonCopyable & | operator= (NonCopyable &&)=default |
|
| NonMovable (NonMovable &&)=delete |
|
NonMovable & | operator= (NonMovable &&)=delete |
|
| NonMovable (const NonMovable &)=default |
|
NonMovable & | operator= (const NonMovable &)=default |
|
|
bool | postLoad () override |
|
void | reserveStorage () |
|
void | loadDataInternal (const ImageTools::ImageData &imageData, const vec3< U16 > &offset, const PixelAlignment &pixelUnpackAlignment) override |
|
void | loadDataInternal (const Byte *data, size_t size, U8 targetMip, const vec3< U16 > &offset, const vec3< U16 > &dimensions, const PixelAlignment &pixelUnpackAlignment) override |
|
void | prepareTextureData (U16 width, U16 height, U16 depth, bool emptyAllocation) override |
|
void | submitTextureData () override |
|
bool | loadFile (const ResourcePath &path, std::string_view name, ImageTools::ImageData &fileData) |
| Use STB to load a file into a Texture Object.
|
|
bool | checkTransparency (const ResourcePath &path, std::string_view name, ImageTools::ImageData &fileData) |
|
bool | loadInternal () |
| Load texture data using the specified file name.
|
|
void | validateDescriptor () |
|
virtual void | loadDataInternal (const ImageTools::ImageData &imageData, const vec3< U16 > &offset, const PixelAlignment &pixelUnpackAlignment)=0 |
|
virtual void | loadDataInternal (const Byte *data, size_t size, U8 targetMip, const vec3< U16 > &offset, const vec3< U16 > &dimensions, const PixelAlignment &pixelUnpackAlignment)=0 |
|
virtual void | prepareTextureData (U16 width, U16 height, U16 depth, bool emptyAllocation) |
|
virtual void | submitTextureData () |
|
| PROPERTY_RW (ResourcePath, assetLocation) |
|
| PROPERTY_RW (Str< 256 >, assetName) |
|
| PROPERTY_R (size_t, descriptorHash) |
|
virtual void | setState (ResourceState currentState) |
|
| GraphicsResource (GFXDevice &context, Type type, I64 GUID, U64 nameHash) |
|
| NonCopyable ()=default |
|
| ~NonCopyable ()=default |
|
| NonMovable ()=default |
|
| ~NonMovable ()=default |
|
Definition at line 42 of file glTexture.h.