oveRTOS C API
Embedded RTOS framework — build system, configuration, and portable C API
Loading...
Searching...
No Matches
Data Structures | Macros | Enumerations | Functions
audio.h File Reference
#include "ove/audio_node.h"
#include "ove/storage.h"
Include dependency graph for audio.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ove_audio_edge
 Directed connection between two nodes in the audio graph. More...
 
struct  ove_audio_graph_stats
 Runtime diagnostic counters for an audio graph. More...
 
struct  ove_audio_graph
 Audio processing graph instance. More...
 

Macros

#define OVE_AUDIO_GRAPH_MAX_NODES   16
 Maximum number of nodes in a single audio graph.
 
#define OVE_AUDIO_GRAPH_MAX_EDGES   16
 Maximum number of edges in a single audio graph.
 
#define OVE_AUDIO_GRAPH_STORAGE_BYTES(nodes, frames, channels, sample_bytes)    ((size_t)(nodes) * (size_t)(frames) * (size_t)(channels) * (size_t)(sample_bytes))
 Conservative upper-bound byte count for graph buffer storage.
 
#define OVE_AUDIO_GRAPH_DEFINE(name, nodes, frames, channels, sample_bytes)
 Declare named static storage for an audio graph and its buffers.
 

Enumerations

enum  ove_audio_graph_state { OVE_AUDIO_GRAPH_IDLE , OVE_AUDIO_GRAPH_READY , OVE_AUDIO_GRAPH_RUNNING }
 Lifecycle state of an audio graph. More...
 

Functions

int ove_audio_graph_init (struct ove_audio_graph *g, unsigned int frames_per_period)
 Initialise an audio graph.
 
void ove_audio_graph_deinit (struct ove_audio_graph *g)
 Release all resources held by an audio graph.
 
int ove_audio_graph_add_node (struct ove_audio_graph *g, const struct ove_audio_node_ops *ops, void *ctx, const char *name, enum ove_audio_node_type type)
 Register a new node in the graph.
 
int ove_audio_graph_connect (struct ove_audio_graph *g, unsigned int from, unsigned int to)
 Connect two nodes with a directed edge.
 
int ove_audio_graph_set_buf_storage (struct ove_audio_graph *g, void *storage, size_t size)
 Provide caller-owned storage for inter-node audio buffers.
 
int ove_audio_graph_build (struct ove_audio_graph *g)
 Validate and compile the graph.
 
int ove_audio_graph_start (struct ove_audio_graph *g)
 Start the audio graph.
 
int ove_audio_graph_stop (struct ove_audio_graph *g)
 Stop the audio graph.
 
int ove_audio_graph_process (struct ove_audio_graph *g)
 Execute one processing cycle (app-driven mode).
 
int ove_audio_graph_get_stats (const struct ove_audio_graph *g, struct ove_audio_graph_stats *stats)
 Retrieve a snapshot of graph runtime statistics.