Changeset 550 in SHVCSoftware for branches/SHM-5.0-dev/source
- Timestamp:
- 21 Jan 2014, 18:47:46 (11 years ago)
- Location:
- branches/SHM-5.0-dev/source
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/SHM-5.0-dev/source
- Property svn:mergeinfo changed
/branches/SHM-4.1-dev/source merged: 542-546 /trunk/source merged: 547 reverse-merged: 352
- Property svn:mergeinfo changed
-
branches/SHM-5.0-dev/source/App/TAppDecoder/TAppDecCfg.cpp
r540 r550 144 144 m_tgtLayerId = nLayerNum - 1; 145 145 assert( m_tgtLayerId >= 0 ); 146 #if O0137_MAX_LAYERID 147 assert( m_tgtLayerId < MAX_NUM_LAYER_IDS ); 148 #endif 146 149 #if OUTPUT_LAYER_SET_INDEX 147 150 this->getCommonDecoderParams()->setOutputLayerSetIdx( olsIdx ); -
branches/SHM-5.0-dev/source/App/TAppEncoder/TAppEncCfg.cpp
r540 r550 2579 2579 printf("ENCODER_FAST_MODE: %d ", ENCODER_FAST_MODE); 2580 2580 printf("REF_IDX_MFM: %d ", REF_IDX_MFM); 2581 #else2582 printf("RecalQP:%d", m_recalculateQPAccordingToLambda ? 1 : 0 );2583 #endif2584 2581 printf("O0194_DIFFERENT_BITDEPTH_EL_BL: %d ", O0194_DIFFERENT_BITDEPTH_EL_BL); 2585 2582 printf("O0194_JOINT_US_BITSHIFT: %d ", O0194_JOINT_US_BITSHIFT); 2586 2583 printf("O0194_WEIGHTED_PREDICTION_CGS: %d ",O0194_WEIGHTED_PREDICTION_CGS); 2584 #else 2585 printf("RecalQP:%d", m_recalculateQPAccordingToLambda ? 1 : 0 ); 2586 #endif 2587 2587 printf("\n\n"); 2588 2588 -
branches/SHM-5.0-dev/source/App/TAppEncoder/TAppEncTop.cpp
r540 r550 1171 1171 vps->setNumOutputLayerSets(vps->getNumLayerSets()); 1172 1172 vps->setNumProfileTierLevel(vps->getNumLayerSets()); 1173 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 1174 vps->setDefaultOneTargetOutputLayerIdc(1); 1175 #else 1173 1176 vps->setDefaultOneTargetOutputLayerFlag(true); 1177 #endif 1174 1178 for(i = 1; i < vps->getNumLayerSets(); i++) 1175 1179 { -
branches/SHM-5.0-dev/source/Lib/TLibCommon/TComSlice.cpp
r540 r550 2038 2038 , m_moreOutputLayerSetsThanDefaultFlag (false) 2039 2039 , m_numAddOutputLayerSets (0) 2040 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 2041 , m_defaultOneTargetOutputLayerIdc (0) 2042 #else 2040 2043 , m_defaultOneTargetOutputLayerFlag (false) 2044 #endif 2041 2045 #if VPS_VUI_BITRATE_PICRATE 2042 2046 , m_bitRatePresentVpsFlag (false) … … 2048 2052 #endif 2049 2053 #if VIEW_ID_RELATED_SIGNALING 2054 #if O0109_VIEW_ID_LEN 2055 , m_viewIdLen (0) 2056 #else 2050 2057 , m_viewIdLenMinus1 (0) 2058 #endif 2059 #endif 2060 #if VPS_VUI_OFFSET 2061 , m_vpsVuiOffset (0) 2051 2062 #endif 2052 2063 { -
branches/SHM-5.0-dev/source/Lib/TLibCommon/TComSlice.h
r540 r550 540 540 Bool m_moreOutputLayerSetsThanDefaultFlag; 541 541 Int m_numAddOutputLayerSets; 542 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 543 UInt m_defaultOneTargetOutputLayerIdc; 544 #else 542 545 Bool m_defaultOneTargetOutputLayerFlag; 546 #endif 543 547 Int m_profileLevelTierIdx[64]; 544 548 #if JCTVC_M0458_INTERLAYER_RPS_SIG … … 622 626 #endif 623 627 #if VIEW_ID_RELATED_SIGNALING 628 #if O0109_VIEW_ID_LEN 629 Int m_viewIdLen; 630 #else 624 631 Int m_viewIdLenMinus1; 632 #endif 625 633 Int m_viewIdVal [MAX_LAYERS]; 626 634 #endif … … 642 650 Int m_numSubDpbs [MAX_VPS_OP_LAYER_SETS_PLUS1]; 643 651 #endif 652 653 #if O0109_MOVE_VPS_VUI_FLAG 654 Bool m_vpsVuiPresentFlag; 655 #endif 656 644 657 #endif //SVC_EXTENSION 658 #if VPS_VUI_OFFSET 659 Int m_vpsVuiOffset; 660 #endif 645 661 public: 646 662 TComVPS(); … … 811 827 Void setNumAddOutputLayerSets(Int x) { m_numAddOutputLayerSets = x ; } 812 828 829 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 830 UInt getDefaultOneTargetOutputLayerIdc() { return m_defaultOneTargetOutputLayerIdc;} 831 Void setDefaultOneTargetOutputLayerIdc(UInt x) { m_defaultOneTargetOutputLayerIdc= x ;} 832 #else 813 833 Bool getDefaultOneTargetOutputLayerFlag() { return m_defaultOneTargetOutputLayerFlag;} 814 834 Void setDefaultOneTargetOutputLayerFlag(Bool x) { m_defaultOneTargetOutputLayerFlag= x ;} 815 835 #endif 816 836 Int getProfileLevelTierIdx(Int i) { return m_profileLevelTierIdx[i]; } 817 837 Void setProfileLevelTierIdx(Int i, Int x) { m_profileLevelTierIdx[i] = x ; } … … 946 966 #endif 947 967 #if VIEW_ID_RELATED_SIGNALING 968 #if O0109_VIEW_ID_LEN 969 Void setViewIdLen( Int val ) { m_viewIdLen = val; } 970 Int getViewIdLen( ) { return m_viewIdLen; } 971 #else 948 972 Void setViewIdLenMinus1( Int val ) { m_viewIdLenMinus1 = val; } 949 973 Int getViewIdLenMinus1( ) { return m_viewIdLenMinus1; } 974 #endif 950 975 951 976 Void setViewIdVal( Int viewOrderIndex, Int val ) { m_viewIdVal[viewOrderIndex] = val; } … … 985 1010 Int getNumSubDpbs(Int i) { return m_numSubDpbs[i]; } 986 1011 Void setNumSubDpbs(Int i, Int x) { m_numSubDpbs[i] = x; } 1012 #endif 1013 1014 #if O0109_MOVE_VPS_VUI_FLAG 1015 Bool getVpsVuiPresentFlag() { return m_vpsVuiPresentFlag; } 1016 Void setVpsVuiPresentFlag(Bool x) { m_vpsVuiPresentFlag = x; } 1017 #endif 1018 1019 #if VPS_VUI_OFFSET 1020 Int getVpsVuiOffset() { return m_vpsVuiOffset; } 1021 Void setVpsVuiOffset(Int x) { m_vpsVuiOffset = x; } 987 1022 #endif 988 1023 #endif //SVC_EXTENSION -
branches/SHM-5.0-dev/source/Lib/TLibCommon/TypeDef.h
r549 r550 43 43 #define SYNTAX_BYTES 10 ///< number of bytes taken by syntaxes per 4x4 block [RefIdxL0(1byte), RefIdxL1(1byte), MVxL0(2bytes), MVyL0(2bytes), MVxL1(2bytes), MVyL1(2bytes)] 44 44 45 #define VPS_VUI_OFFSET 1 ///< N0085: Signal VPS VUI offset in the VPS extension 46 45 47 #define RANDOM_ACCESS_SEI_FIX 1 46 48 #if SVC_EXTENSION 47 49 #define MAX_LAYERS 8 ///< max number of layers the codec is supposed to handle 50 51 #define O0137_MAX_LAYERID 1 ///< JCTVC-O0137, JCTVC-O0200, JCTVC-O0223: restrict nuh_layer_id and vps_max_layers_minus1 52 53 #define O0109_O0199_FLAGS_TO_VUI 1 ///< JCTVC-O0109, O0199: move single_layer_for_non_irap_flag and higher_layer_flag to vps_vui 54 #define O0109_VIEW_ID_LEN 1 ///< JCTVC-O0109: view_id_len_minus1 to view_id_len, and add constraint (1<<view_id_len) is greater than or equal to NumViews 55 #define O0109_PROF_REF_MINUS1 1 ///< JCTVC-O0109: constraint that profile_ref_minus1[i] shall be less than or equal to i 56 #define O0109_DEFAULT_ONE_OUT_LAYER_IDC 1 ///< JCTVC-O0109: default_one_target_output_layer_flag to default_one_target_output_layer_idc 57 #define O0109_MOVE_VPS_VUI_FLAG 1 ///< JCTVC-O0109: move vps_vui_present_flag before vps_vui_offset 58 59 #define O0135_DEFAULT_ONE_OUT_SEMANTIC 1 ///< JCTVC-O0135: semantics change of default_one_target_output_layer_idc for auxiliary pictures 48 60 49 61 #define O0194_DIFFERENT_BITDEPTH_EL_BL 1 ///< JCTVC-O0194: Support for different bitdepth values for BL and EL, add required configuration parameters (and Some bugfixes when REPN_FORMAT_IN_VPS (JCTVC-N0092) is enabled) … … 96 108 97 109 #if VPS_VUI 98 #define VPS_VUI_TILES_NOT_IN_USE__FLAG 99 #define VPS_VUI_WPP_NOT_IN_USE__FLAG 1 ///< JCTVC-O0226: VPS VUI flag to indicate tile not in use110 #define VPS_VUI_TILES_NOT_IN_USE__FLAG 1 ///< JCTVC-O0226: VPS VUI flag to indicate tile not in use 111 #define VPS_VUI_WPP_NOT_IN_USE__FLAG 1 ///< JCTVC-O0226: VPS VUI flag to indicate tile not in use 100 112 #define TILE_BOUNDARY_ALIGNED_FLAG 1 ///< JCTVC-N0160/JCTVC-N0199 proposal 2 variant 2: VPS VUI flag to indicate tile boundary alignment 101 113 #define N0160_VUI_EXT_ILP_REF 1 ///< VUI extension inter-layer dependency offset signalling … … 177 189 #define RC_SHVC_HARMONIZATION 1 ///< JCTVC-M0037: rate control for SHVC 178 190 179 #define VIEW_ID_RELATED_SIGNALING 1 ///< Introduce syntax elements view_id _len_minus1and view_id_val191 #define VIEW_ID_RELATED_SIGNALING 1 ///< Introduce syntax elements view_id and view_id_val 180 192 #define M0043_LAYERS_PRESENT_SEI 0 ///< JCTVC-M0043: add layers present SEI. Macro shall be equal to 0 according to the JCTVC-N0174 discussion. The code is to be removed. 181 193 #define N0383_IL_CONSTRAINED_TILE_SETS_SEI 1 … … 243 255 244 256 #define MAX_CPB_CNT 32 ///< Upper bound of (cpb_cnt_minus1 + 1) 257 #if O0137_MAX_LAYERID 258 #define MAX_NUM_LAYER_IDS 63 259 #else 245 260 #define MAX_NUM_LAYER_IDS 64 246 261 #endif 247 262 #define COEF_REMAIN_BIN_REDUCTION 3 ///< indicates the level at which the VLC 248 263 ///< transitions from Golomb-Rice to TU+EG(k) -
branches/SHM-5.0-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp
r540 r550 866 866 READ_CODE( 2, uiCode, "vps_reserved_three_2bits" ); assert(uiCode == 3); 867 867 #if VPS_RENAME 868 READ_CODE( 6, uiCode, "vps_max_layers_minus1" ); pcVPS->setMaxLayers( uiCode + 1); 868 #if O0137_MAX_LAYERID 869 READ_CODE( 6, uiCode, "vps_max_layers_minus1" ); pcVPS->setMaxLayers( min( 62u, uiCode) + 1 ); 870 #else 871 READ_CODE( 6, uiCode, "vps_max_layers_minus1" ); pcVPS->setMaxLayers( uiCode + 1 ); 872 #endif 869 873 #else 870 874 READ_CODE( 6, uiCode, "vps_reserved_zero_6bits" ); assert(uiCode == 0); … … 990 994 991 995 READ_FLAG( uiCode, "avc_base_layer_flag" ); vps->setAvcBaseLayerFlag(uiCode ? true : false); 996 997 #if O0109_MOVE_VPS_VUI_FLAG 998 READ_FLAG( uiCode, "vps_vui_present_flag"); vps->setVpsVuiPresentFlag(uiCode ? true : false); 999 if ( uiCode ) 1000 { 1001 #endif 1002 #if VPS_VUI_OFFSET 1003 READ_CODE( 16, uiCode, "vps_vui_offset" ); vps->setVpsVuiOffset( uiCode ); 1004 #endif 1005 #if O0109_MOVE_VPS_VUI_FLAG 1006 } 1007 #endif 992 1008 READ_FLAG( uiCode, "splitting_flag" ); vps->setSplittingFlag(uiCode ? true : false); 993 1009 … … 1048 1064 // However, this is a bug in the text since, view_id_len_minus1 is needed to parse view_id_val. 1049 1065 { 1066 #if O0109_VIEW_ID_LEN 1067 READ_CODE( 4, uiCode, "view_id_len" ); vps->setViewIdLen( uiCode ); 1068 #else 1050 1069 READ_CODE( 4, uiCode, "view_id_len_minus1" ); vps->setViewIdLenMinus1( uiCode ); 1051 } 1052 1070 #endif 1071 } 1072 1073 #if O0109_VIEW_ID_LEN 1074 if ( vps->getViewIdLen() > 0 ) 1075 { 1076 for( i = 0; i < vps->getNumViews(); i++ ) 1077 { 1078 READ_CODE( vps->getViewIdLen( ), uiCode, "view_id_val[i]" ); vps->setViewIdVal( i, uiCode ); 1079 } 1080 } 1081 #else 1053 1082 for( i = 0; i < vps->getNumViews(); i++ ) 1054 1083 { … … 1056 1085 } 1057 1086 #endif 1087 #endif // view id related signaling 1058 1088 #if VPS_EXTN_DIRECT_REF_LAYERS 1059 1089 // For layer 0 … … 1165 1195 { 1166 1196 READ_CODE( 6, uiCode, "profile_ref_minus1[i]" ); vps->setProfileLayerSetRef(idx, uiCode + 1); 1197 #if O0109_PROF_REF_MINUS1 1198 assert( vps->getProfileLayerSetRef(idx) <= idx ); 1199 #else 1167 1200 assert( vps->getProfileLayerSetRef(idx) < idx ); 1168 1201 #endif 1169 1202 // Copy profile information as indicated 1170 1203 vps->getPTLForExtn(idx)->copyProfileInfo( vps->getPTLForExtn( vps->getProfileLayerSetRef(idx) ) ); … … 1187 1220 if( numOutputLayerSets > 1 ) 1188 1221 { 1222 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 1223 READ_CODE( 2, uiCode, "default_one_target_output_layer_idc" ); vps->setDefaultOneTargetOutputLayerIdc( uiCode ); 1224 #else 1189 1225 READ_FLAG( uiCode, "default_one_target_output_layer_flag" ); vps->setDefaultOneTargetOutputLayerFlag( uiCode ? true : false ); 1226 #endif 1190 1227 } 1191 1228 vps->setNumOutputLayerSets( numOutputLayerSets ); … … 1215 1252 // Assign OutputLayerFlag depending on default_one_target_output_layer_flag 1216 1253 Int lsIdx = i; 1254 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 1255 if( vps->getDefaultOneTargetOutputLayerIdc() == 1 ) 1256 { 1257 for(j = 0; j < vps->getNumLayersInIdList(lsIdx); j++) 1258 { 1259 #if O0135_DEFAULT_ONE_OUT_SEMANTIC 1260 vps->setOutputLayerFlag(i, j, (j == (vps->getNumLayersInIdList(lsIdx)-1)) && (vps->getDimensionId(j,1)==0) ); 1261 #else 1262 vps->setOutputLayerFlag(i, j, (j == (vps->getNumLayersInIdList(lsIdx)-1))); 1263 #endif 1264 } 1265 } 1266 else if ( vps->getDefaultOneTargetOutputLayerIdc() == 0 ) 1267 { 1268 for(j = 0; j < vps->getNumLayersInIdList(lsIdx); j++) 1269 { 1270 vps->setOutputLayerFlag(i, j, 1); 1271 } 1272 } 1273 else 1274 { 1275 // Other values of default_one_target_output_layer_idc than 0 and 1 are reserved for future use. 1276 } 1277 #else 1217 1278 if( vps->getDefaultOneTargetOutputLayerFlag() ) 1218 1279 { … … 1229 1290 } 1230 1291 } 1292 #endif 1231 1293 } 1232 1294 Int numBits = 1; … … 1408 1470 #endif 1409 1471 1472 #if !O0109_O0199_FLAGS_TO_VUI 1410 1473 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 1411 1474 READ_FLAG(uiCode, "single_layer_for_non_irap_flag" ); vps->setSingleLayerForNonIrapFlag(uiCode == 1 ? true : false); … … 1414 1477 READ_FLAG(uiCode, "higher_layer_irap_skip_flag" ); vps->setHigherLayerIrapSkipFlag(uiCode == 1 ? true : false); 1415 1478 #endif 1416 1479 #endif 1480 1481 #if O0109_MOVE_VPS_VUI_FLAG 1482 if ( vps->getVpsVuiPresentFlag() ) 1483 #else 1417 1484 READ_FLAG( uiCode, "vps_vui_present_flag" ); 1418 1485 if (uiCode) 1486 #endif 1419 1487 { 1420 1488 #if VPS_VUI … … 1593 1661 } 1594 1662 #endif 1663 1664 #if O0109_O0199_FLAGS_TO_VUI 1665 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 1666 READ_FLAG(uiCode, "single_layer_for_non_irap_flag" ); vps->setSingleLayerForNonIrapFlag(uiCode == 1 ? true : false); 1667 #endif 1668 #if HIGHER_LAYER_IRAP_SKIP_FLAG 1669 READ_FLAG(uiCode, "higher_layer_irap_skip_flag" ); vps->setHigherLayerIrapSkipFlag(uiCode == 1 ? true : false); 1670 #endif 1671 #endif 1672 1595 1673 #if N0160_VUI_EXT_ILP_REF 1596 1674 READ_FLAG( uiCode, "num_ilp_restricted_ref_layers" ); vps->setNumIlpRestrictedRefLayers( uiCode == 1 ); -
branches/SHM-5.0-dev/source/Lib/TLibDecoder/TDecTop.cpp
r549 r550 1734 1734 m_cEntropyDecoder.setBitstream (nalu.m_Bitstream); 1735 1735 1736 #if O0137_MAX_LAYERID 1737 // ignore any NAL units with nuh_layer_id == 63 1738 if (nalu.m_layerId == 63 ) 1739 { 1740 return false; 1741 } 1742 #endif 1736 1743 switch (nalu.m_nalUnitType) 1737 1744 { -
branches/SHM-5.0-dev/source/Lib/TLibEncoder/TEncCavlc.cpp
r540 r550 669 669 UInt numBytesInVps = this->m_pcBitIf->getNumberOfWrittenBits(); 670 670 #endif 671 #if VPS_VUI_OFFSET 672 m_vpsVuiCounter = this->m_pcBitIf->getNumberOfWrittenBits(); 673 #endif 671 674 WRITE_CODE( pcVPS->getVPSId(), 4, "vps_video_parameter_set_id" ); 672 675 WRITE_CODE( 3, 2, "vps_reserved_three_2bits" ); … … 795 798 796 799 WRITE_FLAG( vps->getAvcBaseLayerFlag(), "avc_base_layer_flag" ); 800 #if O0109_MOVE_VPS_VUI_FLAG 801 #if !VPS_VUI 802 WRITE_FLAG( 0, "vps_vui_present_flag" ); 803 vps->setVpsVuiPresentFlag(false); 804 #else 805 WRITE_FLAG( 1, "vps_vui_present_flag" ); 806 vps->setVpsVuiPresentFlag(true); 807 #endif 808 if ( vps->getVpsVuiPresentFlag() ) 809 { 810 #if VPS_VUI_OFFSET 811 WRITE_CODE( vps->getVpsVuiOffset( ), 16, "vps_vui_offset" ); 812 #endif 813 WRITE_FLAG( vps->getSplittingFlag(), "splitting_flag" ); 814 } 815 #else 816 #if VPS_VUI_OFFSET 817 WRITE_CODE( vps->getVpsVuiOffset( ), 16, "vps_vui_offset" ); 818 #endif 797 819 WRITE_FLAG( vps->getSplittingFlag(), "splitting_flag" ); 820 #endif // O0109_MOVE_VPS_VUI_FLAG 798 821 799 822 for(i = 0; i < MAX_VPS_NUM_SCALABILITY_TYPES; i++) … … 841 864 // However, this is a bug in the text since, view_id_len_minus1 is needed to parse view_id_val. 842 865 { 866 #if O0109_VIEW_ID_LEN 867 WRITE_CODE( vps->getViewIdLen( ), 4, "view_id_len" ); 868 assert ( vps->getNumViews() >= (1<<vps->getViewIdLen()) ); 869 #else 843 870 WRITE_CODE( vps->getViewIdLenMinus1( ), 4, "view_id_len_minus1" ); 844 } 845 871 #endif 872 } 873 874 #if O0109_VIEW_ID_LEN 875 if ( vps->getViewIdLen() > 0 ) 876 { 877 #endif 846 878 for( i = 0; i < vps->getNumViews(); i++ ) 847 879 { 880 #if O0109_VIEW_ID_LEN 881 WRITE_CODE( vps->getViewIdVal( i ), vps->getViewIdLen( ), "view_id_val[i]" ); 882 #else 848 883 WRITE_CODE( vps->getViewIdVal( i ), vps->getViewIdLenMinus1( ) + 1, "view_id_val[i]" ); 849 } 850 #endif 884 #endif 885 } 886 #if O0109_VIEW_ID_LEN 887 } 888 #endif 889 #endif // VIEW_ID_RELATED_SIGNALING 890 851 891 #if VPS_EXTN_DIRECT_REF_LAYERS 852 892 for( Int layerCtr = 1; layerCtr <= vps->getMaxLayers() - 1; layerCtr++) … … 931 971 if( numOutputLayerSets > 1 ) 932 972 { 973 #if O0109_DEFAULT_ONE_OUT_LAYER_IDC 974 WRITE_CODE( vps->getDefaultOneTargetOutputLayerIdc(), 2, "default_one_target_output_layer_idc" ); 975 #else 933 976 WRITE_FLAG( vps->getDefaultOneTargetOutputLayerFlag(), "default_one_target_output_layer_flag" ); 977 #endif 934 978 } 935 979 … … 1072 1116 #endif 1073 1117 #endif 1118 1119 #if !O0109_O0199_FLAGS_TO_VUI 1074 1120 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 1075 1121 WRITE_FLAG(vps->getSingleLayerForNonIrapFlag(), "single_layer_for_non_irap_flag" ); … … 1078 1124 WRITE_FLAG(vps->getHigherLayerIrapSkipFlag(), "higher_layer_irap_skip_flag" ); 1079 1125 #endif 1080 1126 #endif 1127 1128 #if !O0109_MOVE_VPS_VUI_FLAG 1081 1129 #if !VPS_VUI 1082 1130 WRITE_FLAG( 0, "vps_vui_present_flag" ); … … 1089 1137 WRITE_FLAG(1, "vps_vui_alignment_bit_equal_to_one"); 1090 1138 } 1139 #if VPS_VUI_OFFSET 1140 Int vpsVuiOffsetValeInBits = this->m_pcBitIf->getNumberOfWrittenBits() - m_vpsVuiCounter + 16; // 2 bytes for NUH 1141 assert( vpsVuiOffsetValeInBits % 8 == 0 ); 1142 vps->setVpsVuiOffset( vpsVuiOffsetValeInBits >> 3 ); 1143 #endif 1091 1144 codeVPSVUI(vps); 1092 1145 } 1093 1146 #endif 1147 #else 1148 if(vps->getVpsVuiPresentFlag()) // Should be conditioned on the value of vps_vui_present_flag 1149 { 1150 while ( m_pcBitIf->getNumberOfWrittenBits() % 8 != 0 ) 1151 { 1152 WRITE_FLAG(1, "vps_vui_alignment_bit_equal_to_one"); 1153 } 1154 #if VPS_VUI_OFFSET 1155 Int vpsVuiOffsetValeInBits = this->m_pcBitIf->getNumberOfWrittenBits() - m_vpsVuiCounter + 16; // 2 bytes for NUH 1156 assert( vpsVuiOffsetValeInBits % 8 == 0 ); 1157 vps->setVpsVuiOffset( vpsVuiOffsetValeInBits >> 3 ); 1158 #endif 1159 codeVPSVUI(vps); 1160 } 1161 #endif // 0109_MOVE_VPS_FLAG 1094 1162 } 1095 1163 #endif … … 1225 1293 } 1226 1294 } 1295 #endif 1296 1297 #if O0109_O0199_FLAGS_TO_VUI 1298 #if M0040_ADAPTIVE_RESOLUTION_CHANGE 1299 WRITE_FLAG(vps->getSingleLayerForNonIrapFlag(), "single_layer_for_non_irap_flag" ); 1300 #endif 1301 #if HIGHER_LAYER_IRAP_SKIP_FLAG 1302 WRITE_FLAG(vps->getHigherLayerIrapSkipFlag(), "higher_layer_irap_skip_flag" ); 1303 #endif 1227 1304 #endif 1228 1305 #if N0160_VUI_EXT_ILP_REF -
branches/SHM-5.0-dev/source/Lib/TLibEncoder/TEncCavlc.h
r540 r550 68 68 TComSlice* m_pcSlice; 69 69 UInt m_uiCoeffCost; 70 70 #if VPS_VUI_OFFSET 71 Int m_vpsVuiCounter; 72 #endif 71 73 Void codeShortTermRefPicSet ( TComSPS* pcSPS, TComReferencePictureSet* pcRPS, Bool calledFromSliceHeader, Int idx ); 72 74 Bool findMatchingLTRP ( TComSlice* pcSlice, UInt *ltrpsIndex, Int ltrpPOC, Bool usedFlag ); -
branches/SHM-5.0-dev/source/Lib/TLibEncoder/TEncGOP.cpp
r549 r550 1753 1753 OutputNALUnit nalu(NAL_UNIT_VPS); 1754 1754 #endif 1755 #if VPS_VUI_OFFSET 1756 // The following code also calculates the VPS VUI offset 1757 #endif 1755 1758 #if VPS_EXTN_OFFSET_CALC 1756 1759 OutputNALUnit tempNalu(NAL_UNIT_VPS, 0, 0 ); // The value of nuh_layer_id of VPS NAL unit shall be equal to 0.
Note: See TracChangeset for help on using the changeset viewer.