00001 /* 00002 * This file is part of FFmpeg. 00003 * 00004 * FFmpeg is free software; you can redistribute it and/or 00005 * modify it under the terms of the GNU Lesser General Public 00006 * License as published by the Free Software Foundation; either 00007 * version 2.1 of the License, or (at your option) any later version. 00008 * 00009 * FFmpeg is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 * Lesser General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU Lesser General Public 00015 * License along with FFmpeg; if not, write to the Free Software 00016 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00017 */ 00018 00019 #ifndef AVCODEC_INTRAX8_H 00020 #define AVCODEC_INTRAX8_H 00021 00022 #include "get_bits.h" 00023 #include "mpegvideo.h" 00024 #include "intrax8dsp.h" 00025 00026 typedef struct{ 00027 VLC * j_ac_vlc[4];//they point to the static j_mb_vlc 00028 VLC * j_orient_vlc; 00029 VLC * j_dc_vlc[3]; 00030 00031 int use_quant_matrix; 00032 //set by ff_intrax8_common_init 00033 uint8_t * prediction_table;//2*(mb_w*2) 00034 ScanTable scantable[3]; 00035 //set by the caller codec 00036 MpegEncContext * s; 00037 IntraX8DSPContext dsp; 00038 int quant; 00039 int dquant; 00040 int qsum; 00041 //calculated per frame 00042 int quant_dc_chroma; 00043 int divide_quant_dc_luma; 00044 int divide_quant_dc_chroma; 00045 //changed per block 00046 int edges; 00047 int flat_dc; 00048 int predicted_dc; 00049 int raw_orient; 00050 int chroma_orient; 00051 int orient; 00052 int est_run; 00053 } IntraX8Context; 00054 00055 void ff_intrax8_common_init(IntraX8Context * w, MpegEncContext * const s); 00056 void ff_intrax8_common_end(IntraX8Context * w); 00057 int ff_intrax8_decode_picture(IntraX8Context * w, int quant, int halfpq); 00058 00059 #endif /* AVCODEC_INTRAX8_H */