FChildTextureFormat

Version of [ITextureFormat](API\Developer\TargetPlatform\Interfaces\ITextureFormat) that handles a child texture format that is used as a "post-process" after compressing textures, useful for several platforms that need to modify already compressed texture data for optimal data

Windows
MacOS
Linux

Inheritance Hierarchy

ITextureFormat

FChildTextureFormat

References

Module

TargetPlatform

Header

/Engine/Source/Developer/TargetPlatform/Public/ChildTextureFormat.h

Include

#include "ChildTextureFormat.h"

Syntax

class FChildTextureFormat : public ITextureFormat

Remarks

Version of ITextureFormat that handles a child texture format that is used as a "post-process" after compressing textures, useful for several platforms that need to modify already compressed texture data for optimal data

Variables

Name Description

Protected variable

TArray< FName >

 

BaseFormats

List of base formats that. Combined with FormatPrefix, this contains all formats this can handle.

Protected variable

FString

 

FormatPrefix

Prefix put before all formats from parent formats.

Constructors

Name Description

Public function

FChildTextureFormat

(
    const TCHAR* PlatformFormatPre...
)

Functions

Name Description

Protected function

void

 

AddBaseTextureFormatModules

(
    const TCHAR* ModuleNameWildcar...
)

Public function Const

bool

 

CompressBaseImage

(
    const FImage& InImage,
    const FTextureBuildSettings& Build...,
    bool bImageHasAlphaChannel,
    FCompressedImage2D& OutCompressedI...
)

Public function Const

bool

 

CompressBaseImageTiled

(
    const FImage* Images,
    uint32 NumImages,
    const FTextureBuildSettings& Build...,
    bool bImageHasAlphaChannel,
    TSharedPtr< FTilerSettings >& Tile...,
    FCompressedImage2D& OutCompressedI...
)

Protected function Const

FName

 

GetBaseFormatName

(
    FName PlatformName
)

Protected function Const

const ITextu...

 

GetBaseFormatObject

(
    FName PlatformName
)

Given a platform specific format name, get the parent texture format object

Protected function Const

FString

 

GetChildDerivedDataKeyString

(
    const UTexture& Texture,
    const FTextureBuildSettings* B...
)

Make the child type think about if they need a key string or not, by making it pure virtual

Protected function Const

uint8

 

GetChildFormatVersion

(
    FName Format,
    const FTextureBuildSettings* B...
)

The final version is a combination of parent and child formats, 8 bits for each

Overridden from ITextureFormat

Name Description

Public function Virtual Const

FString

 

GetDerivedDataKeyString

(
    const UTexture& Texture,
    const FTextureBuildSettings* B...
)

Gets an optional derived data key string, so that the compressor can rely upon the number of mips, size of texture, etc, when compressing the image

Public function Virtual Const

EPixelFormat

 

GetPixelFormatForImage

(
    const FTextureBuildSettings& Build...,
    const FImage& Image,
    bool bImageHasAlphaChannel
)

Calculate the final/runtime pixel format for this image on this platform

Public function Virtual Const

void

 

GetSupportedFormats

(
    TArray< FName >& OutFormats
)

Gets the list of supported formats.

Public function Virtual Const

uint16

 

GetVersion

(
    FName Format,
    const FTextureBuildSettings* B...
)

Gets the current version of the specified texture format.

Public function Virtual Const

bool

 

PrepareTiling

(
    const FImage* Images,
    const uint32 NumImages,
    const FTextureBuildSettings& Build...,
    bool bImageHasAlphaChannel,
    TSharedPtr< FTilerSettings >& OutT...,
    TArray< FCompressedImage2D >& OutC...
)

Prepares to compresses a single image with tiling.

Public function Virtual Const

void

 

ReleaseTiling

(
    const FTextureBuildSettings& Build...,
    TSharedPtr< FTilerSettings >& Tile...
)

Cleans up the FTilerSettings object once it is finished.

Public function Virtual Const

bool

 

SetTiling

(
    const FTextureBuildSettings& Build...,
    TSharedPtr< FTilerSettings >& Tile...,
    const TArray64< uint8 >& Reordered...,
    uint32 NumBlocks
)

Sets the tiling settings after device-specific tiling has been performed.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss