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

◆ VertexFieldProcessor()

MayaFlux::Buffers::VertexFieldProcessor::VertexFieldProcessor ( std::shared_ptr< Nodes::Network::GpuFieldOperator >  field_operator)
explicit
Parameters
field_operatorOperator supplying the generated spec. Must already carry at least one binding and a layout with a position attribute, since the shader is compiled during construction. Throws std::invalid_argument when build_spec() yields nothing.

Definition at line 63 of file VertexFieldProcessor.cpp.

65 : ComputeProcessor(require_spec(field_operator))
66 , m_operator(std::move(field_operator))
67 , m_built_revision(m_operator->revision())
68 , m_needs_cluster_id(m_operator->needs_cluster_id())
69{
71
72 add_binding("vertices",
73 ShaderBinding(0, m_operator->get_vertex_binding(),
75
77 add_binding("cluster_id",
78 ShaderBinding(0, m_operator->get_vertex_binding() + 1,
80 }
81
82 m_params.stride_words = m_operator->get_layout().stride_bytes / 4;
83
85}
ComputeProcessor(const std::string &shader_path, uint32_t workgroup_x=256)
Construct processor with shader path.
void set_push_constant_data(const T &data)
Update push constant data (type-safe)
void add_binding(const std::string &descriptor_name, const ShaderBinding &binding)
Add descriptor binding configuration.
std::shared_ptr< Nodes::Network::GpuFieldOperator > m_operator
@ GRAPHICS_BACKEND
Standard graphics processing backend configuration.
@ STORAGE
Large arrays or buffers the shader may write (SSBO)

References MayaFlux::Buffers::ShaderProcessor::add_binding(), MayaFlux::Buffers::GRAPHICS_BACKEND, m_needs_cluster_id, m_operator, m_params, MayaFlux::Buffers::BufferProcessor::m_processing_token, MayaFlux::Buffers::ShaderProcessor::set_push_constant_data(), MayaFlux::Portal::Graphics::STORAGE, and MayaFlux::Buffers::VertexFieldProcessor::RangeParams::stride_words.

+ Here is the call graph for this function: