Navigation
API > API/Developer > API/Developer/TextureFormat
Everything necessary to know the memory layout for an encoded untiled unpacked texture (i.e. enough information to describe the texture entirely to a PC hardware API). Once a texture gets tiled or gets a packed mip tail, FEncodedTextureEncodedData is additionally required to know the memory layout.
| Name | FEncodedTextureDescription |
| Type | struct |
| Header File | /Engine/Source/Developer/TextureFormat/Public/Interfaces/ITextureFormat.h |
| Include Path | #include "Interfaces/ITextureFormat.h" |
Syntax
struct FEncodedTextureDescription
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| FSharedBufferMipChain | TArray< FSharedBuffer, TInlineAllocator< FEncodedTextureExtendedData::MAX_TEXTURE_MIP_COUNT > > | Interfaces/ITextureFormat.h | |
| FUniqueBufferMipChain | TArray< FUniqueBuffer, TInlineAllocator< FEncodedTextureExtendedData::MAX_TEXTURE_MIP_COUNT > > | Interfaces/ITextureFormat.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| ArraySlices | int32 | Interfaces/ITextureFormat.h | ||
| bCubeMap | bool | Interfaces/ITextureFormat.h | ||
| bTextureArray | bool | Interfaces/ITextureFormat.h | ||
| bVolumeTexture | bool | Interfaces/ITextureFormat.h | ||
| NumMips | uint8 | Interfaces/ITextureFormat.h | ||
| PixelFormat | EPixelFormat | Interfaces/ITextureFormat.h | ||
| TopMipSizeX | int32 | Interfaces/ITextureFormat.h | ||
| TopMipSizeY | int32 | Interfaces/ITextureFormat.h | ||
| TopMipVolumeSizeZ | int32 | Interfaces/ITextureFormat.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FEncodedTextureDescription GetDescriptionForMipLevel
(
const FEncodedTextureExtendedData* InExtendedData, |
Returns the description for the single mip level (i.e. no further mips) | Interfaces/ITextureFormat.h | |
void GetEncodedMipIterators
(
const FEncodedTextureExtendedData* InExtendedData, |
Convenience function for iterating over the encoded mips when you need to know how many mips are represented. | Interfaces/ITextureFormat.h | |
void GetLinearMipSizesInBytes
(
TArray< uint64, TInlineAllocator< FEncodedTextureExtendedData::MAX_TEXTURE_MIP_COUNT > >& OutMipSiz... |
Fills out the given array with linear mip sizes for the number of mips this texture has. | Interfaces/ITextureFormat.h | |
int32 GetMipDepth
(
int32 InMipIndex |
Always 1 unless volume texture. | Interfaces/ITextureFormat.h | |
FIntVector3 GetMipDimensions
(
int32 InMipIndex |
Returns the size of the mip at the given index. Z is 1 unless it's a volume texture. | Interfaces/ITextureFormat.h | |
int32 GetMipHeight
(
int32 InMipIndex |
Interfaces/ITextureFormat.h | ||
uint64 GetMipSizeInBytes
(
int32 InMipIndex |
Returns the byte size of the unpacked/tiled mip. For mip chains that are packed or tiled, use FEncodedTextureExtendedData::MipSizesInBytes. | Interfaces/ITextureFormat.h | |
uint64 GetMipSliceRowPitchBytes
(
int32 InMipIndex |
Returns the bytes necessary to get to the next row of the current mip. | Interfaces/ITextureFormat.h | |
uint64 GetMipSliceSizeInBytes
(
int32 InMipIndex |
As GetMipSizeInBytes, except for a single slice of the mip. | Interfaces/ITextureFormat.h | |
int32 GetMipWidth
(
int32 InMipIndex |
Interfaces/ITextureFormat.h | ||
int32 GetNumEncodedMips
(
const FEncodedTextureExtendedData* InExtendedData |
Returns the number of mips that actually carry bulk data for this texture. | Interfaces/ITextureFormat.h | |
int32 GetNumNonStreamingMips
(
const FEncodedTextureExtendedData* InExtendedData, |
This is the number of nonstreaming mips that works for cooking and thus is aware of block alignment concerns for runtime use. | Interfaces/ITextureFormat.h | |
int32 GetNumSlices_NoDepth() |
Returns the slice count for usage cases/platforms that expect slice count to only include cubemap/array slices. | Interfaces/ITextureFormat.h | |
int32 GetNumSlices_WithDepth
(
int32 InMipIndex |
Returns the slice count for usage cases/platform that expect slice count to include volume texture depth. | Interfaces/ITextureFormat.h | |
int32 GetNumStreamingMips
(
const FEncodedTextureExtendedData* InExtendedData, |
This is the number of streaming mips without any restrictions associated with block size alignment. | Interfaces/ITextureFormat.h | |
int32 GetRHIStyleSizeZ
(
int32 InMipIndex |
This returns the SizeZ value that is expected by RHI streamable texture structures. | Interfaces/ITextureFormat.h | |
FEncodedTextureDescription RemoveTopMips
(
const FEncodedTextureExtendedData* InExtendedData, |
Interfaces/ITextureFormat.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static int32 GetMipDepth
(
int32 InTextureDepth, |
Interfaces/ITextureFormat.h | ||
static int32 GetMipHeight
(
int32 InTextureHeight, |
Interfaces/ITextureFormat.h | ||
static int32 GetMipWidth
(
int32 InTextureWidth, |
Interfaces/ITextureFormat.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool operator==
(
const FEncodedTextureDescription& OtherTextureDescription |
Interfaces/ITextureFormat.h |