00001 00002 /*! 00003 ************************************************************************** 00004 * \file elements.h 00005 * \brief Header file for elements in H.264 streams 00006 * \date 6.10.2000, 00007 * \version 00008 * 1.1 00009 * 00010 * \note 00011 * Version 1.0 included three partition modes, no DP, 2 partitionsper slice 00012 * and 4 partitions per slice. As per document VCEG-N72 this is changed 00013 * in version 1.1 to only two partition modes, one without DP and one with 00014 * 3 partition per slice 00015 * 00016 * \author Sebastian Purreiter <sebastian.purreiter@mch.siemens.de> 00017 * \author Stephan Wenger <stewe@cs.tu-berlin.de> 00018 * 00019 ************************************************************************** 00020 */ 00021 00022 #ifndef _ELEMENTS_H_ 00023 #define _ELEMENTS_H_ 00024 00025 /*! 00026 * definition of H.264 syntax elements 00027 * order of elements follow dependencies for picture reconstruction 00028 */ 00029 00030 #define MAXPARTITIONMODES 2 //!< maximum possible partition modes as defined in assignSE2partition[][] 00031 00032 /*! 00033 * \brief lookup-table to assign different elements to partition 00034 * 00035 * \note here we defined up to 6 different partitions similar to 00036 * document Q15-k-18 described in the PROGFRAMEMODE. 00037 * The Sliceheader contains the PSYNC information. \par 00038 * 00039 * Elements inside a partition are not ordered. They are 00040 * ordered by occurence in the stream. 00041 * Assumption: Only partitionlosses are considered. \par 00042 * 00043 * The texture elements luminance and chrominance are 00044 * not ordered in the progressive form 00045 * This may be changed in image.c \par 00046 * 00047 * -IMPORTANT: 00048 * Picture- or Sliceheaders must be assigned to partition 0. \par 00049 * Furthermore partitions must follow syntax dependencies as 00050 * outlined in document Q15-J-23. 00051 */ 00052 00053 00054 // A note on this table: 00055 // 00056 // While the assignment of values in enum data types is specified in C, it is not 00057 // very ood style to have an "elementnumber", not even as a comment. 00058 // 00059 // Hence a copy of the relevant structure from global.h here 00060 /* 00061 typedef enum { 00062 0 SE_HEADER, 00063 1 SE_PTYPE, 00064 2 SE_MBTYPE, 00065 3 SE_REFFRAME, 00066 4 SE_INTRAPREDMODE, 00067 5 SE_MVD, 00068 6 SE_CBP 00069 7 SE_LUM_DC_INTRA, 00070 8 SE_CHR_DC_INTRA, 00071 9 SE_LUM_AC_INTRA, 00072 10 SE_CHR_AC_INTRA, 00073 12 SE_LUM_DC_INTER, 00074 13 SE_CHR_DC_INTER, 00075 14 SE_LUM_AC_INTER, 00076 15 SE_CHR_AC_INTER, 00077 16 SE_DELTA_QUANT, 00078 18 SE_BFRAME, 00079 19 SE_EOS, 00080 20 SE_MAX_ELEMENTS */ // number of maximum syntax elements 00081 //} SE_type; 00082 00083 00084 extern const int * assignSE2partition[2]; 00085 extern const int assignSE2partition_NoDP[SE_MAX_ELEMENTS]; 00086 extern const int assignSE2partition_DP[SE_MAX_ELEMENTS]; 00087 00088 #endif 00089