libavcodec/qtrle.c File Reference
QT RLE Video Decoder by Mike Melanson (
melanson@pcisys.net) For more information about the QT RLE format, visit:
http://www.pcisys.net/~melanson/codecs/.
More...
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include "libavutil/intreadwrite.h"
#include "avcodec.h"
Go to the source code of this file.
|
Data Structures |
struct | QtrleContext |
Defines |
#define | CHECK_STREAM_PTR(n) |
#define | CHECK_PIXEL_PTR(n) |
Functions |
static void | qtrle_decode_1bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change) |
static void | qtrle_decode_2n4bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change, int bpp) |
static void | qtrle_decode_8bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change) |
static void | qtrle_decode_16bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change) |
static void | qtrle_decode_24bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change) |
static void | qtrle_decode_32bpp (QtrleContext *s, int stream_ptr, int row_ptr, int lines_to_change) |
static av_cold int | qtrle_decode_init (AVCodecContext *avctx) |
static int | qtrle_decode_frame (AVCodecContext *avctx, void *data, int *data_size, const uint8_t *buf, int buf_size) |
static av_cold int | qtrle_decode_end (AVCodecContext *avctx) |
Variables |
AVCodec | qtrle_decoder |
Detailed Description
QT RLE Video Decoder by Mike Melanson (
melanson@pcisys.net) For more information about the QT RLE format, visit:
http://www.pcisys.net/~melanson/codecs/.
The QT RLE decoder has seven modes of operation: 1, 2, 4, 8, 16, 24, and 32 bits per pixel. For modes 1, 2, 4, and 8 the decoder outputs PAL8 colorspace data. 16-bit data yields RGB555 data. 24-bit data is RGB24 and 32-bit data is RGB32.
Definition in file qtrle.c.
Define Documentation
#define CHECK_PIXEL_PTR |
( |
n |
|
) |
|
Value:
if ((pixel_ptr + n > pixel_limit) || (pixel_ptr + n < 0)) { \
av_log (s->avctx, AV_LOG_INFO, "Problem: pixel_ptr = %d, pixel_limit = %d\n", \
pixel_ptr + n, pixel_limit); \
return; \
} \
Definition at line 59 of file qtrle.c.
#define CHECK_STREAM_PTR |
( |
n |
|
) |
|
Value:
if ((stream_ptr + n) > s->size) { \
av_log (s->avctx, AV_LOG_INFO, "Problem: stream_ptr out of bounds (%d >= %d)\n", \
stream_ptr + n, s->size); \
return; \
}
Definition at line 52 of file qtrle.c.
Function Documentation
static void qtrle_decode_16bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change | |
|
) |
| | [static] |
static void qtrle_decode_1bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change | |
|
) |
| | [static] |
static void qtrle_decode_24bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change | |
|
) |
| | [static] |
static void qtrle_decode_2n4bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change, |
|
|
int |
bpp | |
|
) |
| | [inline, static] |
static void qtrle_decode_32bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change | |
|
) |
| | [static] |
static void qtrle_decode_8bpp |
( |
QtrleContext * |
s, |
|
|
int |
stream_ptr, |
|
|
int |
row_ptr, |
|
|
int |
lines_to_change | |
|
) |
| | [static] |
static av_cold int qtrle_decode_end |
( |
AVCodecContext * |
avctx |
) |
[static] |
static int qtrle_decode_frame |
( |
AVCodecContext * |
avctx, |
|
|
void * |
data, |
|
|
int * |
data_size, |
|
|
const uint8_t * |
buf, |
|
|
int |
buf_size | |
|
) |
| | [static] |
static av_cold int qtrle_decode_init |
( |
AVCodecContext * |
avctx |
) |
[static] |
Variable Documentation
Initial value:
{
"qtrle",
CODEC_TYPE_VIDEO,
CODEC_ID_QTRLE,
sizeof(QtrleContext),
qtrle_decode_init,
NULL,
qtrle_decode_end,
qtrle_decode_frame,
CODEC_CAP_DR1,
.long_name = NULL_IF_CONFIG_SMALL("QuickTime Animation (RLE) video"),
}
Definition at line 546 of file qtrle.c.