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

◆ process_pending_buffer_operations()

template<typename BufferType >
void MayaFlux::Buffers::RootBuffer< BufferType >::process_pending_buffer_operations ( )
inlineprotected

Process pending operations - call this at start of processing cycles.

Definition at line 249 of file RootBuffer.hpp.

250 {
251 for (auto& m_pending_op : m_pending_ops) {
252 if (m_pending_op.active.load(std::memory_order_acquire)) {
253 auto& op = m_pending_op;
254
255 if (op.is_addition) {
256 add_child_buffer_direct(op.buffer);
257 } else {
259 }
260
261 // Clear operation
262 op.buffer.reset();
263 op.active.store(false, std::memory_order_release);
264 m_pending_count.fetch_sub(1, std::memory_order_relaxed);
265 }
266 }
267 }
void remove_child_buffer_direct(std::shared_ptr< BufferType > buffer)
struct MayaFlux::Buffers::RootBuffer::PendingBufferOp m_pending_ops[MAX_PENDING]
void add_child_buffer_direct(std::shared_ptr< BufferType > buffer)
std::atomic< uint32_t > m_pending_count