#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include "libavutil/bswap.h"
#include "libavutil/lzo.h"
#include "libavutil/imgutils.h"
#include "avcodec.h"
#include "dsputil.h"
#include "rtjpeg.h"
Go to the source code of this file.
Data Structures | |
struct | NuvContext |
Functions | |
static void | copy_frame (AVFrame *f, const uint8_t *src, int width, int height) |
copy frame data from buffer to AVFrame, handling stride. | |
static int | get_quant (AVCodecContext *avctx, NuvContext *c, const uint8_t *buf, int size) |
extract quantization tables from codec data into our context | |
static void | get_quant_quality (NuvContext *c, int quality) |
set quantization tables from a quality value | |
static int | codec_reinit (AVCodecContext *avctx, int width, int height, int quality) |
static int | decode_frame (AVCodecContext *avctx, void *data, int *data_size, AVPacket *avpkt) |
static av_cold int | decode_init (AVCodecContext *avctx) |
static av_cold int | decode_end (AVCodecContext *avctx) |
Variables | |
static const uint8_t | fallback_lquant [] |
static const uint8_t | fallback_cquant [] |
AVCodec | ff_nuv_decoder |
static int codec_reinit | ( | AVCodecContext * | avctx, | |
int | width, | |||
int | height, | |||
int | quality | |||
) | [static] |
static void copy_frame | ( | AVFrame * | f, | |
const uint8_t * | src, | |||
int | width, | |||
int | height | |||
) | [static] |
static av_cold int decode_end | ( | AVCodecContext * | avctx | ) | [static] |
static int decode_frame | ( | AVCodecContext * | avctx, | |
void * | data, | |||
int * | data_size, | |||
AVPacket * | avpkt | |||
) | [static] |
static av_cold int decode_init | ( | AVCodecContext * | avctx | ) | [static] |
static int get_quant | ( | AVCodecContext * | avctx, | |
NuvContext * | c, | |||
const uint8_t * | buf, | |||
int | size | |||
) | [static] |
extract quantization tables from codec data into our context
Definition at line 83 of file nuv.c.
Referenced by decode_frame(), and decode_init().
static void get_quant_quality | ( | NuvContext * | c, | |
int | quality | |||
) | [static] |
set quantization tables from a quality value
Definition at line 100 of file nuv.c.
Referenced by codec_reinit().
const uint8_t fallback_cquant[] [static] |
Initial value:
{ 17, 18, 24, 47, 99, 99, 99, 99, 18, 21, 26, 66, 99, 99, 99, 99, 24, 26, 56, 99, 99, 99, 99, 99, 47, 66, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99 }
Definition at line 55 of file nuv.c.
Referenced by get_quant_quality().
const uint8_t fallback_lquant[] [static] |
Initial value:
{ 16, 11, 10, 16, 24, 40, 51, 61, 12, 12, 14, 19, 26, 58, 60, 55, 14, 13, 16, 24, 40, 57, 69, 56, 14, 17, 22, 29, 51, 87, 80, 62, 18, 22, 37, 56, 68, 109, 103, 77, 24, 35, 55, 64, 81, 104, 113, 92, 49, 64, 78, 87, 103, 121, 120, 101, 72, 92, 95, 98, 112, 100, 103, 99 }
Definition at line 44 of file nuv.c.
Referenced by get_quant_quality().
Initial value:
{ .name = "nuv", .type = AVMEDIA_TYPE_VIDEO, .id = CODEC_ID_NUV, .priv_data_size = sizeof(NuvContext), .init = decode_init, .close = decode_end, .decode = decode_frame, .capabilities = CODEC_CAP_DR1, .long_name = NULL_IF_CONFIG_SMALL("NuppelVideo/RTJPEG"), }