4.22 preview5, FTextureRenderTargetCubeResource.ReadPixels crashes

Shirlman
Tue, 12 Mar 2019 11:13:13 +0000
C++

After enable dx12 for raytracing, ReadPixels crashes in 4.22 preview4, the following code work well in 4.21

code snippet：
FTextureRenderTargetCubeResource* CubeResource = (FTextureRenderTargetCubeResource*)SceneCapture->GetCaptureComponentCube()->TextureTarget->GameThread_GetRenderTargetResource();
CubeResource->ReadPixels(SurfaceData, FReadSurfaceDataFlags(RCM_UNorm, CubeFace_NegX));

log:
DestTexture2D is nullptr

Fatal error: [File:D:\Build++UE4\Sync\Engine\Source\Runtime\RenderCore\Private\RenderingThread.cpp] [Line: 819]
Rendering thread exception:
Fatal error!

1 post - 1 participant