FFmpeg
|
sgidec.c File Reference
#include "libavutil/imgutils.h"
#include "libavutil/avassert.h"
#include "avcodec.h"
#include "bytestream.h"
#include "internal.h"
#include "sgi.h"
Include dependency graph for sgidec.c:
Go to the source code of this file.
Data Structures | |
struct | SgiState |
Typedefs | |
typedef struct SgiState | SgiState |
Functions | |
static int | expand_rle_row (SgiState *s, uint8_t *out_buf, uint8_t *out_end, int pixelstride) |
Expand an RLE row into a channel. More... | |
static int | read_rle_sgi (uint8_t *out_buf, SgiState *s) |
Read a run length encoded SGI image. More... | |
static int | read_uncompressed_sgi (unsigned char *out_buf, SgiState *s) |
Read an uncompressed SGI image. More... | |
static int | decode_frame (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt) |
Variables | |
AVCodec | ff_sgi_decoder |
Typedef Documentation
Function Documentation
|
static |
|
static |
Expand an RLE row into a channel.
- Parameters
-
s the current image state out_buf Points to one line after the output buffer. out_end end of line in output buffer pixelstride pixel stride of input buffer
- Returns
- size of output in bytes, -1 if buffer overflows
Definition at line 46 of file sgidec.c.
Referenced by read_rle_sgi().
Read a run length encoded SGI image.
- Parameters
-
out_buf output buffer s the current image state
- Returns
- 0 if no error, else return error number.
Definition at line 86 of file sgidec.c.
Referenced by decode_frame().
|
static |
Read an uncompressed SGI image.
- Parameters
-
out_buf output buffer s the current image state
- Returns
- 0 if read success, otherwise return -1.
Definition at line 120 of file sgidec.c.
Referenced by decode_frame().
Variable Documentation
AVCodec ff_sgi_decoder |
Initial value:
= {
.name = "sgi",
.type = AVMEDIA_TYPE_VIDEO,
.id = AV_CODEC_ID_SGI,
.priv_data_size = sizeof(SgiState),
.decode = decode_frame,
.long_name = NULL_IF_CONFIG_SMALL("SGI image"),
.capabilities = CODEC_CAP_DR1,
}
struct SgiState SgiState
#define CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: libavcodec/avcodec.h:743
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: libavutil/internal.h:123
static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: sgidec.c:153
Definition: avutil.h:143
static int decode(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: crystalhd.c:868
Definition: libavcodec/avcodec.h:204
Generated on Fri Dec 20 2024 06:56:15 for FFmpeg by 1.8.11