![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <UnrealClient.h>
Inheritance diagram for FRenderTarget:Static Public Member Functions | |
| static float | GetEngineDisplayGamma () |
Protected Attributes | |
| FTextureRHIRef | RenderTargetTextureRHI |
A render target.
|
default |
Default constructor
|
virtualdefault |
Destructor
|
inlinevirtual |
Reimplemented in FDummyViewport, and FSceneViewport.
|
virtual |
Reimplemented in FPlanarReflectionRenderTarget, FRenderTargetTexture, FSceneViewport, FSlateTextureRenderTarget2DResource, FTextureRenderTarget2DArrayResource, FTextureRenderTargetVolumeResource, FTextureRenderTargetResource, FTextureRenderTarget2DResource, and FTextureRenderTargetCubeResource.
|
inlinevirtual |
Reimplemented in FDummyViewport, and FSceneViewport.
|
static |
|
inlinevirtual |
Returns the GPU nodes on which to render this render target.
Reimplemented in FTextureRenderTargetResource, FPlanarReflectionRenderTarget, and FViewport.
|
virtual |
Accessor for the surface RHI when setting this render target
Reimplemented in FSceneViewport, FSlateCanvasRenderTarget, and FRDGCanvasRenderTarget.
|
virtual |
Returns a valid RDG texture for this render target.
Reimplemented in FSlateCanvasRenderTarget, and FRDGCanvasRenderTarget.
|
virtual |
Reimplemented in FDummyViewport, and FSceneViewport.
|
virtual |
Accessor for the surface RHI to use when reading the reading target (may differ from GetRenderTargetTexture() for some implementations like cubemaps)
Reimplemented in FTextureRenderTargetResource.
Implemented in FSlateCanvasRenderTarget, FPlanarReflectionRenderTarget, FRenderTargetTexture, FRDGCanvasRenderTarget, FSlateTextureRenderTarget2DResource, FTextureRenderTarget2DArrayResource, FTextureRenderTargetVolumeResource, FTextureRenderTarget2DResource, FTextureRenderTargetCubeResource, FViewport, FViewport::FHitProxyMap, FMediaTextureResource, and FWebBrowserTextureResource.
Returns if there is a command to toggle freezerendering
Reimplemented in FViewport.
Handles freezing/unfreezing of rendering
Reimplemented in FViewport.
| PRAGMA_DISABLE_DEPRECATION_WARNINGS bool FRenderTarget::ReadFloat16Pixels | ( | TArray< FFloat16Color > & | OutImageData, |
| ECubeFace | CubeFace | ||
| ) |
Reads the render target's displayed pixels into the given color buffer.
| OutImageData | - RGBA16F values will be stored in this buffer |
| CubeFace | - optional cube face for when reading from a cube render target |
|
virtual |
Reads the render target's displayed pixels into the given color buffer.
| OutImageData | - RGBA16F values will be stored in this buffer |
| InFlags | - Additional information about how to to read the surface data (cube face, slice index, etc.) |
| InSrcRect | - InSrcRect not specified means the whole rect |
The default value for InFlags specifies RCM_UNorm which will cause values to be scaled into [0,1] ; use RCM_MinMax to retrieve values without change.
Unlike other RenderTarget Read functions, this only works if surface is PF_FloatRGBA exactly ; it does not convert. Prefer using FImageUtils::GetRenderTargetImage rather than calling this directly.
Reimplemented in FTextureRenderTargetVolumeResource.
|
virtual |
Reads the render target's displayed pixels into the given color buffer.
| OutImageData | - Linear color array to store the value |
| InFlags | - Additional information about how to to read the surface data (cube face, slice index, etc.) |
| InSrcRect | - InSrcRect not specified means the whole rect |
The default value for InFlags specifies RCM_UNorm which will cause values to be scaled into [0,1] ; use RCM_MinMax to retrieve values without change.
This will convert whatever the pixel format is to FLinearColor (if supported). Prefer using FImageUtils::GetRenderTargetImage rather than calling this directly.
Reimplemented in FTextureRenderTargetVolumeResource.
| bool FRenderTarget::ReadLinearColorPixelsPtr | ( | FLinearColor * | OutImageBytes, |
| FReadSurfaceDataFlags | InFlags = FReadSurfaceDataFlags(RCM_MinMax, CubeFace_MAX), |
||
| FIntRect | InSrcRect = FIntRect(0, 0, 0, 0) |
||
| ) |
Reads the render target's displayed pixels into the given color buffer.
| OutImageBytes | - Linear color array will be stored in this buffer. Buffer must be preallocated with the correct size! |
| InFlags | - Additional information about how to to read the surface data (cube face, slice index, etc.) |
| InSrcRect | - InSrcRect not specified means the whole rect |
Ptr variant of this API just does an extra memcpy; prefer the TArray variant. Prefer using FImageUtils::GetRenderTargetImage rather than calling this directly.
|
virtual |
Reads the render target's displayed pixels into a preallocated color buffer.
| OutImageData | - RGBA8 values will be stored in this buffer |
| InFlags | - Additional information about how to to read the surface data (cube face, slice index, etc.) |
| InSrcRect | - InSrcRect not specified means the whole rect |
This will convert whatever the pixel format is to FColor Prefer using FImageUtils::GetRenderTargetImage rather than calling this directly.
The default value for InFlags specifies RCM_UNorm which will cause values to be scaled into [0,1] ; use RCM_MinMax to retrieve values without change.
If the RenderTarget surface is float linear, it will converted to SRGB FColor, if InFlags.bLinearToGamma is set (which is on by default). If the RenderTarget surface is U8, then the SRGB/not state is unchanged, the U8 values are retrieved unchanged in either Linear or SRGB. Gamma is handled correctly automatically by FImageUtils::GetRenderTargetImage
Reimplemented in FTextureRenderTargetCubeResource, FTextureRenderTarget2DArrayResource, and FTextureRenderTargetVolumeResource.
| bool FRenderTarget::ReadPixelsPtr | ( | FColor * | OutImageBytes, |
| FReadSurfaceDataFlags | InFlags = FReadSurfaceDataFlags(RCM_UNorm, CubeFace_MAX), |
||
| FIntRect | InSrcRect = FIntRect(0, 0, 0, 0) |
||
| ) |
Reads the render target's displayed pixels into a preallocated color buffer.
| OutImageBytes | - RGBA8 values will be stored in this buffer. Buffer must be preallocated with the correct size! |
| InFlags | - Additional information about how to to read the surface data (cube face, slice index, etc.) |
| InSrcRect | - InSrcRect not specified means the whole rect |
Ptr variant of this API just does an extra memcpy; prefer the TArray variant. Prefer using FImageUtils::GetRenderTargetImage rather than calling this directly.
|
protected |