MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ write_field_descriptors()

void MayaFlux::Buffers::VolumeFieldProcessor::write_field_descriptors ( )
private

Issue descriptor writes for every entry in the binding table.

Definition at line 205 of file VolumeFieldProcessor.cpp.

206{
207 if (!m_volume || m_descriptor_set_ids.empty()) {
208 return;
209 }
210
211 auto& foundry = Portal::Graphics::get_shader_foundry();
212
213 for (const auto& entry : m_bindings) {
214 const vk::Buffer handle = entry.access == FieldAccess::READ
215 ? m_volume->read_handle(entry.field)
216 : m_volume->write_handle(entry.field);
217
218 foundry.update_descriptor_buffer(
219 m_descriptor_set_ids[0], entry.binding, vk::DescriptorType::eStorageBuffer,
220 handle, 0, m_volume->get_field_bytes(entry.field));
221 }
222}
std::vector< Portal::Graphics::DescriptorSetID > m_descriptor_set_ids
std::shared_ptr< VolumeGridBuffer > m_volume
The attached volume, null until on_attach validates it.
@ READ
Resolves to VolumeGridBuffer::read_handle.
MAYAFLUX_API ShaderFoundry & get_shader_foundry()
Get the global shader compiler instance.

References MayaFlux::Portal::Graphics::get_shader_foundry(), m_bindings, MayaFlux::Buffers::ShaderProcessor::m_descriptor_set_ids, m_volume, and READ.

Referenced by on_descriptors_created(), and processing_function().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: