xref: /third_party/ffmpeg/libavcodec/h263dec.h (revision cabdff1a)
1/*
2 * H.263 decoder internal header
3 *
4 * This file is part of FFmpeg.
5 *
6 * FFmpeg is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * FFmpeg is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with FFmpeg; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 */
20#ifndef AVCODEC_H263DEC_H
21#define AVCODEC_H263DEC_H
22
23#include "mpegvideo.h"
24#include "vlc.h"
25
26// The defines below define the number of bits that are read at once for
27// reading vlc values. Changing these may improve speed and data cache needs
28// be aware though that decreasing them may need the number of stages that is
29// passed to get_vlc* to be increased.
30#define H263_MV_VLC_BITS     9
31#define INTRA_MCBPC_VLC_BITS 6
32#define INTER_MCBPC_VLC_BITS 7
33#define CBPY_VLC_BITS 6
34#define TEX_VLC_BITS 9
35
36extern VLC ff_h263_intra_MCBPC_vlc;
37extern VLC ff_h263_inter_MCBPC_vlc;
38extern VLC ff_h263_cbpy_vlc;
39extern VLC ff_h263_mv_vlc;
40
41extern const enum AVPixelFormat ff_h263_hwaccel_pixfmt_list_420[];
42
43int ff_h263_decode_motion(MpegEncContext * s, int pred, int f_code);
44int ff_h263_decode_init(AVCodecContext *avctx);
45int ff_h263_decode_frame(AVCodecContext *avctx, AVFrame *frame,
46                         int *got_frame, AVPacket *avpkt);
47int ff_h263_decode_end(AVCodecContext *avctx);
48void ff_h263_decode_init_vlc(void);
49int ff_h263_decode_picture_header(MpegEncContext *s);
50int ff_h263_decode_gob_header(MpegEncContext *s);
51int ff_h263_decode_mba(MpegEncContext *s);
52
53/**
54 * Print picture info if FF_DEBUG_PICT_INFO is set.
55 */
56void ff_h263_show_pict_info(MpegEncContext *s);
57
58int ff_intel_h263_decode_picture_header(MpegEncContext *s);
59int ff_h263_decode_mb(MpegEncContext *s,
60                      int16_t block[6][64]);
61
62int ff_h263_resync(MpegEncContext *s);
63
64#endif
65