Changeset 1413 in 3DVCSoftware for trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp
- Timestamp:
- 11 Jul 2018, 15:19:49 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp
r1405 r1413 4 4 * granted under this license. 5 5 * 6 * Copyright (c) 2010-201 6, ITU/ISO/IEC6 * Copyright (c) 2010-2017, ITU/ISO/IEC 7 7 * All rights reserved. 8 8 * … … 43 43 #include "TLibCommon/TComCodingStatistics.h" 44 44 #endif 45 #include "TDecConformance.h" 46 45 47 #if NH_MV 46 48 #include "TDecTop.h" … … 244 246 Int iCode; 245 247 246 READ_UVLC ( uiCode, "pps_pic_parameter_set_id");248 READ_UVLC_CHK( uiCode, "pps_pic_parameter_set_id", 0, 63); 247 249 assert(uiCode <= 63); 248 250 pcPPS->setPPSId (uiCode); 249 251 250 READ_UVLC ( uiCode, "pps_seq_parameter_set_id");252 READ_UVLC_CHK( uiCode, "pps_seq_parameter_set_id", 0, 15); 251 253 assert(uiCode <= 15); 252 254 pcPPS->setSPSId (uiCode); … … 258 260 READ_CODE(3, uiCode, "num_extra_slice_header_bits"); pcPPS->setNumExtraSliceHeaderBits(uiCode); 259 261 260 READ_FLAG ( uiCode, "sign_data_hiding_ flag" ); pcPPS->setSignHideFlag( uiCode );262 READ_FLAG ( uiCode, "sign_data_hiding_enabled_flag" ); pcPPS->setSignDataHidingEnabledFlag( uiCode ); 261 263 262 264 READ_FLAG( uiCode, "cabac_init_present_flag" ); pcPPS->setCabacInitPresentFlag( uiCode ? true : false ); 263 265 264 READ_UVLC (uiCode, "num_ref_idx_l0_default_active_minus1");266 READ_UVLC_CHK(uiCode, "num_ref_idx_l0_default_active_minus1", 0, 14); 265 267 assert(uiCode <= 14); 266 268 pcPPS->setNumRefIdxL0DefaultActive(uiCode+1); 267 269 268 READ_UVLC (uiCode, "num_ref_idx_l1_default_active_minus1");270 READ_UVLC_CHK(uiCode, "num_ref_idx_l1_default_active_minus1", 0, 14); 269 271 assert(uiCode <= 14); 270 272 pcPPS->setNumRefIdxL1DefaultActive(uiCode+1); 271 273 272 READ_SVLC (iCode, "init_qp_minus26" );pcPPS->setPicInitQPMinus26(iCode);274 READ_SVLC_CHK(iCode, "init_qp_minus26", std::numeric_limits<Int>::min(), 25 ); pcPPS->setPicInitQPMinus26(iCode); 273 275 READ_FLAG( uiCode, "constrained_intra_pred_flag" ); pcPPS->setConstrainedIntraPred( uiCode ? true : false ); 274 276 READ_FLAG( uiCode, "transform_skip_enabled_flag" ); … … 285 287 pcPPS->setMaxCuDQPDepth( 0 ); 286 288 } 287 READ_SVLC ( iCode, "pps_cb_qp_offset");289 READ_SVLC_CHK( iCode, "pps_cb_qp_offset", -12, 12); 288 290 pcPPS->setQpOffset(COMPONENT_Cb, iCode); 289 291 assert( pcPPS->getQpOffset(COMPONENT_Cb) >= -12 ); 290 292 assert( pcPPS->getQpOffset(COMPONENT_Cb) <= 12 ); 291 293 292 READ_SVLC ( iCode, "pps_cr_qp_offset");294 READ_SVLC_CHK( iCode, "pps_cr_qp_offset", -12, 12); 293 295 pcPPS->setQpOffset(COMPONENT_Cr, iCode); 294 296 assert( pcPPS->getQpOffset(COMPONENT_Cr) >= -12 ); … … 305 307 pcPPS->setWPBiPred( uiCode==1 ); 306 308 307 READ_FLAG( uiCode, "transquant_bypass_enable _flag");308 pcPPS->setTransquantBypassEnable Flag(uiCode ? true : false);309 READ_FLAG( uiCode, "transquant_bypass_enabled_flag"); 310 pcPPS->setTransquantBypassEnabledFlag(uiCode ? true : false); 309 311 READ_FLAG( uiCode, "tiles_enabled_flag" ); pcPPS->setTilesEnabledFlag ( uiCode == 1 ); 310 312 READ_FLAG( uiCode, "entropy_coding_sync_enabled_flag" ); pcPPS->setEntropyCodingSyncEnabledFlag( uiCode == 1 ); … … 344 346 } 345 347 346 if ((tileColumnsMinus1 + tileRowsMinus1) != 0) 347 { 348 assert ((tileColumnsMinus1 + tileRowsMinus1) != 0); 348 349 READ_FLAG ( uiCode, "loop_filter_across_tiles_enabled_flag" ); pcPPS->setLoopFilterAcrossTilesEnabledFlag( uiCode ? true : false ); 349 350 } 350 }351 351 READ_FLAG( uiCode, "pps_loop_filter_across_slices_enabled_flag" ); pcPPS->setLoopFilterAcrossSlicesEnabledFlag( uiCode ? true : false ); 352 352 READ_FLAG( uiCode, "deblocking_filter_control_present_flag" ); pcPPS->setDeblockingFilterControlPresentFlag( uiCode ? true : false ); … … 354 354 { 355 355 READ_FLAG( uiCode, "deblocking_filter_override_enabled_flag" ); pcPPS->setDeblockingFilterOverrideEnabledFlag( uiCode ? true : false ); 356 READ_FLAG( uiCode, "pps_d isable_deblocking_filter_flag" ); pcPPS->setPicDisableDeblockingFilterFlag(uiCode ? true : false );357 if(!pcPPS->getP icDisableDeblockingFilterFlag())356 READ_FLAG( uiCode, "pps_deblocking_filter_disabled_flag" ); pcPPS->setPPSDeblockingFilterDisabledFlag(uiCode ? true : false ); 357 if(!pcPPS->getPPSDeblockingFilterDisabledFlag()) 358 358 { 359 359 READ_SVLC ( iCode, "pps_beta_offset_div2" ); pcPPS->setDeblockingFilterBetaOffsetDiv2( iCode ); … … 502 502 READ_UVLC(uiCode, "diff_cu_chroma_qp_offset_depth"); ppsRangeExtension.setDiffCuChromaQpOffsetDepth(uiCode); 503 503 UInt tableSizeMinus1 = 0; 504 READ_UVLC(tableSizeMinus1, "chroma_qp_offset_list_len_minus1");504 READ_UVLC_CHK(tableSizeMinus1, "chroma_qp_offset_list_len_minus1", 0, MAX_QP_OFFSET_LIST_SIZE-1); 505 505 assert(tableSizeMinus1 < MAX_QP_OFFSET_LIST_SIZE); 506 506 … … 509 509 Int cbOffset; 510 510 Int crOffset; 511 READ_SVLC(cbOffset, "cb_qp_offset_list[i]");511 READ_SVLC_CHK(cbOffset, "cb_qp_offset_list[i]", -12, 12); 512 512 assert(cbOffset >= -12 && cbOffset <= 12); 513 READ_SVLC(crOffset, "cr_qp_offset_list[i]");513 READ_SVLC_CHK(crOffset, "cr_qp_offset_list[i]", -12, 12); 514 514 assert(crOffset >= -12 && crOffset <= 12); 515 515 // table uses +1 for index (see comment inside the function) … … 546 546 Void TDecCavlc::parsePps3dExtension( TComPPS* pcPPS ) 547 547 { 548 #if NH_3D_DLT549 548 UInt uiCode = 0; 550 549 // … … 679 678 } 680 679 } 681 #endif 680 682 681 } 683 682 #endif … … 885 884 { 886 885 #endif 887 READ_CODE ( 3, uiCode, "sps_max_sub_layers_minus1" );pcSPS->setMaxTLayers ( uiCode+1 );886 READ_CODE_CHK( 3, uiCode, "sps_max_sub_layers_minus1", 0, 6 ); pcSPS->setMaxTLayers ( uiCode+1 ); 888 887 assert(uiCode <= 6); 889 888 #if NH_MV … … 902 901 { 903 902 // sps_temporal_id_nesting_flag must be 1 when sps_max_sub_layers_minus1 is 0 903 TDecConformanceCheck::checkRange(uiCode, "sps_temporal_id_nesting_flag", 1U, 1U); 904 904 assert( uiCode == 1 ); 905 905 } … … 911 911 } 912 912 #endif 913 READ_UVLC ( uiCode, "sps_seq_parameter_set_id"); pcSPS->setSPSId( uiCode );913 READ_UVLC_CHK( uiCode, "sps_seq_parameter_set_id", 0, 15 ); pcSPS->setSPSId( uiCode ); 914 914 assert(uiCode <= 15); 915 915 #if NH_MV … … 926 926 #endif 927 927 928 READ_UVLC ( uiCode, "chroma_format_idc" );pcSPS->setChromaFormatIdc( ChromaFormat(uiCode) );928 READ_UVLC_CHK( uiCode, "chroma_format_idc", 0, 3 ); pcSPS->setChromaFormatIdc( ChromaFormat(uiCode) ); 929 929 assert(uiCode <= 3); 930 930 if( pcSPS->getChromaFormatIdc() == CHROMA_444 ) 931 931 { 932 READ_FLAG( uiCode, "separate_colour_plane_flag"); assert(uiCode == 0); 933 } 934 935 READ_UVLC ( uiCode, "pic_width_in_luma_samples" ); pcSPS->setPicWidthInLumaSamples ( uiCode ); 936 READ_UVLC ( uiCode, "pic_height_in_luma_samples" ); pcSPS->setPicHeightInLumaSamples( uiCode ); 932 READ_FLAG_CHK( uiCode, "separate_colour_plane_flag", 0, 0); 933 assert(uiCode == 0); 934 } 935 936 // pic_width_in_luma_samples and pic_height_in_luma_samples needs conformance checking - multiples of MinCbSizeY 937 READ_UVLC_CHK ( uiCode, "pic_width_in_luma_samples", 1, std::numeric_limits<UInt>::max() ); pcSPS->setPicWidthInLumaSamples ( uiCode ); 938 READ_UVLC_CHK ( uiCode, "pic_height_in_luma_samples", 1, std::numeric_limits<UInt>::max() ); pcSPS->setPicHeightInLumaSamples( uiCode ); 937 939 READ_FLAG( uiCode, "conformance_window_flag"); 938 940 if (uiCode != 0) … … 948 950 } 949 951 #else 950 READ_UVLC( uiCode, "conf_win_left_offset" ); conf.setWindowLeftOffset ( uiCode * TComSPS::getWinUnitX( pcSPS->getChromaFormatIdc() ) ); 951 READ_UVLC( uiCode, "conf_win_right_offset" ); conf.setWindowRightOffset ( uiCode * TComSPS::getWinUnitX( pcSPS->getChromaFormatIdc() ) ); 952 READ_UVLC( uiCode, "conf_win_top_offset" ); conf.setWindowTopOffset ( uiCode * TComSPS::getWinUnitY( pcSPS->getChromaFormatIdc() ) ); 953 READ_UVLC( uiCode, "conf_win_bottom_offset" ); conf.setWindowBottomOffset( uiCode * TComSPS::getWinUnitY( pcSPS->getChromaFormatIdc() ) ); 952 const UInt subWidthC = TComSPS::getWinUnitX( pcSPS->getChromaFormatIdc() ); 953 const UInt subHeightC = TComSPS::getWinUnitY( pcSPS->getChromaFormatIdc() ); 954 READ_UVLC( uiCode, "conf_win_left_offset" ); conf.setWindowLeftOffset ( uiCode * subWidthC ); 955 READ_UVLC( uiCode, "conf_win_right_offset" ); conf.setWindowRightOffset ( uiCode * subWidthC ); 956 READ_UVLC( uiCode, "conf_win_top_offset" ); conf.setWindowTopOffset ( uiCode * subHeightC ); 957 READ_UVLC( uiCode, "conf_win_bottom_offset" ); conf.setWindowBottomOffset( uiCode * subHeightC ); 958 TDecConformanceCheck::checkRange<UInt>(conf.getWindowLeftOffset()+conf.getWindowRightOffset(), "conformance window width in pixels", 0, pcSPS->getPicWidthInLumaSamples()-1); 954 959 #endif 955 960 } … … 960 965 #endif 961 966 962 READ_UVLC( uiCode, "bit_depth_luma_minus8" ); 967 READ_UVLC_CHK( uiCode, "bit_depth_luma_minus8", 0, 8 ); 968 assert(uiCode <= 8); 963 969 #if O0043_BEST_EFFORT_DECODING 964 970 pcSPS->setStreamBitDepth(CHANNEL_TYPE_LUMA, 8 + uiCode); … … 968 974 uiCode = forceDecodeBitDepth - 8; 969 975 } 970 #endif971 976 assert(uiCode <= 8); 977 #endif 972 978 pcSPS->setBitDepth(CHANNEL_TYPE_LUMA, 8 + uiCode); 973 979 … … 978 984 #endif 979 985 980 READ_UVLC( uiCode, "bit_depth_chroma_minus8" ); 986 READ_UVLC_CHK( uiCode, "bit_depth_chroma_minus8", 0, 8 ); 987 assert(uiCode <= 8); 981 988 #if O0043_BEST_EFFORT_DECODING 982 989 pcSPS->setStreamBitDepth(CHANNEL_TYPE_CHROMA, 8 + uiCode); … … 985 992 uiCode = forceDecodeBitDepth - 8; 986 993 } 987 #endif988 994 assert(uiCode <= 8); 995 #endif 989 996 pcSPS->setBitDepth(CHANNEL_TYPE_CHROMA, 8 + uiCode); 990 997 #if O0043_BEST_EFFORT_DECODING … … 997 1004 #endif 998 1005 999 READ_UVLC( uiCode, "log2_max_pic_order_cnt_lsb_minus4" ); pcSPS->setBitsForPOC( 4 + uiCode ); 1000 assert(uiCode <= 12); 1006 READ_UVLC_CHK( uiCode, "log2_max_pic_order_cnt_lsb_minus4", 0, 12 ); pcSPS->setBitsForPOC( 4 + uiCode ); 1001 1007 1002 1008 #if NH_MV … … 1039 1045 #endif 1040 1046 1041 READ_UVLC( uiCode, "log2_min_luma_coding_block_size_minus3" ); 1042 Int log2MinCUSize = uiCode + 3; 1043 pcSPS->setLog2MinCodingBlockSize(log2MinCUSize); 1044 READ_UVLC( uiCode, "log2_diff_max_min_luma_coding_block_size" ); 1047 const UInt maxLog2CtbSize = TDecConformanceCheck::getMaxLog2CtbSize(*(pcSPS->getPTL())); 1048 const UInt minLog2CtbSize = TDecConformanceCheck::getMinLog2CtbSize(*(pcSPS->getPTL())); 1049 READ_UVLC_CHK( uiCode, "log2_min_luma_coding_block_size_minus3", 0, maxLog2CtbSize-3 ); 1050 assert(uiCode <= maxLog2CtbSize-3); 1051 Int minCbLog2SizeY = uiCode + 3; 1052 pcSPS->setLog2MinCodingBlockSize(minCbLog2SizeY); 1053 1054 // Difference + log2MinCUSize must be <= maxLog2CtbSize 1055 // Difference + log2MinCUSize must be >= minLog2CtbSize 1056 const UInt minLog2DiffMaxMinLumaCodingBlockSize = minLog2CtbSize < minCbLog2SizeY ? 0 : minLog2CtbSize - minCbLog2SizeY; 1057 const UInt maxLog2DiffMaxMinLumaCodingBlockSize = maxLog2CtbSize - minCbLog2SizeY; 1058 1059 READ_UVLC_CHK( uiCode, "log2_diff_max_min_luma_coding_block_size", minLog2DiffMaxMinLumaCodingBlockSize, maxLog2DiffMaxMinLumaCodingBlockSize); 1060 assert(uiCode >= minLog2DiffMaxMinLumaCodingBlockSize && uiCode <= maxLog2DiffMaxMinLumaCodingBlockSize); 1045 1061 pcSPS->setLog2DiffMaxMinCodingBlockSize(uiCode); 1046 1047 if (pcSPS->getPTL()->getGeneralPTL()->getLevelIdc() >= Level::LEVEL5)1048 {1049 assert(log2MinCUSize + pcSPS->getLog2DiffMaxMinCodingBlockSize() >= 5);1050 }1051 1052 Int maxCUDepthDelta = uiCode;1053 pcSPS->set MaxCUWidth ( 1<<(log2MinCUSize + maxCUDepthDelta));1054 pcSPS->setMaxCUHeight ( 1<<(log2MinCUSize + maxCUDepthDelta) ); 1055 READ_UVLC( uiCode, "log2_min_luma_transform_block_size_minus2" ); pcSPS->setQuadtreeTULog2MinSize( uiCode + 2 );1056 1057 READ_UVLC( uiCode, "log2_diff_max_min_luma_transform_block_size" );pcSPS->setQuadtreeTULog2MaxSize( uiCode + pcSPS->getQuadtreeTULog2MinSize() );1062 1063 const Int maxCUDepthDelta = uiCode; 1064 const Int ctbLog2SizeY = minCbLog2SizeY + maxCUDepthDelta; 1065 pcSPS->setMaxCUWidth ( 1<<ctbLog2SizeY ); 1066 pcSPS->setMaxCUHeight ( 1<<ctbLog2SizeY ); 1067 READ_UVLC_CHK( uiCode, "log2_min_luma_transform_block_size_minus2", 0, minCbLog2SizeY-1-2 ); 1068 const UInt minTbLog2SizeY = uiCode + 2; 1069 pcSPS->setQuadtreeTULog2MinSize( minTbLog2SizeY ); 1070 1071 // log2_diff <= Min(CtbLog2SizeY, 5) - minTbLog2SizeY 1072 READ_UVLC_CHK( uiCode, "log2_diff_max_min_luma_transform_block_size", 0, min<UInt>(5U, ctbLog2SizeY) - minTbLog2SizeY ); 1073 pcSPS->setQuadtreeTULog2MaxSize( uiCode + pcSPS->getQuadtreeTULog2MinSize() ); 1058 1074 pcSPS->setMaxTrSize( 1<<(uiCode + pcSPS->getQuadtreeTULog2MinSize()) ); 1059 1075 1060 READ_UVLC ( uiCode, "max_transform_hierarchy_depth_inter"); pcSPS->setQuadtreeTUMaxDepthInter( uiCode+1 );1061 READ_UVLC ( uiCode, "max_transform_hierarchy_depth_intra"); pcSPS->setQuadtreeTUMaxDepthIntra( uiCode+1 );1062 1063 Int addCuDepth = max (0, log2MinCUSize- (Int)pcSPS->getQuadtreeTULog2MinSize() );1076 READ_UVLC_CHK( uiCode, "max_transform_hierarchy_depth_inter", 0, ctbLog2SizeY - minTbLog2SizeY); pcSPS->setQuadtreeTUMaxDepthInter( uiCode+1 ); 1077 READ_UVLC_CHK( uiCode, "max_transform_hierarchy_depth_intra", 0, ctbLog2SizeY - minTbLog2SizeY); pcSPS->setQuadtreeTUMaxDepthIntra( uiCode+1 ); 1078 1079 Int addCuDepth = max (0, minCbLog2SizeY - (Int)pcSPS->getQuadtreeTULog2MinSize() ); 1064 1080 pcSPS->setMaxTotalCUDepth( maxCUDepthDelta + addCuDepth + getMaxCUDepthOffset(pcSPS->getChromaFormatIdc(), pcSPS->getQuadtreeTULog2MinSize()) ); 1065 1081 … … 1095 1111 if( pcSPS->getUsePCM() ) 1096 1112 { 1097 READ_CODE( 4, uiCode, "pcm_sample_bit_depth_luma_minus1" ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_LUMA, 1 + uiCode ); 1098 READ_CODE( 4, uiCode, "pcm_sample_bit_depth_chroma_minus1" ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_CHROMA, 1 + uiCode ); 1099 READ_UVLC( uiCode, "log2_min_pcm_luma_coding_block_size_minus3" ); pcSPS->setPCMLog2MinSize (uiCode+3); 1100 READ_UVLC( uiCode, "log2_diff_max_min_pcm_luma_coding_block_size" ); pcSPS->setPCMLog2MaxSize ( uiCode+pcSPS->getPCMLog2MinSize() ); 1113 #if O0043_BEST_EFFORT_DECODING 1114 READ_CODE_CHK( 4, uiCode, "pcm_sample_bit_depth_luma_minus1", 0, pcSPS->getStreamBitDepth(CHANNEL_TYPE_LUMA) ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_LUMA, 1 + uiCode ); 1115 READ_CODE_CHK( 4, uiCode, "pcm_sample_bit_depth_chroma_minus1", 0, pcSPS->getStreamBitDepth(CHANNEL_TYPE_LUMA) ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_CHROMA, 1 + uiCode ); 1116 #else 1117 READ_CODE_CHK( 4, uiCode, "pcm_sample_bit_depth_luma_minus1", 0, pcSPS->getBitDepth(CHANNEL_TYPE_LUMA) ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_LUMA, 1 + uiCode ); 1118 READ_CODE_CHK( 4, uiCode, "pcm_sample_bit_depth_chroma_minus1", 0, pcSPS->getBitDepth(CHANNEL_TYPE_CHROMA) ); pcSPS->setPCMBitDepth ( CHANNEL_TYPE_CHROMA, 1 + uiCode ); 1119 #endif 1120 READ_UVLC_CHK( uiCode, "log2_min_pcm_luma_coding_block_size_minus3", std::min<UInt>(minCbLog2SizeY, 5 )-3, std::min<UInt>(ctbLog2SizeY, 5)-3); 1121 const UInt log2MinIpcmCbSizeY = uiCode+3; 1122 pcSPS->setPCMLog2MinSize (log2MinIpcmCbSizeY); 1123 READ_UVLC_CHK( uiCode, "log2_diff_max_min_pcm_luma_coding_block_size", 0, (std::min<UInt>(ctbLog2SizeY,5) - log2MinIpcmCbSizeY) ); 1124 pcSPS->setPCMLog2MaxSize ( uiCode+pcSPS->getPCMLog2MinSize() ); 1101 1125 READ_FLAG( uiCode, "pcm_loop_filter_disable_flag" ); pcSPS->setPCMFilterDisableFlag ( uiCode ? true : false ); 1102 1126 } 1103 1127 1104 READ_UVLC ( uiCode, "num_short_term_ref_pic_sets");1128 READ_UVLC_CHK( uiCode, "num_short_term_ref_pic_sets", 0, 64 ); 1105 1129 1106 1130 assert(uiCode <= 64); … … 1132 1156 #endif 1133 1157 { 1134 READ_UVLC ( uiCode, "num_long_term_ref_pics_sps");1158 READ_UVLC_CHK( uiCode, "num_long_term_ref_pics_sps", 0, 32 ); 1135 1159 pcSPS->setNumLongTermRefPicSPS(uiCode); 1136 1160 for (UInt k = 0; k < pcSPS->getNumLongTermRefPicSPS(); k++) … … 1142 1166 } 1143 1167 } 1144 READ_FLAG( uiCode, "sps_temporal_mvp_enable _flag" ); pcSPS->setTMVPFlagsPresent(uiCode);1145 1146 READ_FLAG( uiCode, "s ps_strong_intra_smoothing_enable_flag" );pcSPS->setUseStrongIntraSmoothing(uiCode);1168 READ_FLAG( uiCode, "sps_temporal_mvp_enabled_flag" ); pcSPS->setSPSTemporalMVPEnabledFlag(uiCode); 1169 1170 READ_FLAG( uiCode, "strong_intra_smoothing_enable_flag" ); pcSPS->setUseStrongIntraSmoothing(uiCode); 1147 1171 1148 1172 READ_FLAG( uiCode, "vui_parameters_present_flag" ); pcSPS->setVuiParametersPresentFlag(uiCode); … … 2135 2159 for( Int j = 0; j <= vps->getMaxSubLayersInLayerSetMinus1( currLsIdx ); j++ ) 2136 2160 { 2137 #if NH_3D_FIX_TICKET_1142138 2161 if( j > 0 && dpbSize.getSubLayerFlagInfoPresentFlag( i ) ) 2139 #else2140 if( j > 0 && dpbSize.getSubLayerDpbInfoPresentFlag( i, j ) )2141 #endif2142 2162 { 2143 2163 READ_FLAG( uiCode, "sub_layer_dpb_info_present_flag" ); dpbSize.setSubLayerDpbInfoPresentFlag( i, j, uiCode == 1 ); … … 2611 2631 pcSlice->setRPS(rps); 2612 2632 } 2613 if (sps->getTMVPFlagsPresent())2633 if (sps->getSPSTemporalMVPEnabledFlag()) 2614 2634 { 2615 2635 READ_FLAG( uiCode, "slice_temporal_mvp_enabled_flag" ); … … 2881 2901 } 2882 2902 2883 #if NH_3D _IC2903 #if NH_3D 2884 2904 else if( pcSlice->getViewIndex() && ( pcSlice->getSliceType() == P_SLICE || pcSlice->getSliceType() == B_SLICE ) 2885 2905 && !pcSlice->getIsDepth() && vps->getNumRefListLayers( layerId ) > 0 … … 2903 2923 { 2904 2924 READ_UVLC( uiCode, "five_minus_max_num_merge_cand"); 2905 #if NH_3D _IV_MERGE2925 #if NH_3D 2906 2926 pcSlice->setMaxNumMergeCand(( ( pcSlice->getMpiFlag() || pcSlice->getIvMvPredFlag() || pcSlice->getViewSynthesisPredFlag() ) ? MRG_MAX_NUM_CANDS_MEM : MRG_MAX_NUM_CANDS) - uiCode); 2907 2927 #else … … 2960 2980 if(pcSlice->getDeblockingFilterOverrideFlag()) 2961 2981 { 2962 READ_FLAG ( uiCode, "slice_d isable_deblocking_filter_flag" ); pcSlice->setDeblockingFilterDisable(uiCode ? 1 : 0);2982 READ_FLAG ( uiCode, "slice_deblocking_filter_disabled_flag" ); pcSlice->setDeblockingFilterDisable(uiCode ? 1 : 0); 2963 2983 if(!pcSlice->getDeblockingFilterDisable()) 2964 2984 { … … 2973 2993 else 2974 2994 { 2975 pcSlice->setDeblockingFilterDisable ( pps->getPicDisableDeblockingFilterFlag() );2995 pcSlice->setDeblockingFilterDisable ( pps->getPPSDeblockingFilterDisabledFlag() ); 2976 2996 pcSlice->setDeblockingFilterBetaOffsetDiv2( pps->getDeblockingFilterBetaOffsetDiv2() ); 2977 2997 pcSlice->setDeblockingFilterTcOffsetDiv2 ( pps->getDeblockingFilterTcOffsetDiv2() ); … … 3298 3318 ptl->setIntraConstraintFlag(false); 3299 3319 ptl->setLowerBitRateConstraintFlag(true); 3320 if (ptl->getProfileIdc() == Profile::MAIN10 || ptl->getProfileCompatibilityFlag(Profile::MAIN10)) 3321 { 3322 READ_CODE(7, uiCode, PTL_TRACE_TEXT("reserved_zero_7bits" )); 3323 READ_FLAG( uiCode, PTL_TRACE_TEXT("one_picture_only_constraint_flag")); ptl->setOnePictureOnlyConstraintFlag(uiCode != 0); 3324 READ_CODE(16, uiCode, PTL_TRACE_TEXT("reserved_zero_35bits[0..15]" )); 3325 READ_CODE(16, uiCode, PTL_TRACE_TEXT("reserved_zero_35bits[16..31]" )); 3326 READ_CODE(3, uiCode, PTL_TRACE_TEXT("reserved_zero_35bits[32..34]" )); 3327 } 3328 else 3329 { 3300 3330 READ_CODE(16, uiCode, PTL_TRACE_TEXT("reserved_zero_43bits[0..15]" )); 3301 3331 READ_CODE(16, uiCode, PTL_TRACE_TEXT("reserved_zero_43bits[16..31]" )); 3302 3332 READ_CODE(11, uiCode, PTL_TRACE_TEXT("reserved_zero_43bits[32..42]" )); 3333 } 3303 3334 } 3304 3335 … … 3355 3386 } 3356 3387 3357 #if NH_3D _DIS3388 #if NH_3D 3358 3389 Void TDecCavlc::parseDIS( TComDataCU* /*pcCU*/, UInt /*uiAbsPartIdx*/, UInt /*uiDepth*/ ) 3359 3390 { … … 3439 3470 Int iDQp; 3440 3471 3441 #if RExt__DECODER_DEBUG_BIT_STATISTICS 3472 #if RExt__DECODER_DEBUG_BIT_STATISTICS || ENC_DEC_TRACE 3442 3473 READ_SVLC(iDQp, "delta_qp"); 3443 3474 #else … … 3497 3528 } 3498 3529 3499 #if NH_3D _ARP3530 #if NH_3D 3500 3531 Void TDecCavlc::parseARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3501 3532 { 3502 3533 assert(0); 3503 3534 } 3504 #endif 3505 #if NH_3D_IC 3535 3506 3536 Void TDecCavlc::parseICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3507 3537 { 3508 3538 assert(0); 3509 3539 } 3510 #endif 3511 #if NH_3D_SDC_INTRA || NH_3D_SDC_INTER 3540 3512 3541 Void TDecCavlc::parseSDCFlag ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3513 3542 { … … 3515 3544 } 3516 3545 3517 #endif 3518 #if NH_3D_DBBP 3519 Void TDecCavlc::parseDBBPFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3520 { 3521 assert(0); 3522 } 3546 Void TDecCavlc::parseDBBPFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) 3547 { 3548 assert(0); 3549 } 3523 3550 #endif 3524 3551 // ====================================================================================================================
Note: See TracChangeset for help on using the changeset viewer.