FFmpeg
Loading...
Searching...
No Matches
swfenc.c File Reference
#include "config_components.h"
#include "libavcodec/put_bits.h"
#include "libavutil/avassert.h"
#include "libavutil/fifo.h"
#include "avformat.h"
#include "flv.h"
#include "mux.h"
#include "swf.h"

Go to the source code of this file.

Data Structures

struct  SWFEncContext
 

Macros

#define AUDIO_FIFO_SIZE   65536
 
#define FRAC_BITS   16
 

Functions

static void put_swf_tag (AVFormatContext *s, int tag)
 
static void put_swf_end_tag (AVFormatContext *s)
 
static void max_nbits (int *nbits_ptr, int val)
 
static void put_swf_rect (AVIOContext *pb, int xmin, int xmax, int ymin, int ymax)
 
static void put_swf_line_edge (PutBitContext *pb, int dx, int dy)
 
static void put_swf_matrix (AVIOContext *pb, int a, int b, int c, int d, int tx, int ty)
 
static int swf_write_header (AVFormatContext *s)
 
static int fifo_avio_wrapper (void *opaque, void *buf, size_t *nb_elems)
 
static int swf_write_video (AVFormatContext *s, AVCodecParameters *par, const uint8_t *buf, int size, unsigned pkt_flags)
 
static int swf_write_audio (AVFormatContext *s, AVCodecParameters *par, const uint8_t *buf, int size)
 
static int swf_write_packet (AVFormatContext *s, AVPacket *pkt)
 
static int swf_write_trailer (AVFormatContext *s)
 
static void swf_deinit (AVFormatContext *s)
 

Macro Definition Documentation

◆ AUDIO_FIFO_SIZE

#define AUDIO_FIFO_SIZE   65536

Definition at line 33 of file swfenc.c.

Referenced by swf_write_header().

◆ FRAC_BITS

#define FRAC_BITS   16

Definition at line 157 of file swfenc.c.

Function Documentation

◆ put_swf_tag()

static void put_swf_tag ( AVFormatContext * s,
int tag )
static

Definition at line 49 of file swfenc.c.

Referenced by swf_write_header(), swf_write_trailer(), and swf_write_video().

◆ put_swf_end_tag()

static void put_swf_end_tag ( AVFormatContext * s)
static

Definition at line 65 of file swfenc.c.

Referenced by swf_write_header(), swf_write_trailer(), and swf_write_video().

◆ max_nbits()

static void max_nbits ( int * nbits_ptr,
int val )
inlinestatic

Definition at line 87 of file swfenc.c.

Referenced by put_swf_line_edge(), put_swf_matrix(), and put_swf_rect().

◆ put_swf_rect()

static void put_swf_rect ( AVIOContext * pb,
int xmin,
int xmax,
int ymin,
int ymax )
static

Definition at line 103 of file swfenc.c.

Referenced by swf_write_header().

◆ put_swf_line_edge()

static void put_swf_line_edge ( PutBitContext * pb,
int dx,
int dy )
static

Definition at line 130 of file swfenc.c.

Referenced by swf_write_header().

◆ put_swf_matrix()

static void put_swf_matrix ( AVIOContext * pb,
int a,
int b,
int c,
int d,
int tx,
int ty )
static

Definition at line 159 of file swfenc.c.

Referenced by swf_write_header(), and swf_write_video().

◆ swf_write_header()

static int swf_write_header ( AVFormatContext * s)
static

Definition at line 195 of file swfenc.c.

◆ fifo_avio_wrapper()

static int fifo_avio_wrapper ( void * opaque,
void * buf,
size_t * nb_elems )
static

Definition at line 360 of file swfenc.c.

◆ swf_write_video()

static int swf_write_video ( AVFormatContext * s,
AVCodecParameters * par,
const uint8_t * buf,
int size,
unsigned pkt_flags )
static

Definition at line 366 of file swfenc.c.

Referenced by swf_write_audio(), and swf_write_packet().

◆ swf_write_audio()

static int swf_write_audio ( AVFormatContext * s,
AVCodecParameters * par,
const uint8_t * buf,
int size )
static

Definition at line 477 of file swfenc.c.

Referenced by swf_write_packet().

◆ swf_write_packet()

static int swf_write_packet ( AVFormatContext * s,
AVPacket * pkt )
static

Definition at line 501 of file swfenc.c.

◆ swf_write_trailer()

static int swf_write_trailer ( AVFormatContext * s)
static

Definition at line 510 of file swfenc.c.

◆ swf_deinit()

static void swf_deinit ( AVFormatContext * s)
static

Definition at line 535 of file swfenc.c.