46 int16_t *output_samples;
59 output_samples = (int16_t *)frame->
data[0];
62 for (i = 0; i < 256; i++)
67 *output_samples++ = cb[*src++];
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
This structure describes decoded (raw) audio or video data.
#define PAF_SOUND_FRAME_SIZE
ptrdiff_t const GLvoid * data
#define AV_CH_LAYOUT_STEREO
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_RL16
static double cb(void *priv, double x, double y)
enum AVSampleFormat sample_fmt
audio sample format
static int paf_audio_decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *pkt)
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
const char * name
Name of the codec implementation.
uint64_t channel_layout
Audio channel layout.
Libavcodec external API header.
main external API structure.
int ff_get_buffer(AVCodecContext *avctx, AVFrame *frame, int flags)
Get a buffer for a frame.
#define PAF_SOUND_SAMPLES
static av_const int sign_extend(int val, unsigned bits)
uint8_t * data[AV_NUM_DATA_POINTERS]
pointer to the picture/channel planes.
AVCodec ff_paf_audio_decoder
static av_cold int paf_audio_init(AVCodecContext *avctx)
common internal api header.
int channels
number of audio channels
This structure stores compressed data.
int nb_samples
number of audio samples (per channel) described by this frame
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.