FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
utils.c File Reference
#include "libavutil/common.h"
#include "libavutil/dict.h"
#include "libavutil/frame.h"
#include "libavutil/log.h"
#include "libavutil/mem.h"
#include "libavutil/opt.h"
#include "avresample.h"
#include "internal.h"
#include "audio_data.h"
#include "audio_convert.h"
#include "audio_mix.h"
#include "resample.h"

Go to the source code of this file.

Macros

#define LICENSE_PREFIX   "libavresample license: "
 

Functions

int avresample_open (AVAudioResampleContext *avr)
 Initialize AVAudioResampleContext. More...
 
int avresample_is_open (AVAudioResampleContext *avr)
 Check whether an AVAudioResampleContext is open or closed. More...
 
void avresample_close (AVAudioResampleContext *avr)
 Close AVAudioResampleContext. More...
 
void avresample_free (AVAudioResampleContext **avr)
 Free AVAudioResampleContext and associated AVOption values. More...
 
static int handle_buffered_output (AVAudioResampleContext *avr, AudioData *output, AudioData *converted)
 
int attribute_align_arg avresample_convert (AVAudioResampleContext *avr, uint8_t **output, int out_plane_size, int out_samples, uint8_t *const *input, int in_plane_size, int in_samples)
 Convert input samples and write them to the output FIFO. More...
 
int avresample_config (AVAudioResampleContext *avr, AVFrame *out, AVFrame *in)
 Configure or reconfigure the AVAudioResampleContext using the information provided by the AVFrames. More...
 
static int config_changed (AVAudioResampleContext *avr, AVFrame *out, AVFrame *in)
 
static int convert_frame (AVAudioResampleContext *avr, AVFrame *out, AVFrame *in)
 
static int available_samples (AVFrame *out)
 
int avresample_convert_frame (AVAudioResampleContext *avr, AVFrame *out, AVFrame *in)
 Convert the samples in the input AVFrame and write them to the output AVFrame. More...
 
int avresample_get_matrix (AVAudioResampleContext *avr, double *matrix, int stride)
 Get the current channel mixing matrix. More...
 
int avresample_set_matrix (AVAudioResampleContext *avr, const double *matrix, int stride)
 Set channel mixing matrix. More...
 
int avresample_set_channel_mapping (AVAudioResampleContext *avr, const int *channel_map)
 Set a customized input channel mapping. More...
 
int avresample_available (AVAudioResampleContext *avr)
 Return the number of available samples in the output FIFO. More...
 
int avresample_get_out_samples (AVAudioResampleContext *avr, int in_nb_samples)
 Provide the upper bound on the number of samples the configured conversion would output. More...
 
int avresample_read (AVAudioResampleContext *avr, uint8_t **output, int nb_samples)
 Read samples from the output FIFO. More...
 
unsigned avresample_version (void)
 Return the LIBAVRESAMPLE_VERSION_INT constant. More...
 
const char * avresample_license (void)
 Return the libavresample license. More...
 
const char * avresample_configuration (void)
 Return the libavresample build-time configuration. More...
 

Macro Definition Documentation

#define LICENSE_PREFIX   "libavresample license: "

Referenced by avresample_license().

Function Documentation

static int handle_buffered_output ( AVAudioResampleContext avr,
AudioData output,
AudioData converted 
)
static

Definition at line 287 of file utils.c.

Referenced by avresample_convert().

static int config_changed ( AVAudioResampleContext avr,
AVFrame out,
AVFrame in 
)
static

Definition at line 526 of file utils.c.

Referenced by avresample_convert_frame().

static int convert_frame ( AVAudioResampleContext avr,
AVFrame out,
AVFrame in 
)
inlinestatic

Definition at line 550 of file utils.c.

Referenced by avresample_convert_frame().

static int available_samples ( AVFrame out)
inlinestatic

Definition at line 587 of file utils.c.

Referenced by avresample_convert_frame().