Navigation
API > API/Runtime > API/Runtime/RenderCore
A rendering resource which is owned by the rendering thread.
| Name | FRenderResource |
| Type | class |
| Header File | /Engine/Source/Runtime/RenderCore/Public/RenderResource.h |
| Include Path | #include "RenderResource.h" |
Syntax
class FRenderResource
Derived Classes
FRenderResource derived class hierarchy
- FTextureCollectionResource
- TRenderResourcePool
- FBufferWithRDG
- FVertexFactory
- FVertexBuffer
- FMaterialRenderProxy
- FIndexBuffer
- TUniformBuffer
- FViewport
- FDuplicatedVerticesBuffer
- FEmptyResourceCollection
- FEmptyVertexDeclaration
- FFilterVertexDeclaration
- FGeometryCacheTrackStreamableRenderResource
- FGlobalBoundShaderStateResource
- FGlobalDynamicReadBuffer
- FHairCommonResource
- FStaticMeshInstanceBuffer
- FLandscapeTextureAtlas
- FLightmapResourceCluster
- FMediaVertexDeclaration
- FMorphTargetVertexInfoBuffers
- FNDIGeometryCollectionBuffer
- FNDIHairStrandsBuffer
- FNDIPhysicsAssetBuffer
- FNDIRigidMeshCollisionBuffer
- FNDIVelocityGridBuffer
- FParticleSortBuffers
- FPhysicsFieldResource
- FTexture
- FPrecomputedVolumetricLightmapData
- FRayTracingGeometry
- FRenderTargetPool
- FSceneTextureExtracts
- FScreenVertexDeclaration
- FShaderMapResource
- FSharedSamplerState
- FSimpleElementVertexDeclaration
- FSinglePrimitiveStructured
- FSkeletalMeshAttributeVertexBuffer
- FSkeletalMeshGpuDynamicBufferProxy
- FSkeletalMeshGpuSpawnStaticBuffers
- FSkeletalMeshHalfEdgeBuffer
- FSlateRenderTargetRHI
- FSlateTexture2DRHIRef
- FStaticMeshSectionAreaWeightedTriangleSamplerBuffer
- FStaticMeshVertexBuffer
- FStreamingManager
- FSubsurfaceProfileTexture
- FSystemTextures
- FTextureReference
- FTextureRenderResources
- FTileVertexDeclaration
- FVariableRateShadingImageManager
- FVertexFactoryResource
- FVisualizeTexture
- FVolumetricLightmapBrickAtlas
- TBoundShaderStateHistory
- TStaticStateRHI::FStaticStateResource
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FRenderResource
(
const FRenderResource& |
Misc copy/assignment | RenderResource.h | |
| RenderResource.h | |||
FRenderResource
(
ERHIFeatureLevel::Type InFeatureLevel |
Constructor when we know what feature level this resource should support | RenderResource.h | |
| Default constructor. | RenderResource.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FRenderResource() |
Destructor used to catch unreleased resources. | RenderResource.h |
Enums
Public
| Name | Remarks |
|---|---|
| EInitPhase | Controls initialization order of render resources. |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| ResourceState | ERenderResourceState | RenderResource.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| FeatureLevel | TEnumAsByte< ERHIFeatureLevel::Type > | RenderResource.h | ||
| InitPhase | EInitPhase | RenderResource.h | ||
| ListIndex | int32 | RenderResource.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual FString GetFriendlyName() |
RenderResource.h | ||
EInitPhase GetInitPhase() |
RenderResource.h | ||
int32 GetListIndex() |
RenderResource.h | ||
FName GetOwnerName() |
RenderResource.h | ||
FName GetResourceName() |
RenderResource.h | ||
virtual void InitResource
(
FRHICommandListBase& RHICmdList |
Initializes the resource. This is only called by the rendering thread. | RenderResource.h | |
virtual void InitRHI
(
FRHICommandListBase& RHICmdList |
Initializes the RHI resources used by this resource. | RenderResource.h | |
bool IsInitialized() |
Accessors. | RenderResource.h | |
virtual void ReleaseResource() |
Prepares the resource for deletion. This is only called by the rendering thread. | RenderResource.h | |
virtual void ReleaseRHI () |
Releases the RHI resources used by this resource. | RenderResource.h | |
void SetOwnerName
(
FName InOwnerName |
SetOwnerName should be called before BeginInitResource for the owner name to be successfully tracked. | RenderResource.h | |
void SetResourceName
(
FName InResourceName |
RenderResource.h | ||
void UpdateRHI
(
FRHICommandListBase& RHICmdList |
If the resource's RHI resources have been initialized, then release and reinitialize it. | RenderResource.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FBufferRHIRef CreateRHIBuffer
(
FRHICommandListBase& RHICmdList, |
Helper for submitting a resource array to RHI and freeing eligible CPU memory. | RenderResource.h | |
const FStaticFeatureLevel GetFeatureLevel() |
RenderResource.h | ||
bool HasValidFeatureLevel() |
RenderResource.h | ||
void SetFeatureLevel
(
const FStaticFeatureLevel InFeatureLevel |
This is used during mobile editor preview refactor, this will eventually be replaced with a parameter to InitRHI() etc.. | RenderResource.h | |
void SetInitPhase
(
EInitPhase InInitPhase |
RenderResource.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void ChangeFeatureLevel
(
ERHIFeatureLevel::Type NewFeatureLevel |
Reinitializes render resources at a new feature level. | RenderResource.h | |
static FBufferRHIRef CreateRHIBufferInternal
(
FRHICommandListBase& RHICmdList, |
RenderResource.h | ||
static FRHICommandListBase & GetImmediateCommandList() |
RenderResource.h | ||
static void InitPreRHIResources () |
Initialize all resources initialized before the RHI was initialized. | RenderResource.h | |
static void ReleaseRHIForAllResources() |
Release all render resources that are currently initialized. | RenderResource.h | |
| Set the scoped (thread local) resource name, used for error reporting | RenderResource.h | ||
static bool ShouldFreeResourceObject
(
void* ResourceObject, |
RenderResource.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FRenderResource & operator=
(
const FRenderResource& Other |
RenderResource.h | ||
FRenderResource & operator=
(
FRenderResource&& Other |
RenderResource.h |