Navigation
API > API/Plugins > API/Plugins/MutableRuntime > API/Plugins/MutableRuntime/MuR
Inheritance Hierarchy
- Base
- RefCounted
- Resource
- Image
References
| Module | MutableRuntime |
| Header | /Engine/Plugins/Experimental/Mutable/Source/MutableRuntime/Public/MuR/Image.h |
| Include | #include "MuR/Image.h" |
Syntax
class Image : public mu::Resource
Remarks
2D image resource with mipmaps.
Variables
| Type | Name | Description | |
|---|---|---|---|
| ImageDataContainerType | m_data | ||
| uint8 | m_flags | Persistent flags with some image properties. The meaning will depend of every context. | |
| EImageFormat | m_format | ||
| uint8 | m_lods | Levels of detail (mipmaps) | |
| FImageSize | m_size | ||
| uint32 | ReferenceID | Only valid if the right flags are set, this identifies a referenced image. | |
| uint16 | RelevancyMaxY | ||
| uint16 | RelevancyMinY | Non-persistent relevancy map. |
Constructors
| Type | Name | Description | |
|---|---|---|---|
Image () |
Life cycle. | ||
Image
(
uint32 sizeX, |
Constructor from the size and format. |
Destructors
| Type | Name | Description | |
|---|---|---|---|
~Image () |
Forbidden. Manage with the Ptr<> template. |
Functions
| Type | Name | Description | |
|---|---|---|---|
| int32 | Calculate the size of the image data in bytes, regardless of what is allocated in m_data, only using the image descriptions. | ||
| int32 | CalculateDataSize
(
int lod |
Calculate the size of a lod of the image data in bytes, regardless of what is allocated in m_data, only using the image descriptions. | |
| int32 | CalculateDataSize
(
int32 SizeX, |
Calculate the size of the image data in bytes, regardless of what is allocated in m_data, only using the image descriptions. | |
| FIntVector2 | CalculateMipSize
(
int lod |
Calculate the size in pixels of a particular mipmap of this image. | |
| int32 | CalculatePixelCount
(
int lod |
Same as above, but only calculates the pixels of an lod. | |
| int32 | Calculate the number of pixels of the image, regardless of what is allocated in m_data, only using the image descriptions. | ||
| Ptr< Image > | Clone () |
Deep clone. | |
| void | Copy another image. | ||
| void | |||
| Ptr< Image > | CreateAsReference
(
uint32 ID |
||
| uint8 * | GetData () |
Return a pointer to a instance-owned buffer where the image pixels are. | |
| const uint8 * | GetData () |
Return a pointer to a instance-owned buffer where the image pixels are. | |
| EImageFormat | GetFormat () |
Return the pixel format of the image. | |
| int | GetLODCount () |
Return the number of levels of detail (mipmaps) in the texture. | |
| int32 | GetLODDataSize
(
int lod |
Return the size in bytes of a specific LOD of the image. | |
| uint8 * | GetMipData
(
int mip |
Return a pointer to the beginning of the data for a particular mip. | |
| const uint8 * | GetMipData
(
int mip |
Return a pointer to the beginning of the data for a particular mip. | |
| int | GetMipmapCount
(
int SizeX, |
Calculate the number of mipmaps for a particular image size. | |
| int32 | Return the size of the resident mips. | ||
| void | GetNonBlackRect
(
FImageRect& rect |
Get the rect inside the image bounding the non-black content of the image. | |
| void | GetNonBlackRect_Reference
(
FImageRect& rect |
Get the rect inside the image bounding the non-black content of the image. | |
| uint32 | Return the id of the engine referenced texture. Only valid if IsReference. | ||
| const FImageSize & | GetSize () |
||
| uint16 | GetSizeX () |
Return the width of the image. | |
| uint16 | GetSizeY () |
Return the height of the image. | |
| void | InitToBlack () |
Clear the image to black colour. | |
| bool | IsFullAlpha () |
See if all the pixels in the alpha channel are the max value of the pixel format (white). | |
| bool | IsPlainColour
(
FVector4f& colour |
See if all the pixels in the image are equal and return the colour. | |
| bool | IsReference () |
Return true if this is a reference to an engine image. | |
| void | ReduceLODs
(
int32 LODsToSkip |
Reduce the LODs of the image to the given amount. | |
| void | ReduceLODsTo
(
int32 NewLODCount |
Reduce the LODs of the image to the given amount. | |
| FVector4f | Sample
(
FVector2f coords |
Sample the image and return an RGB colour. | |
| void | Serialise
(
OutputArchive& arch |
||
| void | Serialise
(
const Image* p, |
Serialisation. | |
| Ptr< Image > | StaticUnserialise
(
InputArchive& arch |
||
| void | Unserialise
(
InputArchive& arch |
Overridden from Resource
| Type | Name | Description | |
|---|---|---|---|
| int32 | GetDataSize () |
Return the size in bytes of all the LODs of the image. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| bool | operator==
(
const Image& o |
Enums
| Type | Name | Description | |
|---|---|---|---|
| EImageFlags | These set of flags are used to cache information for images at runtime. |
Typedefs
| Name | Description |
|---|---|
| ImageDataContainerType | Pixel data for all lods. |