00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _CABAC_H_
00021 #define _CABAC_H_
00022
00023 extern const byte maxpos [];
00024 extern const byte c1isdc [];
00025 extern const byte type2ctx_bcbp[];
00026 extern const byte type2ctx_map [];
00027 extern const byte type2ctx_last[];
00028 extern const byte type2ctx_one [];
00029 extern const byte type2ctx_abs [];
00030 extern const byte max_c2 [];
00031
00032 extern const byte pos2ctx_map8x8 [];
00033 extern const byte pos2ctx_map8x4 [];
00034 extern const byte pos2ctx_map4x4 [];
00035 extern const byte pos2ctx_map2x4c [];
00036 extern const byte pos2ctx_map4x4c [];
00037 extern const byte* pos2ctx_map [];
00038 extern const byte pos2ctx_map8x8i [];
00039 extern const byte pos2ctx_map8x4i [];
00040 extern const byte pos2ctx_map4x8i [];
00041 extern const byte* pos2ctx_map_int [];
00042 extern const byte pos2ctx_last8x8 [];
00043 extern const byte pos2ctx_last8x4 [];
00044 extern const byte pos2ctx_last4x4 [];
00045 extern const byte pos2ctx_last2x4c[];
00046 extern const byte pos2ctx_last4x4c[];
00047 extern const byte* pos2ctx_last [];
00048
00049
00050 MotionInfoContexts* create_contexts_MotionInfo(void);
00051 TextureInfoContexts* create_contexts_TextureInfo(void);
00052 void delete_contexts_MotionInfo(MotionInfoContexts *enco_ctx);
00053 void delete_contexts_TextureInfo(TextureInfoContexts *enco_ctx);
00054 void writeHeaderToBuffer(void);
00055 void writeMB_typeInfo_CABAC(SyntaxElement *se, DataPartition *dp);
00056 void writeIntraPredMode_CABAC(SyntaxElement *se, DataPartition *dp);
00057 void writeB8_typeInfo_CABAC(SyntaxElement *se, DataPartition *dp);
00058 void writeRefFrame_CABAC(SyntaxElement *se, DataPartition *dp);
00059 void writeMVD_CABAC(SyntaxElement *se, DataPartition *dp);
00060 void writeCBP_CABAC(Macroblock *currMB, SyntaxElement *se, DataPartition *dp);
00061 void writeDquant_CABAC(SyntaxElement *se, DataPartition *dp);
00062 void writeRunLevel_CABAC(Macroblock* currMB, SyntaxElement *se, DataPartition *dp);
00063 void writeCIPredMode_CABAC(SyntaxElement *se, DataPartition *dp);
00064 void print_ctx_TextureInfo(TextureInfoContexts *enco_ctx);
00065 void writeMB_skip_flagInfo_CABAC(Macroblock *currMB, SyntaxElement *se, DataPartition *dp);
00066 void writeFieldModeInfo_CABAC(SyntaxElement *se, DataPartition *dp);
00067 void writeCBP_BIT_CABAC (Macroblock* currMB, int b8, int bit, int cbp, int inter, EncodingEnvironmentPtr eep_dp, TextureInfoContexts *ctx);
00068 void cabac_new_slice(void);
00069 void CheckAvailabilityOfNeighborsCABAC(Macroblock* currMB);
00070
00071 void writeMB_transform_size_CABAC(SyntaxElement *se, DataPartition *dp);
00072
00073
00074 #endif // CABAC_H
00075