Sound Open Firmware
Loading...
Searching...
No Matches

Audio source API helpers and stream configuration. More...

Include dependency graph for source_api.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void source_init (struct sof_source *source, const struct source_ops *ops, struct sof_audio_stream_params *audio_stream_params)
 Initialize source API structure before any operation.
 
size_t source_get_num_of_processed_bytes (struct sof_source *source)
 Get total number of bytes processed by the source (freed by source_release_data()).
 
void source_reset_num_of_processed_bytes (struct sof_source *source)
 Reset counter of total processed bytes to zero.
 
bool source_get_underrun (struct sof_source *source)
 Check if buffer underrun is permitted on source stream.
 
uint32_t source_get_id (struct sof_source *source)
 Get unique stream identifier for source.
 
int source_set_frm_fmt (struct sof_source *source, enum sof_ipc_frame frm_fmt)
 Set audio frame format for source.
 
int source_set_valid_fmt (struct sof_source *source, enum sof_ipc_frame valid_sample_fmt)
 Set valid sample format for source.
 
int source_set_rate (struct sof_source *source, unsigned int rate)
 Set sample rate for source.
 
int source_set_channels (struct sof_source *source, unsigned int channels)
 Set channel count for source.
 
int source_set_underrun (struct sof_source *source, bool underrun_permitted)
 Configure whether underrun is permitted on source.
 
int source_set_buffer_fmt (struct sof_source *source, uint32_t buffer_fmt)
 Set buffer format for source.
 
void source_set_min_available (struct sof_source *source, size_t min_available)
 Set minimum available data requirement in bytes.
 
int source_set_params (struct sof_source *source, struct sof_ipc_stream_params *params, bool force_update)
 Configure initial set of audio parameters.
 
int source_set_alignment_constants (struct sof_source *source, const uint32_t byte_align, const uint32_t frame_align_req)
 Set byte and frame alignment constants for source stream.
 

Detailed Description

Audio source API helpers and stream configuration.