FFmpeg
Functions | Variables
ws-snd1.c File Reference
#include <stdint.h>
#include "libavutil/channel_layout.h"
#include "libavutil/common.h"
#include "libavutil/intreadwrite.h"
#include "avcodec.h"
#include "codec_internal.h"
#include "decode.h"

Go to the source code of this file.

Functions

static av_cold int ws_snd_decode_init (AVCodecContext *avctx)
 
static int ws_snd_decode_frame (AVCodecContext *avctx, AVFrame *frame, int *got_frame_ptr, AVPacket *avpkt)
 

Variables

static const int8_t ws_adpcm_4bit []
 
const FFCodec ff_ws_snd1_decoder
 

Detailed Description

Westwood SNDx codecs

Reference documents about VQA format and its audio codecs can be found here: http://www.multimedia.cx

Definition in file ws-snd1.c.

Function Documentation

◆ ws_snd_decode_init()

static av_cold int ws_snd_decode_init ( AVCodecContext avctx)
static

Definition at line 45 of file ws-snd1.c.

◆ ws_snd_decode_frame()

static int ws_snd_decode_frame ( AVCodecContext avctx,
AVFrame frame,
int got_frame_ptr,
AVPacket avpkt 
)
static

Definition at line 54 of file ws-snd1.c.

Variable Documentation

◆ ws_adpcm_4bit

const int8_t ws_adpcm_4bit[]
static
Initial value:
= {
-9, -8, -6, -5, -4, -3, -2, -1,
0, 1, 2, 3, 4, 5, 6, 8
}

Definition at line 40 of file ws-snd1.c.

Referenced by ws_snd_decode_frame().

◆ ff_ws_snd1_decoder

const FFCodec ff_ws_snd1_decoder
Initial value:
= {
.p.name = "ws_snd1",
CODEC_LONG_NAME("Westwood Audio (SND1)"),
.p.type = AVMEDIA_TYPE_AUDIO,
}

Definition at line 173 of file ws-snd1.c.

ws_snd_decode_init
static av_cold int ws_snd_decode_init(AVCodecContext *avctx)
Definition: ws-snd1.c:45
FF_CODEC_DECODE_CB
#define FF_CODEC_DECODE_CB(func)
Definition: codec_internal.h:287
AVMEDIA_TYPE_AUDIO
@ AVMEDIA_TYPE_AUDIO
Definition: avutil.h:202
CODEC_LONG_NAME
#define CODEC_LONG_NAME(str)
Definition: codec_internal.h:272
AV_CODEC_CAP_CHANNEL_CONF
#define AV_CODEC_CAP_CHANNEL_CONF
Codec should fill in channel configuration and samplerate instead of container.
Definition: codec.h:106
AV_CODEC_CAP_DR1
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() or get_encode_buffer() for allocating buffers and supports custom allocators.
Definition: codec.h:52
ws_snd_decode_frame
static int ws_snd_decode_frame(AVCodecContext *avctx, AVFrame *frame, int *got_frame_ptr, AVPacket *avpkt)
Definition: ws-snd1.c:54
AV_CODEC_ID_WESTWOOD_SND1
@ AV_CODEC_ID_WESTWOOD_SND1
Definition: codec_id.h:457