ffmpeg.libavutil.samplefmt

Undocumented in source.

Members

Enums

AVSampleFormat
enum AVSampleFormat

Audio sample formats

Functions

av_get_alt_sample_fmt
AVSampleFormat av_get_alt_sample_fmt(AVSampleFormat sample_fmt, int planar)

Return the planar<->packed alternative form of the given sample format, or AV_SAMPLE_FMT_NONE on error. If the passed sample_fmt is already in the requested planar/packed format, the format returned is the same as the input.

av_get_bytes_per_sample
int av_get_bytes_per_sample(AVSampleFormat sample_fmt)

Return number of bytes per sample.

av_get_packed_sample_fmt
AVSampleFormat av_get_packed_sample_fmt(AVSampleFormat sample_fmt)

Get the packed alternative form of the given sample format.

av_get_planar_sample_fmt
AVSampleFormat av_get_planar_sample_fmt(AVSampleFormat sample_fmt)

Get the planar alternative form of the given sample format.

av_get_sample_fmt
AVSampleFormat av_get_sample_fmt(const(char)* name)

Return a sample format corresponding to name, or AV_SAMPLE_FMT_NONE on error.

av_get_sample_fmt_name
const(char)* av_get_sample_fmt_name(AVSampleFormat sample_fmt)

Return the name of sample_fmt, or NULL if sample_fmt is not recognized.

av_get_sample_fmt_string
char* av_get_sample_fmt_string(char* buf, int buf_size, AVSampleFormat sample_fmt)

Generate a string corresponding to the sample format with sample_fmt, or a header if sample_fmt is negative.

av_sample_fmt_is_planar
int av_sample_fmt_is_planar(AVSampleFormat sample_fmt)

Check if the sample format is planar.

av_samples_alloc
int av_samples_alloc(ubyte** audio_data, int* linesize, int nb_channels, int nb_samples, AVSampleFormat sample_fmt, int align_)

Allocate a samples buffer for nb_samples samples, and fill data pointers and linesize accordingly. The allocated samples buffer can be freed by using av_freep(&audio_data[0]) Allocated data will be initialized to silence.

av_samples_alloc_array_and_samples
int av_samples_alloc_array_and_samples(ubyte*** audio_data, int* linesize, int nb_channels, int nb_samples, AVSampleFormat sample_fmt, int align_)

Allocate a data pointers array, samples buffer for nb_samples samples, and fill data pointers and linesize accordingly.

av_samples_copy
int av_samples_copy(ubyte** dst, ubyte** src, int dst_offset, int src_offset, int nb_samples, int nb_channels, AVSampleFormat sample_fmt)

Copy samples from src to dst.

av_samples_fill_arrays
int av_samples_fill_arrays(ubyte** audio_data, int* linesize, const(ubyte)* buf, int nb_channels, int nb_samples, AVSampleFormat sample_fmt, int align_)

Fill plane data pointers and linesize for samples with sample format sample_fmt.

av_samples_get_buffer_size
int av_samples_get_buffer_size(int* linesize, int nb_channels, int nb_samples, AVSampleFormat sample_fmt, int align_)

Get the required buffer size for the given audio parameters.

av_samples_set_silence
int av_samples_set_silence(ubyte** audio_data, int offset, int nb_samples, int nb_channels, AVSampleFormat sample_fmt)

Fill an audio buffer with silence.

Meta