UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
Texture.cpp File Reference
#include "Engine/Texture.h"
#include "EngineLogs.h"
#include "Modules/ModuleManager.h"
#include "Materials/Material.h"
#include "MaterialShared.h"
#include "Math/ColorList.h"
#include "Misc/ConfigCacheIni.h"
#include "Misc/FeedbackContext.h"
#include "UObject/AssetRegistryTagsContext.h"
#include "UObject/UObjectIterator.h"
#include "UObject/ObjectSaveContext.h"
#include "UObject/Package.h"
#include "Engine/Texture2D.h"
#include "Engine/TextureMipDataProviderFactory.h"
#include "ContentStreaming.h"
#include "EngineUtils.h"
#include "IImageWrapper.h"
#include "IImageWrapperModule.h"
#include "Engine/Engine.h"
#include "Interfaces/ITargetPlatform.h"
#include "Interfaces/ITargetPlatformManagerModule.h"
#include "AssetCompilingManager.h"
#include "Engine/TextureLODSettings.h"
#include "RenderUtils.h"
#include "ObjectCacheContext.h"
#include "Rendering/StreamableTextureResource.h"
#include "RenderingThread.h"
#include "Interfaces/ITextureFormat.h"
#include "Interfaces/ITextureFormatModule.h"
#include "UObject/UE5MainStreamObjectVersion.h"
#include "Compression/OodleDataCompression.h"
#include "Engine/TextureCube.h"
#include "Engine/RendererSettings.h"
#include "ColorManagement/ColorSpace.h"
#include "ImageCoreBP.h"
#include "ImageCoreUtils.h"
#include "ImageCoreDelta.h"
#include "ImageUtils.h"
#include "Algo/Unique.h"
#include "DeviceProfiles/DeviceProfile.h"
#include "DeviceProfiles/DeviceProfileManager.h"
#include "Async/ParallelFor.h"
#include "VirtualTextureEnum.h"

Macros

#define CASE_ENUM_TO_TEXT(txt)   case txt: return TEXT(#txt);
 
#define TEXT_TO_ENUM(eVal, txt)   if (FCString::Stricmp(TEXT(#eVal), txt) == 0) return eVal;
 
#define TEXT_TO_MIPGENSETTINGS(m)   TEXT_TO_ENUM(m, InStr);
 

Functions

 DEFINE_LOG_CATEGORY (LogTexture)
 
 DEFINE_LOG_CATEGORY (LogTextureUpload)
 
const TCHARLexToString (FTextureSource::ELockState State)
 
FName GetLatestOodleTextureSdkVersion ()
 
FName GetDefaultTextureFormatName (const ITargetPlatformSettings *TargetPlatformSettings, const ITargetPlatformControls *TargetPlatformControls, const UTexture *Texture, int32 LayerIndex, bool bSupportCompressedVolumeTexture, int32 Unused_BlockSize, bool bSupportFilteredFloat32Textures)
 
FName GetDefaultTextureFormatName (const ITargetPlatform *TargetPlatform, const UTexture *Texture, int32 LayerIndex, bool bSupportCompressedVolumeTexture, int32 Unused_BlockSize, bool bSupportFilteredFloat32Textures)
 
void GetDefaultTextureFormatNamePerLayer (TArray< FName > &OutFormatNames, const class ITargetPlatformSettings *TargetPlatformSettings, const class ITargetPlatformControls *TargetPlatformControls, const class UTexture *Texture, bool bSupportCompressedVolumeTexture, int32 Unused_BlockSize, bool bSupportFilteredFloat32Textures)
 
void GetDefaultTextureFormatNamePerLayer (TArray< FName > &OutFormatNames, const class ITargetPlatform *TargetPlatform, const class UTexture *Texture, bool bSupportCompressedVolumeTexture, int32 Unused_BlockSize, bool bSupportFilteredFloat32Textures)
 
void GetAllDefaultTextureFormats (const class ITargetPlatformSettings *TargetPlatformSettings, TArray< FName > &OutFormats)
 
void GetAllDefaultTextureFormats (const class ITargetPlatform *TargetPlatform, TArray< FName > &OutFormats)
 

Variables

int32 GSkipInvalidDXTDimensions = 1
 
ENGINE_API bool GDisableAutomaticTextureMaterialUpdateDependencies = false
 

Macro Definition Documentation

◆ CASE_ENUM_TO_TEXT

#define CASE_ENUM_TO_TEXT (   txt)    case txt: return TEXT(#txt);

Helper functions for text output of texture properties...

◆ TEXT_TO_ENUM

#define TEXT_TO_ENUM (   eVal,
  txt 
)    if (FCString::Stricmp(TEXT(#eVal), txt) == 0) return eVal;

◆ TEXT_TO_MIPGENSETTINGS

#define TEXT_TO_MIPGENSETTINGS (   m)    TEXT_TO_ENUM(m, InStr);

Function Documentation

◆ DEFINE_LOG_CATEGORY() [1/2]

DEFINE_LOG_CATEGORY ( LogTexture  )

◆ DEFINE_LOG_CATEGORY() [2/2]

DEFINE_LOG_CATEGORY ( LogTextureUpload  )

◆ GetAllDefaultTextureFormats() [1/2]

void GetAllDefaultTextureFormats ( const class ITargetPlatform TargetPlatform,
TArray< FName > &  OutFormats 
)

◆ GetAllDefaultTextureFormats() [2/2]

void GetAllDefaultTextureFormats ( const class ITargetPlatformSettings TargetPlatformSettings,
TArray< FName > &  OutFormats 
)

◆ GetDefaultTextureFormatName() [1/2]

FName GetDefaultTextureFormatName ( const ITargetPlatform TargetPlatform,
const UTexture Texture,
int32  LayerIndex,
bool  bSupportCompressedVolumeTexture,
int32  Unused_BlockSize,
bool  bSupportFilteredFloat32Textures 
)

◆ GetDefaultTextureFormatName() [2/2]

FName GetDefaultTextureFormatName ( const ITargetPlatformSettings TargetPlatformSettings,
const ITargetPlatformControls TargetPlatformControls,
const UTexture Texture,
int32  LayerIndex,
bool  bSupportCompressedVolumeTexture,
int32  Unused_BlockSize,
bool  bSupportFilteredFloat32Textures 
)

IF you add a format to this function don't forget to update GetAllDefaultTextureFormats

◆ GetDefaultTextureFormatNamePerLayer() [1/2]

void GetDefaultTextureFormatNamePerLayer ( TArray< FName > &  OutFormatNames,
const class ITargetPlatform TargetPlatform,
const class UTexture Texture,
bool  bSupportCompressedVolumeTexture,
int32  Unused_BlockSize,
bool  bSupportFilteredFloat32Textures 
)

Gets an array of format names for each layer in the texture

◆ GetDefaultTextureFormatNamePerLayer() [2/2]

void GetDefaultTextureFormatNamePerLayer ( TArray< FName > &  OutFormatNames,
const class ITargetPlatformSettings TargetPlatformSettings,
const class ITargetPlatformControls TargetPlatformControls,
const class UTexture Texture,
bool  bSupportCompressedVolumeTexture,
int32  Unused_BlockSize,
bool  bSupportFilteredFloat32Textures 
)

◆ GetLatestOodleTextureSdkVersion()

FName GetLatestOodleTextureSdkVersion ( )
extern

◆ LexToString()

const TCHAR * LexToString ( FTextureSource::ELockState  State)

Convert FTextureSource::ELockState to TCHAR*

Variable Documentation

◆ GDisableAutomaticTextureMaterialUpdateDependencies

ENGINE_API bool GDisableAutomaticTextureMaterialUpdateDependencies = false

◆ GSkipInvalidDXTDimensions

int32 GSkipInvalidDXTDimensions = 1