FFmpeg
Data Structures | Functions | Variables
dfpwmenc.c File Reference
#include "libavutil/internal.h"
#include "avcodec.h"
#include "codec_id.h"
#include "codec_internal.h"
#include "encode.h"

Go to the source code of this file.

Data Structures

struct  DFPWMState
 

Functions

static void au_compress (DFPWMState *state, int len, uint8_t *outbuf, const uint8_t *inbuf)
 
static av_cold int dfpwm_enc_init (struct AVCodecContext *ctx)
 
static int dfpwm_enc_frame (struct AVCodecContext *ctx, struct AVPacket *packet, const struct AVFrame *frame, int *got_packet)
 

Variables

const FFCodec ff_dfpwm_encoder
 

Detailed Description

DFPWM1a encoder

Definition in file dfpwmenc.c.

Function Documentation

◆ au_compress()

static void au_compress ( DFPWMState state,
int  len,
uint8_t *  outbuf,
const uint8_t *  inbuf 
)
static

Definition at line 42 of file dfpwmenc.c.

Referenced by dfpwm_enc_frame().

◆ dfpwm_enc_init()

static av_cold int dfpwm_enc_init ( struct AVCodecContext ctx)
static

Definition at line 78 of file dfpwmenc.c.

◆ dfpwm_enc_frame()

static int dfpwm_enc_frame ( struct AVCodecContext ctx,
struct AVPacket packet,
const struct AVFrame frame,
int *  got_packet 
)
static

Definition at line 92 of file dfpwmenc.c.

Variable Documentation

◆ ff_dfpwm_encoder

const FFCodec ff_dfpwm_encoder
Initial value:
= {
.p.name = "dfpwm",
CODEC_LONG_NAME("DFPWM1a audio"),
.p.type = AVMEDIA_TYPE_AUDIO,
.priv_data_size = sizeof(DFPWMState),
.p.sample_fmts = (const enum AVSampleFormat[]){AV_SAMPLE_FMT_U8, AV_SAMPLE_FMT_NONE},
}

Definition at line 110 of file dfpwmenc.c.

dfpwm_enc_frame
static int dfpwm_enc_frame(struct AVCodecContext *ctx, struct AVPacket *packet, const struct AVFrame *frame, int *got_packet)
Definition: dfpwmenc.c:92
FF_CODEC_ENCODE_CB
#define FF_CODEC_ENCODE_CB(func)
Definition: codec_internal.h:320
AVMEDIA_TYPE_AUDIO
@ AVMEDIA_TYPE_AUDIO
Definition: avutil.h:202
AV_CODEC_CAP_ENCODER_REORDERED_OPAQUE
#define AV_CODEC_CAP_ENCODER_REORDERED_OPAQUE
This encoder can reorder user opaque values from input AVFrames and return them with corresponding ou...
Definition: codec.h:159
CODEC_LONG_NAME
#define CODEC_LONG_NAME(str)
Definition: codec_internal.h:296
dfpwm_enc_init
static av_cold int dfpwm_enc_init(struct AVCodecContext *ctx)
Definition: dfpwmenc.c:78
AV_CODEC_CAP_VARIABLE_FRAME_SIZE
#define AV_CODEC_CAP_VARIABLE_FRAME_SIZE
Audio encoder supports receiving a different number of samples in each call.
Definition: codec.h:128
init
int(* init)(AVBSFContext *ctx)
Definition: dts2pts.c:368
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
AV_SAMPLE_FMT_NONE
@ AV_SAMPLE_FMT_NONE
Definition: samplefmt.h:56
AV_SAMPLE_FMT_U8
@ AV_SAMPLE_FMT_U8
unsigned 8 bits
Definition: samplefmt.h:57
AVSampleFormat
AVSampleFormat
Audio sample formats.
Definition: samplefmt.h:55
DFPWMState
Definition: dfpwmdec.c:34
AV_CODEC_ID_DFPWM
@ AV_CODEC_ID_DFPWM
Definition: codec_id.h:536