Points the descriptor set at the current buffer set, on any change of source or ring slot.
Rewriting a shared set is safe here because resolve_pending() has already retired the only submission that reads it, and the draw takes the milled buffer as vertex input rather than through this set.
Definition at line 592 of file PrimitiveMill.cpp.
593{
596 return;
597 }
598
600 const auto set =
m_sets.front();
601
602 const auto bind = [&](uint32_t binding, const std::shared_ptr<VKBuffer>& buf) {
603 foundry.update_descriptor_buffer(
604 set, binding, vk::DescriptorType::eStorageBuffer,
605 buf->get_buffer(), 0, buf->get_size_bytes());
606 };
607
608 bind(0, source);
612
616}
size_t m_bound_slot
Ring slot the descriptor set currently points at, for invalidation.
std::weak_ptr< Buffers::VKBuffer > m_bound_source
Source the descriptor set currently points at, for invalidation.
std::shared_ptr< Buffers::VKBuffer > m_prefix_buf
std::shared_ptr< Buffers::VKBuffer > m_run_buf
bool m_descriptors_written
std::vector< DescriptorSetID > m_sets
std::vector< std::shared_ptr< Buffers::VKBuffer > > m_outputs
Milled buffers rotated between dispatches, all at m_output_capacity.
MAYAFLUX_API ShaderFoundry & get_shader_foundry()
Get the global shader compiler instance.
References MayaFlux::Portal::Graphics::get_shader_foundry(), m_bound_slot, m_bound_source, m_descriptors_written, m_output_slot, m_outputs, m_prefix_buf, m_run_buf, and m_sets.
Referenced by mill().