FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Enumerations | Functions | Variables
vb.c File Reference

VB Video decoder. More...

#include <stdio.h>
#include <stdlib.h>
#include "avcodec.h"
#include "bytestream.h"
#include "internal.h"

Go to the source code of this file.

Data Structures

struct  VBDecContext
 

Enumerations

enum  VBFlags {
  VB_HAS_GMC = 0x01, VB_HAS_AUDIO = 0x04, VB_HAS_VIDEO = 0x08, VB_HAS_PALETTE = 0x10,
  VB_HAS_LENGTH = 0x20, VB_HAS_GMC = 0x01, VB_HAS_AUDIO = 0x04, VB_HAS_VIDEO = 0x08,
  VB_HAS_PALETTE = 0x10, VB_HAS_LENGTH = 0x20
}
 

Functions

static void vb_decode_palette (VBDecContext *c, int data_size)
 
static int check_pixel (uint8_t *buf, uint8_t *start, uint8_t *end)
 
static int check_line (uint8_t *buf, uint8_t *start, uint8_t *end)
 
static int vb_decode_framedata (VBDecContext *c, int offset)
 
static int decode_frame (AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
 
static av_cold int decode_init (AVCodecContext *avctx)
 
static av_cold int decode_end (AVCodecContext *avctx)
 

Variables

static const uint16_t vb_patterns [64]
 
AVCodec ff_vb_decoder
 

Detailed Description

VB Video decoder.

Definition in file vb.c.

Enumeration Type Documentation

enum VBFlags
Enumerator
VB_HAS_GMC 
VB_HAS_AUDIO 
VB_HAS_VIDEO 
VB_HAS_PALETTE 
VB_HAS_LENGTH 
VB_HAS_GMC 
VB_HAS_AUDIO 
VB_HAS_VIDEO 
VB_HAS_PALETTE 
VB_HAS_LENGTH 

Definition at line 34 of file vb.c.

Function Documentation

static void vb_decode_palette ( VBDecContext c,
int  data_size 
)
static

Definition at line 61 of file vb.c.

Referenced by decode_frame().

static int check_pixel ( uint8_t buf,
uint8_t start,
uint8_t end 
)
inlinestatic

Definition at line 79 of file vb.c.

Referenced by vb_decode_framedata().

static int check_line ( uint8_t buf,
uint8_t start,
uint8_t end 
)
inlinestatic

Definition at line 84 of file vb.c.

Referenced by vb_decode_framedata().

static int vb_decode_framedata ( VBDecContext c,
int  offset 
)
static

Definition at line 89 of file vb.c.

Referenced by decode_frame().

static int decode_frame ( AVCodecContext avctx,
void data,
int got_frame,
AVPacket avpkt 
)
static

Definition at line 187 of file vb.c.

static av_cold int decode_init ( AVCodecContext avctx)
static

Definition at line 248 of file vb.c.

static av_cold int decode_end ( AVCodecContext avctx)
static

Definition at line 267 of file vb.c.

Variable Documentation

const uint16_t vb_patterns[64]
static
Initial value:
= {
0x0660, 0xFF00, 0xCCCC, 0xF000, 0x8888, 0x000F, 0x1111, 0xFEC8,
0x8CEF, 0x137F, 0xF731, 0xC800, 0x008C, 0x0013, 0x3100, 0xCC00,
0x00CC, 0x0033, 0x3300, 0x0FF0, 0x6666, 0x00F0, 0x0F00, 0x2222,
0x4444, 0xF600, 0x8CC8, 0x006F, 0x1331, 0x318C, 0xC813, 0x33CC,
0x6600, 0x0CC0, 0x0066, 0x0330, 0xF900, 0xC88C, 0x009F, 0x3113,
0x6000, 0x0880, 0x0006, 0x0110, 0xCC88, 0xFC00, 0x00CF, 0x88CC,
0x003F, 0x1133, 0x3311, 0xF300, 0x6FF6, 0x0603, 0x08C6, 0x8C63,
0xC631, 0x6310, 0xC060, 0x0136, 0x136C, 0x36C8, 0x6C80, 0x324C
}

Definition at line 50 of file vb.c.

Referenced by vb_decode_framedata().

AVCodec ff_vb_decoder
Initial value:
= {
.name = "vb",
.long_name = NULL_IF_CONFIG_SMALL("Beam Software VB"),
.priv_data_size = sizeof(VBDecContext),
.close = decode_end,
.capabilities = AV_CODEC_CAP_DR1,
}
static av_cold int init(AVCodecContext *avctx)
Definition: avrndec.c:35
static av_cold int decode_end(AVCodecContext *avctx)
Definition: vb.c:267
static int decode_frame(AVCodecContext *avctx, void *data, int *got_frame, AVPacket *avpkt)
Definition: vb.c:187
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
Definition: internal.h:179
static int decode(AVCodecContext *avctx, AVFrame *frame, int *got_frame, AVPacket *pkt)
Definition: ffmpeg.c:2257
#define AV_CODEC_CAP_DR1
Codec uses get_buffer() for allocating buffers and supports custom allocators.
Definition: avcodec.h:994
static av_cold int decode_init(AVCodecContext *avctx)
Definition: vb.c:248

Definition at line 277 of file vb.c.