Description

Static mesh that does not have Support Ray Tracing flag does not have a GeometryRHI object. So it causes a crash in FD3D12RayTracingScene.

Excluding instances that do not have a GerometyRHI in FDeferredShadingSceneRenderer::GaterRayTracingWorldInstances works as a workaround.

Steps to Reproduce
  1. Create a Raytracing enabled project
  2. Create/Duplicate and Open a static mesh
  3. Uncheck Support Ray Tracing in the Static Mesh
  4. Create new niagara emitter
  5. Add MeshRenderer in the emitter
  6. Set the static mesh in the MeshRenderer detail pane
Callstack

UE4.27

FD3D12RayTracingScene::FD3D12RayTracingScene(FD3D12Adapter * Adapter, const FRayTracingSceneInitializer & Initializer) Line 2820
FD3D12DynamicRHI::RHICreateRayTracingScene(const FRayTracingSceneInitializer & Initializer) Line 2231
FDeferredShadingSceneRenderer::DispatchRayTracingWorldUpdates(FRHICommandListImmediate & RHICmdList) Line 1148
FDeferredShadingSceneRenderer::Render(FRHICommandListImmediate & RHICmdList) Line 1782
RenderViewFamily_RenderThread(FRHICommandListImmediate & RHICmdList, FSceneRenderer * SceneRenderer) Line 3742
FRendererModule::BeginRenderingViewFamily::__l43::<lambda>(FRHICommandListImmediate & RHICmdList) Line 4008
TEnqueueUniqueRenderCommandType<`FRendererModule::BeginRenderingViewFamily'::`43'::FDrawSceneCommandName,void <lambda>(FRHICommandListImmediate &)>::DoTask(ENamedThreads::Type CurrentThread, const TRefCountPtr<FGraphEvent> & MyCompletionGraphEvent) Line 183
TGraphTask<TEnqueueUniqueRenderCommandType<`FRendererModule::BeginRenderingViewFamily'::`43'::FDrawSceneCommandName,void <lambda>(FRHICommandListImmediate &)>>::ExecuteTask(TArray<FBaseGraphTask *,TSizedDefaultAllocator<32>> & NewTasks, ENamedThreads::Type CurrentThread) Line 888
FNamedTaskThread::ProcessTasksNamedThread(int QueueIndex, bool bAllowStall) Line 710
FNamedTaskThread::ProcessTasksUntilQuit(int QueueIndex) Line 602
FTaskGraphImplementation::ProcessThreadUntilRequestReturn(ENamedThreads::Type CurrentThread) Line 1481
RenderingThreadMain(FEvent * TaskGraphBoundSyncEvent) Line 373
FRenderingThread::Run() Line 528
FRunnableThreadWin::Run() Line 84
FRunnableThreadWin::GuardedRun() Line 27
FRunnableThreadWin::_ThreadProc(void * pThis) Line 38

UE5 CL18416580

[Inline Frame] UnrealEditor-Renderer.dll!FDeferredShadingSceneRenderer::GatherRayTracingWorldInstancesForView::__l112::<lambda_4026edc39b360fc29d4f3d0780f35ee0>::operator()() Line 965	C++
UnrealEditor-Renderer.dll!DispatchCheckVerify<void,<lambda_4026edc39b360fc29d4f3d0780f35ee0>>(FDeferredShadingSceneRenderer::GatherRayTracingWorldInstancesForView::__l112::<lambda_4026edc39b360fc29d4f3d0780f35ee0> && Inner) Line 170	C++
UnrealEditor-Renderer.dll!FDeferredShadingSceneRenderer::GatherRayTracingWorldInstancesForView(FRDGBuilder & GraphBuilder, FViewInfo & View, FRayTracingScene & RayTracingScene) Line 965	C++
UnrealEditor-Renderer.dll!FDeferredShadingSceneRenderer::Render(FRDGBuilder & GraphBuilder) Line 2152	C++
UnrealEditor-Renderer.dll!RenderViewFamily_RenderThread(FRHICommandListImmediate & RHICmdList, FSceneRenderer * SceneRenderer) Line 4087	C++
UnrealEditor-Renderer.dll!FRendererModule::BeginRenderingViewFamily::__l46::<lambda>(FRHICommandListImmediate & RHICmdList) Line 4345	C++
UnrealEditor-Renderer.dll!TEnqueueUniqueRenderCommandType<`FRendererModule::BeginRenderingViewFamily'::`46'::FDrawSceneCommandName,void <lambda>(FRHICommandListImmediate &)>::DoTask(ENamedThreads::Type CurrentThread, const TRefCountPtr<FGraphEvent> & MyCompletionGraphEvent) Line 185	C++
UnrealEditor-Renderer.dll!TGraphTask<TEnqueueUniqueRenderCommandType<`FRendererModule::BeginRenderingViewFamily'::`46'::FDrawSceneCommandName,void <lambda>(FRHICommandListImmediate &)>>::ExecuteTask(TArray<FBaseGraphTask *,TSizedDefaultAllocator<32>> & NewTasks, ENamedThreads::Type CurrentThread, bool bDeleteOnCompletion) Line 980	C++
[Inline Frame] UnrealEditor-Core.dll!FBaseGraphTask::Execute(TArray<FBaseGraphTask *,TSizedDefaultAllocator<32>> & CurrentThread, ENamedThreads::Type) Line 587	C++
UnrealEditor-Core.dll!FNamedTaskThread::ProcessTasksNamedThread(int QueueIndex, bool bAllowStall) Line 753	C++
UnrealEditor-Core.dll!FNamedTaskThread::ProcessTasksUntilQuit(int QueueIndex) Line 642	C++
UnrealEditor-Core.dll!FTaskGraphCompatibilityImplementation::ProcessThreadUntilRequestReturn(ENamedThreads::Type CurrentThread) Line 2115	C++
UnrealEditor-RenderCore.dll!RenderingThreadMain(FEvent * TaskGraphBoundSyncEvent) Line 376	C++
UnrealEditor-RenderCore.dll!FRenderingThread::Run() Line 515	C++
UnrealEditor-Core.dll!FRunnableThreadWin::Run() Line 146	C++
UnrealEditor-Core.dll!FRunnableThreadWin::GuardedRun() Line 76	C++
[External Code]	

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-135874 in the post.

0
Login to Vote

Fixed
ComponentUE - Graphics Features
Affects Versions4.27.1
Target Fix5.0
Fix Commit18884301
Release Commit18884301
CreatedNov 24, 2021
ResolvedFeb 7, 2022
UpdatedJan 26, 2023
View Jira Issue