|
FFmpeg
2.1.1
|
libavformat API example. More...
#include <stdlib.h>#include <stdio.h>#include <string.h>#include <math.h>#include <libavutil/opt.h>#include <libavutil/mathematics.h>#include <libavformat/avformat.h>#include <libswscale/swscale.h>#include <libswresample/swresample.h>Go to the source code of this file.
Macros | |
| #define | STREAM_DURATION 200.0 |
| #define | STREAM_FRAME_RATE 25 /* 25 images/s */ |
| #define | STREAM_NB_FRAMES ((int)(STREAM_DURATION * STREAM_FRAME_RATE)) |
| #define | STREAM_PIX_FMT AV_PIX_FMT_YUV420P /* default pix_fmt */ |
Functions | |
| static AVStream * | add_stream (AVFormatContext *oc, AVCodec **codec, enum AVCodecID codec_id) |
| static void | open_audio (AVFormatContext *oc, AVCodec *codec, AVStream *st) |
| static void | get_audio_frame (int16_t *samples, int frame_size, int nb_channels) |
| static void | write_audio_frame (AVFormatContext *oc, AVStream *st) |
| static void | close_audio (AVFormatContext *oc, AVStream *st) |
| static void | open_video (AVFormatContext *oc, AVCodec *codec, AVStream *st) |
| static void | fill_yuv_image (AVPicture *pict, int frame_index, int width, int height) |
| static void | write_video_frame (AVFormatContext *oc, AVStream *st) |
| static void | close_video (AVFormatContext *oc, AVStream *st) |
| int | main (int argc, char **argv) |
Variables | |
| static int | sws_flags = SWS_BICUBIC |
| static float | t |
| static float | tincr |
| static float | tincr2 |
| static uint8_t ** | src_samples_data |
| static int | src_samples_linesize |
| static int | src_nb_samples |
| static int | max_dst_nb_samples |
| uint8_t ** | dst_samples_data |
| int | dst_samples_linesize |
| int | dst_samples_size |
| struct SwrContext * | swr_ctx = NULL |
| static AVFrame * | frame |
| static AVPicture | src_picture |
| static AVPicture | dst_picture |
| static int | frame_count |
libavformat API example.
Output a media file in any supported libavformat format. The default codecs are used.
Definition in file muxing.c.
| #define STREAM_FRAME_RATE 25 /* 25 images/s */ |
Definition at line 45 of file muxing.c.
Referenced by add_stream().
| #define STREAM_NB_FRAMES ((int)(STREAM_DURATION * STREAM_FRAME_RATE)) |
Definition at line 46 of file muxing.c.
Referenced by write_video_frame().
| #define STREAM_PIX_FMT AV_PIX_FMT_YUV420P /* default pix_fmt */ |
Definition at line 47 of file muxing.c.
Referenced by add_stream().
|
static |
|
static |
|
static |
Definition at line 205 of file muxing.c.
Referenced by write_audio_frame().
|
static |
|
static |
|
static |
Definition at line 343 of file muxing.c.
Referenced by write_video_frame().
|
static |
|
static |
|
static |
Definition at line 49 of file muxing.c.
Referenced by write_video_frame().
|
static |
Definition at line 123 of file muxing.c.
Referenced by get_audio_frame(), and open_audio().
|
static |
Definition at line 123 of file muxing.c.
Referenced by get_audio_frame(), and open_audio().
|
static |
Definition at line 123 of file muxing.c.
Referenced by get_audio_frame(), and open_audio().
|
static |
Definition at line 125 of file muxing.c.
Referenced by close_audio(), open_audio(), and write_audio_frame().
|
static |
Definition at line 126 of file muxing.c.
Referenced by open_audio().
|
static |
Definition at line 127 of file muxing.c.
Referenced by open_audio(), and write_audio_frame().
|
static |
Definition at line 129 of file muxing.c.
Referenced by open_audio(), and write_audio_frame().
| struct SwrContext* swr_ctx = NULL |
|
static |
Definition at line 296 of file muxing.c.
Referenced by write_audio_frame().
|
static |
Definition at line 297 of file muxing.c.
Referenced by open_video().
|
static |
Definition at line 298 of file muxing.c.
Referenced by write_video_frame().
1.8.5