FFmpeg
roqvideo.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2003 Mike Melanson
3  * Copyright (C) 2003 Dr. Tim Ferguson
4  *
5  * This file is part of FFmpeg.
6  *
7  * FFmpeg is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU Lesser General Public
9  * License as published by the Free Software Foundation; either
10  * version 2.1 of the License, or (at your option) any later version.
11  *
12  * FFmpeg is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * Lesser General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with FFmpeg; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 
22 #ifndef AVCODEC_ROQVIDEO_H
23 #define AVCODEC_ROQVIDEO_H
24 
25 #include "libavutil/frame.h"
26 
27 typedef struct roq_cell {
28  unsigned char y[4];
29  unsigned char u, v;
30 } roq_cell;
31 
32 typedef struct roq_qcell {
33  int idx[4];
34 } roq_qcell;
35 
36 typedef struct motion_vect {
37  int d[2];
38 } motion_vect;
39 
40 typedef struct RoqContext {
41  const AVClass *class;
42  void *logctx;
45  int width, height;
46 
49 } RoqContext;
50 
51 #define RoQ_INFO 0x1001
52 #define RoQ_QUAD_CODEBOOK 0x1002
53 #define RoQ_QUAD_VQ 0x1011
54 #define RoQ_SOUND_MONO 0x1020
55 #define RoQ_SOUND_STEREO 0x1021
56 
57 #define RoQ_ID_MOT 0x00
58 #define RoQ_ID_FCC 0x01
59 #define RoQ_ID_SLD 0x02
60 #define RoQ_ID_CCC 0x03
61 
62 void ff_apply_vector_2x2(RoqContext *ri, int x, int y, roq_cell *cell);
63 void ff_apply_vector_4x4(RoqContext *ri, int x, int y, roq_cell *cell);
64 
65 void ff_apply_motion_4x4(RoqContext *ri, int x, int y, int deltax, int deltay);
66 
67 void ff_apply_motion_8x8(RoqContext *ri, int x, int y, int deltax, int deltay);
68 
69 #endif /* AVCODEC_ROQVIDEO_H */
RoqContext::cb4x4
roq_qcell cb4x4[256]
Definition: roqvideo.h:48
RoqContext::current_frame
AVFrame * current_frame
Definition: roqvideo.h:44
ff_apply_motion_8x8
void ff_apply_motion_8x8(RoqContext *ri, int x, int y, int deltax, int deltay)
Definition: roqvideo.c:140
AVFrame
This structure describes decoded (raw) audio or video data.
Definition: frame.h:344
RoqContext
Definition: roqvideo.h:40
roq_cell::y
unsigned char y[4]
Definition: roqvideo.h:28
roq_cell
Definition: roqvideo.h:27
RoqContext::height
int height
Definition: roqvideo.h:45
motion_vect
Definition: roqvideo.h:36
ff_apply_vector_2x2
void ff_apply_vector_2x2(RoqContext *ri, int x, int y, roq_cell *cell)
Definition: roqvideo.c:42
roq_cell::v
unsigned char v
Definition: roqvideo.h:29
AVClass
Describe the class of an AVClass context structure.
Definition: log.h:66
roq_qcell
Definition: roqvideo.h:32
frame.h
ff_apply_vector_4x4
void ff_apply_vector_4x4(RoqContext *ri, int x, int y, roq_cell *cell)
Definition: roqvideo.c:72
roq_qcell::idx
int idx[4]
Definition: roqvideo.h:33
RoqContext::last_frame
AVFrame * last_frame
Definition: roqvideo.h:43
motion_vect::d
int d[2]
Definition: roqvideo.h:37
roq_cell::u
unsigned char u
Definition: roqvideo.h:29
RoqContext::logctx
void * logctx
Definition: roqvideo.h:42
RoqContext::width
int width
Definition: roqvideo.h:45
ff_apply_motion_4x4
void ff_apply_motion_4x4(RoqContext *ri, int x, int y, int deltax, int deltay)
Definition: roqvideo.c:134
RoqContext::cb2x2
roq_cell cb2x2[256]
Definition: roqvideo.h:47