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

◆ PressureProcessor() [2/2]

MayaFlux::Buffers::PressureProcessor::PressureProcessor ( std::string  divergence_field,
std::string  pressure_field,
const Portal::Graphics::ShaderSpec spec,
uint32_t  iterations = 40 
)

Construct a pressure solve stage from a generated ShaderSpec.

Parameters
divergence_fieldName of the scalar field read.
pressure_fieldName of the scalar field solved.
specShaderSpec implementing one Jacobi pass.
iterationsJacobi passes per cycle.

Definition at line 29 of file PressureProcessor.cpp.

34 : VolumeFieldProcessor(make_bindings(divergence_field, pressure_field), spec)
35 , m_divergence_field(std::move(divergence_field))
36 , m_pressure_field(std::move(pressure_field))
37{
39 set_iteration_count(iterations);
40}
void set_iteration_count(uint32_t count)
Set how many dispatches are recorded per execute cycle.
static std::vector< FieldBinding > make_bindings(const std::string &divergence_field, const std::string &pressure_field)
Build the binding table for the two field names.
VolumeFieldProcessor(std::vector< FieldBinding > bindings, const std::string &shader_path)
Construct from a shader path.
void add_swap_field(std::string field)
Register a field to swap after each dispatch.

References MayaFlux::Buffers::VolumeFieldProcessor::add_swap_field(), m_pressure_field, and MayaFlux::Buffers::ComputeProcessor::set_iteration_count().

+ Here is the call graph for this function: