FFmpeg
Data Structures | Macros | Functions | Variables
cafenc.c File Reference
#include "avformat.h"
#include "caf.h"
#include "isom.h"
#include "avio_internal.h"
#include "libavutil/intfloat.h"
#include "libavutil/dict.h"

Go to the source code of this file.

Data Structures

struct  CAFContext
 

Macros

#define FRAME_SIZE_OFFSET   40
 

Functions

static uint32_t codec_flags (enum AVCodecID codec_id)
 
static uint32_t samples_per_packet (enum AVCodecID codec_id, int channels, int block_align)
 
static int caf_write_header (AVFormatContext *s)
 
static int caf_write_packet (AVFormatContext *s, AVPacket *pkt)
 
static int caf_write_trailer (AVFormatContext *s)
 

Variables

const AVOutputFormat ff_caf_muxer
 

Macro Definition Documentation

◆ FRAME_SIZE_OFFSET

#define FRAME_SIZE_OFFSET   40

Definition at line 29 of file cafenc.c.

Function Documentation

◆ codec_flags()

static uint32_t codec_flags ( enum AVCodecID  codec_id)
static

Definition at line 38 of file cafenc.c.

Referenced by caf_write_header(), and set_encoder_id().

◆ samples_per_packet()

static uint32_t samples_per_packet ( enum AVCodecID  codec_id,
int  channels,
int  block_align 
)
static

Definition at line 55 of file cafenc.c.

Referenced by caf_write_header(), and caf_write_trailer().

◆ caf_write_header()

static int caf_write_header ( AVFormatContext s)
static

Definition at line 104 of file cafenc.c.

◆ caf_write_packet()

static int caf_write_packet ( AVFormatContext s,
AVPacket pkt 
)
static

Definition at line 208 of file cafenc.c.

◆ caf_write_trailer()

static int caf_write_trailer ( AVFormatContext s)
static

< mNumberPackets

< mNumberValidFrames

< mPrimingFrames

< mRemainderFrames

Definition at line 237 of file cafenc.c.

Variable Documentation

◆ ff_caf_muxer

const AVOutputFormat ff_caf_muxer
Initial value:
= {
.name = "caf",
.long_name = NULL_IF_CONFIG_SMALL("Apple CAF (Core Audio Format)"),
.mime_type = "audio/x-caf",
.extensions = "caf",
.priv_data_size = sizeof(CAFContext),
.audio_codec = AV_CODEC_ID_PCM_S16BE,
.video_codec = AV_CODEC_ID_NONE,
.codec_tag = ff_caf_codec_tags_list,
}

Definition at line 269 of file cafenc.c.

caf_write_packet
static int caf_write_packet(AVFormatContext *s, AVPacket *pkt)
Definition: cafenc.c:208
AV_CODEC_ID_PCM_S16BE
@ AV_CODEC_ID_PCM_S16BE
Definition: codec_id.h:315
caf_write_header
static int caf_write_header(AVFormatContext *s)
Definition: cafenc.c:104
write_trailer
static int write_trailer(AVFormatContext *s1)
Definition: v4l2enc.c:98
NULL_IF_CONFIG_SMALL
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
Definition: internal.h:117
write_packet
static void write_packet(OutputFile *of, AVPacket *pkt, OutputStream *ost, int unqueue)
Definition: ffmpeg.c:731
AV_CODEC_ID_NONE
@ AV_CODEC_ID_NONE
Definition: codec_id.h:48
caf_write_trailer
static int caf_write_trailer(AVFormatContext *s)
Definition: cafenc.c:237
ff_caf_codec_tags_list
const AVCodecTag *const ff_caf_codec_tags_list[]
Definition: caf.c:81
CAFContext
Definition: cafenc.c:31
write_header
static void write_header(FFV1Context *f)
Definition: ffv1enc.c:347