@@ -2402,32 +2402,38 @@ bool D3D12Device::invoke_create_and_init_pipeline_event(const D3D12_PIPELINE_STA
2402
2402
continue ;
2403
2403
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_VS:
2404
2404
vs_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_VS *>(p)->data );
2405
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::vertex_shader, 1 , &vs_desc });
2405
+ if (vs_desc.code != nullptr )
2406
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::vertex_shader, 1 , &vs_desc });
2406
2407
p += sizeof (D3D12_PIPELINE_STATE_STREAM_VS);
2407
2408
continue ;
2408
2409
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_PS:
2409
2410
ps_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_PS *>(p)->data );
2410
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::pixel_shader, 1 , &ps_desc });
2411
+ if (ps_desc.code != nullptr )
2412
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::pixel_shader, 1 , &ps_desc });
2411
2413
p += sizeof (D3D12_PIPELINE_STATE_STREAM_PS);
2412
2414
continue ;
2413
2415
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_DS:
2414
2416
ds_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_DS *>(p)->data );
2415
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::domain_shader, 1 , &ds_desc });
2417
+ if (ds_desc.code != nullptr )
2418
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::domain_shader, 1 , &ds_desc });
2416
2419
p += sizeof (D3D12_PIPELINE_STATE_STREAM_DS);
2417
2420
continue ;
2418
2421
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_HS:
2419
2422
hs_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_HS *>(p)->data );
2420
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::hull_shader, 1 , &hs_desc });
2423
+ if (hs_desc.code != nullptr )
2424
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::hull_shader, 1 , &hs_desc });
2421
2425
p += sizeof (D3D12_PIPELINE_STATE_STREAM_HS);
2422
2426
continue ;
2423
2427
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_GS:
2424
2428
gs_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_GS *>(p)->data );
2425
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::geometry_shader, 1 , &gs_desc });
2429
+ if (gs_desc.code != nullptr )
2430
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::geometry_shader, 1 , &gs_desc });
2426
2431
p += sizeof (D3D12_PIPELINE_STATE_STREAM_GS);
2427
2432
continue ;
2428
2433
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_CS:
2429
2434
cs_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_CS *>(p)->data );
2430
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::compute_shader, 1 , &cs_desc });
2435
+ if (cs_desc.code != nullptr )
2436
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::compute_shader, 1 , &cs_desc });
2431
2437
p += sizeof (D3D12_PIPELINE_STATE_STREAM_CS);
2432
2438
continue ;
2433
2439
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_STREAM_OUTPUT:
@@ -2514,12 +2520,14 @@ bool D3D12Device::invoke_create_and_init_pipeline_event(const D3D12_PIPELINE_STA
2514
2520
continue ;
2515
2521
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_AS:
2516
2522
as_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_AS *>(p)->data );
2517
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::amplification_shader, 1 , &as_desc });
2523
+ if (as_desc.code != nullptr )
2524
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::amplification_shader, 1 , &as_desc });
2518
2525
p += sizeof (D3D12_PIPELINE_STATE_STREAM_AS);
2519
2526
continue ;
2520
2527
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_MS:
2521
2528
ms_desc = reshade::d3d12::convert_shader_desc (reinterpret_cast <const D3D12_PIPELINE_STATE_STREAM_MS *>(p)->data );
2522
- subobjects.push_back ({ reshade::api::pipeline_subobject_type::mesh_shader, 1 , &ms_desc });
2529
+ if (ms_desc.code != nullptr )
2530
+ subobjects.push_back ({ reshade::api::pipeline_subobject_type::mesh_shader, 1 , &ms_desc });
2523
2531
p += sizeof (D3D12_PIPELINE_STATE_STREAM_MS);
2524
2532
continue ;
2525
2533
case D3D12_PIPELINE_STATE_SUBOBJECT_TYPE_DEPTH_STENCIL2:
0 commit comments