MCPcopy Create free account
hub / github.com/crosire/reshade / SetComputeRootConstantBufferView

Method SetComputeRootConstantBufferView

source/d3d12/d3d12_command_list.cpp:633–653  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

631#endif
632}
633void STDMETHODCALLTYPE D3D12GraphicsCommandList::SetComputeRootConstantBufferView(UINT RootParameterIndex, D3D12_GPU_VIRTUAL_ADDRESS BufferLocation)
634{
635 _orig->SetComputeRootConstantBufferView(RootParameterIndex, BufferLocation);
636
637#if RESHADE_ADDON >= 2
638 if (!reshade::has_addon_event<reshade::addon_event::push_descriptors>())
639 return;
640
641 reshade::api::buffer_range buffer_range;
642 if (!_device_impl->resolve_gpu_address(BufferLocation, &buffer_range.buffer, &buffer_range.offset))
643 return;
644 buffer_range.size = UINT64_MAX;
645
646 reshade::invoke_addon_event<reshade::addon_event::push_descriptors>(
647 this,
648 reshade::api::shader_stage::all_compute | reshade::api::shader_stage::all_ray_tracing,
649 to_handle(_current_root_signature[1]),
650 RootParameterIndex,
651 reshade::api::descriptor_table_update { {}, 0, 0, 1, reshade::api::descriptor_type::constant_buffer, &buffer_range });
652#endif
653}
654void STDMETHODCALLTYPE D3D12GraphicsCommandList::SetGraphicsRootConstantBufferView(UINT RootParameterIndex, D3D12_GPU_VIRTUAL_ADDRESS BufferLocation)
655{
656 _orig->SetGraphicsRootConstantBufferView(RootParameterIndex, BufferLocation);

Callers 1

push_descriptorsMethod · 0.80

Calls 2

resolve_gpu_addressMethod · 0.80
to_handleFunction · 0.70

Tested by

no test coverage detected