|
MayaFlux 0.1.0
Digital-First Multimedia Processing Framework
|
Processor that bridges computational nodes and data buffers. More...
#include <NodeBuffer.hpp>
Inheritance diagram for MayaFlux::Buffers::NodeSourceProcessor:
Collaboration diagram for MayaFlux::Buffers::NodeSourceProcessor:Public Member Functions | |
| NodeSourceProcessor (std::shared_ptr< Nodes::Node > node, float mix=0.5f, bool clear_before_process=true) | |
| Creates a new processor that connects a computational node to data buffers. | |
| void | processing_function (std::shared_ptr< Buffer > buffer) override |
| Captures node computation output into a buffer. | |
| void | set_mix (float mix) |
| Sets the interpolation coefficient between existing and incoming data. | |
| float | get_mix () const |
| Gets the current interpolation coefficient. | |
Public Member Functions inherited from MayaFlux::Buffers::BufferProcessor | |
| virtual | ~BufferProcessor ()=default |
| Virtual destructor for proper cleanup of derived classes. | |
| void | process (std::shared_ptr< Buffer > buffer) |
| Applies a computational transformation to the data in the provided buffer. | |
| virtual void | on_attach (std::shared_ptr< Buffer >) |
| Called when this processor is attached to a buffer. | |
| virtual void | on_detach (std::shared_ptr< Buffer >) |
| Called when this processor is detached from a buffer. | |
| virtual void | set_processing_token (ProcessingToken token) |
| Gets the preferred processing backend for this processor. | |
| virtual ProcessingToken | get_processing_token () const |
| Gets the current processing token for this buffer. | |
| virtual bool | is_compatible_with (std::shared_ptr< Buffer >) const |
| Checks if this processor can handle the specified buffer type. | |
Private Member Functions | |
| std::vector< double > | get_node_data (uint32_t num_samples) |
| Gets a batch of data from the node. | |
| void | update_buffer (std::vector< double > &buffer_data) |
| Updates the buffer data with node output. | |
Private Attributes | |
| std::shared_ptr< Nodes::Node > | m_node |
| Source node that generates sequential data values. | |
| float | m_mix |
| Interpolation coefficient between existing and incoming data (0.0-1.0) | |
| bool | m_clear_before_process |
| Whether to reset the buffer before adding node output. | |
Additional Inherited Members | |
Protected Attributes inherited from MayaFlux::Buffers::BufferProcessor | |
| ProcessingToken | m_processing_token { ProcessingToken::AUDIO_BACKEND } |
Processor that bridges computational nodes and data buffers.
NodeSourceProcessor serves as a data flow connector between the node computation system and the buffer storage system, enabling the capture and persistence of dynamically generated values. This component is fundamental for integrating real-time, sample-by-sample computational processes with block-based data storage and transformation.
Key capabilities:
This processor enables powerful computational patterns such as:
Definition at line 32 of file NodeBuffer.hpp.