#include <stdio.h>#include <stdlib.h>#include <string.h>#include <math.h>#include <stdint.h>#include <float.h>#include <xavs.h>#include "avcodec.h"#include "internal.h"#include "libavutil/opt.h"Go to the source code of this file.
Data Structures | |
| struct | XavsContext |
Defines | |
| #define | END_OF_STREAM 0x001 |
| #define | XAVS_PART_I8X8 0x002 |
| #define | XAVS_PART_P8X8 0x010 |
| #define | XAVS_PART_B8X8 0x100 |
| #define | OFFSET(x) offsetof(XavsContext, x) |
| #define | VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM |
Functions | |
| static void | XAVS_log (void *p, int level, const char *fmt, va_list args) |
| static int | encode_nals (AVCodecContext *ctx, uint8_t *buf, int size, xavs_nal_t *nals, int nnal, int skip_sei) |
| static int | XAVS_frame (AVCodecContext *ctx, uint8_t *buf, int bufsize, void *data) |
| static av_cold int | XAVS_close (AVCodecContext *avctx) |
| static av_cold int | XAVS_init (AVCodecContext *avctx) |
Variables | |
| static const AVOption | options [] |
| class { | |
| class_name = "libxavs" | |
| item_name = av_default_item_name | |
| option = options | |
| version = LIBAVUTIL_VERSION_INT | |
| }; | |
| static const AVCodecDefault | xavs_defaults [] |
| AVCodec | ff_libxavs_encoder |
| #define END_OF_STREAM 0x001 |
| #define OFFSET | ( | x | ) | offsetof(XavsContext, x) |
| #define VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM |
| #define XAVS_PART_B8X8 0x100 |
| #define XAVS_PART_I8X8 0x002 |
| #define XAVS_PART_P8X8 0x010 |
| static int encode_nals | ( | AVCodecContext * | ctx, | |
| uint8_t * | buf, | |||
| int | size, | |||
| xavs_nal_t * | nals, | |||
| int | nnal, | |||
| int | skip_sei | |||
| ) | [static] |
| static av_cold int XAVS_close | ( | AVCodecContext * | avctx | ) | [static] |
| static int XAVS_frame | ( | AVCodecContext * | ctx, | |
| uint8_t * | buf, | |||
| int | bufsize, | |||
| void * | data | |||
| ) | [static] |
| static av_cold int XAVS_init | ( | AVCodecContext * | avctx | ) | [static] |
| static void XAVS_log | ( | void * | p, | |
| int | level, | |||
| const char * | fmt, | |||
| va_list | args | |||
| ) | [static] |
const { ... } [static] |
| class_name = "libxavs" |
Initial value:
{
.name = "libxavs",
.type = AVMEDIA_TYPE_VIDEO,
.id = CODEC_ID_CAVS,
.priv_data_size = sizeof(XavsContext),
.init = XAVS_init,
.encode = XAVS_frame,
.close = XAVS_close,
.capabilities = CODEC_CAP_DELAY | CODEC_CAP_AUTO_THREADS,
.pix_fmts = (const enum PixelFormat[]) { PIX_FMT_YUV420P, PIX_FMT_NONE },
.long_name = NULL_IF_CONFIG_SMALL("libxavs - the Chinese Audio Video Standard Encoder"),
.priv_class = &class,
.defaults = xavs_defaults,
}
Initial value:
{
{ "crf", "Select the quality for constant quality mode", OFFSET(crf), AV_OPT_TYPE_FLOAT, {-1 }, -1, FLT_MAX, VE },
{ "qp", "Constant quantization parameter rate control method",OFFSET(cqp), AV_OPT_TYPE_INT, {-1 }, -1, INT_MAX, VE },
{ "b-bias", "Influences how often B-frames are used", OFFSET(b_bias), AV_OPT_TYPE_INT, {INT_MIN}, INT_MIN, INT_MAX, VE },
{ "cplxblur", "Reduce fluctuations in QP (before curve compression)", OFFSET(cplxblur), AV_OPT_TYPE_FLOAT, {-1 }, -1, FLT_MAX, VE},
{ "direct-pred", "Direct MV prediction mode", OFFSET(direct_pred), AV_OPT_TYPE_INT, {-1 }, -1, INT_MAX, VE, "direct-pred" },
{ "none", NULL, 0, AV_OPT_TYPE_CONST, { XAVS_DIRECT_PRED_NONE }, 0, 0, VE, "direct-pred" },
{ "spatial", NULL, 0, AV_OPT_TYPE_CONST, { XAVS_DIRECT_PRED_SPATIAL }, 0, 0, VE, "direct-pred" },
{ "temporal", NULL, 0, AV_OPT_TYPE_CONST, { XAVS_DIRECT_PRED_TEMPORAL }, 0, 0, VE, "direct-pred" },
{ "auto", NULL, 0, AV_OPT_TYPE_CONST, { XAVS_DIRECT_PRED_AUTO }, 0, 0, VE, "direct-pred" },
{ "aud", "Use access unit delimiters.", OFFSET(aud), AV_OPT_TYPE_INT, {-1 }, -1, 1, VE},
{ "mbtree", "Use macroblock tree ratecontrol.", OFFSET(mbtree), AV_OPT_TYPE_INT, {-1 }, -1, 1, VE},
{ "mixed-refs", "One reference per partition, as opposed to one reference per macroblock", OFFSET(mixed_refs), AV_OPT_TYPE_INT, {-1}, -1, 1, VE },
{ "fast-pskip", NULL, OFFSET(fast_pskip), AV_OPT_TYPE_INT, {-1 }, -1, 1, VE},
{ NULL },
}
const AVCodecDefault xavs_defaults[] [static] |
1.5.8