ETextureCreateFlags

Flags used for texture creation

Windows
MacOS
Linux

References

Module

RHI

Header

/Engine/Source/Runtime/RHI/Public/RHIDefinitions.h

Include

#include "RHIDefinitions.h"

Syntax

enum ETextureCreateFlags
{
    TexCreate_None                              = 0,
    TexCreate_RenderTargetable                  = 1<<0,
    TexCreate_ResolveTargetable                 = 1<<1,
    TexCreate_DepthStencilTargetable            = 1<<2,
    TexCreate_ShaderResource                    = 1<<3,
    TexCreate_SRGB                              = 1<<4,
    TexCreate_CPUWritable                       = 1<<5,
    TexCreate_NoTiling                          = 1<<6,
    TexCreate_VideoDecode                       = 1<<7,
    TexCreate_Dynamic                           = 1<<8,
    TexCreate_InputAttachmentRead               = 1<<9,
    TexCreate_DisableAutoDefrag                 = 1<<10,
    TexCreate_Memoryless                        = 1<<11,
    TexCreate_GenerateMipCapable                = 1<<12,
    TexCreate_FastVRAMPartialAlloc              = 1<<13,
    TexCreate_DisableSRVCreation                = 1 << 14,
    TexCreate_DisableDCC                        = 1 << 15,
    TexCreate_UAV                               = 1<<16,
    TexCreate_Presentable                       = 1<<17,
    TexCreate_CPUReadback                       = 1<<18,
    TexCreate_OfflineProcessed                  = 1<<19,
    TexCreate_FastVRAM                          = 1<<20,
    TexCreate_HideInVisualizeTexture            = 1<<21,
    TexCreate_Virtual                           = 1<<22,
    TexCreate_TargetArraySlicesIndependently    = 1<<23,
    TexCreate_Shared                            = 1 << 24,
    TexCreate_NoFastClear                       = 1 << 25,
    TexCreate_DepthStencilResolveTarget         = 1 << 26,
    TexCreate_Streamable                        = 1 << 27,
    TexCreate_NoFastClearFinalize               = 1 << 28,
    TexCreate_AFRManual                         = 1 << 29,
    TexCreate_ReduceMemoryWithTilingMode        = 1 << 30,
    TexCreate_Transient                         = 1 << 31,
}

Values

Name

Description

TexCreate_None

TexCreate_RenderTargetable

Texture can be used as a render target.

TexCreate_ResolveTargetable

Texture can be used as a resolve target.

TexCreate_DepthStencilTargetable

Texture can be used as a depth-stencil target.

TexCreate_ShaderResource

Texture can be used as a shader resource.

TexCreate_SRGB

Texture is encoded in sRGB gamma space.

TexCreate_CPUWritable

Texture data is writable by the CPU.

TexCreate_NoTiling

Texture will be created with an un-tiled format.

TexCreate_VideoDecode

Texture will be used for video decode.

TexCreate_Dynamic

Texture that may be updated every frame.

TexCreate_InputAttachmentRead

Texture will be used as a render pass attachment that will be read from.

TexCreate_DisableAutoDefrag

Disable automatic defragmentation if the initial texture memory allocation fails.

TexCreate_Memoryless

This texture has no GPU or CPU backing. It only exists in tile memory on TBDR GPUs (i.e., mobile).

TexCreate_GenerateMipCapable

Create the texture with the flag that allows mip generation later, only applicable to D3D11.

TexCreate_FastVRAMPartialAlloc

The texture can be partially allocated in fastvram.

TexCreate_DisableSRVCreation

Do not create associated shader resource view, only applicable to D3D11 and D3D12.

TexCreate_DisableDCC

Do not allow Delta Color Compression (DCC) to be used with this texture.

TexCreate_UAV

UnorderedAccessView (DX11 only) Warning: Causes additional synchronization between draw calls when using a render target allocated with this flag, use sparingly See: GCNPerformanceTweets.pdf Tip 37

TexCreate_Presentable

Render target texture that will be displayed on screen (back buffer)

TexCreate_CPUReadback

Texture data is accessible by the CPU.

TexCreate_OfflineProcessed

Texture was processed offline (via a texture conversion process for the current platform)

TexCreate_FastVRAM

Texture needs to go in fast VRAM if available (HINT only)

TexCreate_HideInVisualizeTexture

By default the texture is not showing up in the list - this is to reduce clutter, using the FULL option this can be ignored

TexCreate_Virtual

Texture should be created in virtual memory, with no physical memory allocation made You must make further calls to RHIVirtualTextureSetFirstMipInMemory to allocate physical memory and RHIVirtualTextureSetFirstMipVisible to map the first mip visible to the GPU

TexCreate_TargetArraySlicesIndependently

Creates a RenderTargetView for each array slice of the texture Warning: if this was specified when the resource was created, you can't use SV_RenderTargetArrayIndex to route to other slices!

TexCreate_Shared

Texture that may be shared with DX9 or other devices.

TexCreate_NoFastClear

RenderTarget will not use full-texture fast clear functionality.

TexCreate_DepthStencilResolveTarget

Texture is a depth stencil resolve target.

TexCreate_Streamable

Flag used to indicted this texture is a streamable 2D texture, and should be counted towards the texture streaming pool budget.

TexCreate_NoFastClearFinalize

Render target will not FinalizeFastClear; Caches and meta data will be flushed, but clearing will be skipped (avoids potentially trashing metadata)

TexCreate_AFRManual

Hint to the driver that this resource is managed properly by the engine for Alternate-Frame-Rendering in mGPU usage.

TexCreate_ReduceMemoryWithTilingMode

Workaround for 128^3 volume textures getting bloated 4x due to tiling mode on PS4.

TexCreate_Transient

Texture should be allocated from transient memory.

Remarks

Flags used for texture creation

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