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

◆ bind_pipeline()

void MayaFlux::Portal::Graphics::ComputePress::bind_pipeline ( CommandBufferID  cmd_id,
ComputePipelineID  pipeline_id 
)

Bind pipeline to active command buffer.

Definition at line 214 of file ComputePress.cpp.

215{
216 auto pipeline_it = m_pipelines.find(pipeline_id);
217 if (pipeline_it == m_pipelines.end()) {
219 "Invalid pipeline ID: {}", pipeline_id);
220 return;
221 }
222
223 auto cmd = m_shader_foundry->get_command_buffer(cmd_id);
224 if (!cmd) {
226 "Invalid command buffer ID: {}", cmd_id);
227 return;
228 }
229
230 pipeline_it->second.pipeline->bind(cmd);
231}
#define MF_ERROR(comp, ctx,...)
std::unordered_map< ComputePipelineID, PipelineState > m_pipelines
vk::CommandBuffer get_command_buffer(CommandBufferID cmd_id)
Get Vulkan command buffer handle from CommandBufferID.
@ GPUCompute
GPU compute operations (shaders, GPGPU tasks)
@ Portal
High-level user-facing API layer.

References MayaFlux::Portal::Graphics::ShaderFoundry::get_command_buffer(), MayaFlux::Journal::GPUCompute, m_pipelines, m_shader_foundry, MF_ERROR, and MayaFlux::Journal::Portal.

Referenced by bind_all().

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