Changeset 1317 in 3DVCSoftware for branches/HTM-15.0-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
- Timestamp:
- 4 Sep 2015, 21:28:58 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HTM-15.0-dev0/source/Lib/TLibEncoder/TEncCavlc.cpp
r1313 r1317 40 40 #include "SEIwrite.h" 41 41 42 #if NH_ 3D42 #if NH_MV 43 43 #include "TEncTop.h" 44 44 #endif … … 53 53 { 54 54 fprintf( g_hTrace, "=========== Video Parameter Set ===========\n" ); 55 } 55 56 56 57 Void xTraceSPSHeader () … … 380 381 WRITE_CODE((pcPPS->getDLT()->getDepthViewBitDepth() - 8), 4, "pps_bit_depth_for_depth_layers_minus8"); 381 382 382 #if NH_3D_DLT_FIX383 383 for( Int i = 0; i <= pcPPS->getDLT()->getNumDepthViews()-1; i++ ) 384 #else385 for( Int i = 0; i <= pcPPS->getDLT()->getNumDepthViews(); i++ )386 #endif387 384 { 388 385 Int layerId = pcPPS->getDLT()->getDepthIdxToLayerId(i); … … 748 745 WRITE_UVLC( pcSPS->getMaxDecPicBuffering(i) - 1, "sps_max_dec_pic_buffering_minus1[i]" ); 749 746 WRITE_UVLC( pcSPS->getNumReorderPics(i), "sps_max_num_reorder_pics[i]" ); 747 #if NH_MV 748 WRITE_UVLC( pcSPS->getSpsMaxLatencyIncreasePlus1(i), "sps_max_latency_increase_plus1[i]" ); 749 #else 750 750 WRITE_UVLC( pcSPS->getMaxLatencyIncrease(i), "sps_max_latency_increase_plus1[i]" ); 751 #endif 751 752 if (!subLayerOrderingInfoPresentFlag) 752 753 { … … 814 815 codeShortTermRefPicSet( rps,false, i); 815 816 } 817 #if NH_MV 818 WRITE_FLAG( pcSPS->getLongTermRefPicsPresentFlag() ? 1 : 0, "long_term_ref_pics_present_flag" ); 819 if (pcSPS->getLongTermRefPicsPresentFlag()) 820 #else 816 821 WRITE_FLAG( pcSPS->getLongTermRefsPresent() ? 1 : 0, "long_term_ref_pics_present_flag" ); 817 822 if (pcSPS->getLongTermRefsPresent()) 823 #endif 818 824 { 819 825 WRITE_UVLC(pcSPS->getNumLongTermRefPicSPS(), "num_long_term_ref_pics_sps" ); … … 1747 1753 //write slice address 1748 1754 const Int sliceSegmentRsAddress = pcSlice->getPic()->getPicSym()->getCtuTsToRsAddrMap(ctuTsAddress); 1749 1755 #if NH_MV 1756 // This should actually be done somewhere else and not in writing process. 1757 pcSlice->setFirstSliceSegementInPicFlag( sliceSegmentRsAddress==0 ); 1758 WRITE_FLAG( pcSlice->getFirstSliceSegementInPicFlag() , "first_slice_segment_in_pic_flag" ); 1759 #else 1750 1760 WRITE_FLAG( sliceSegmentRsAddress==0, "first_slice_segment_in_pic_flag" ); 1761 #endif 1751 1762 if ( pcSlice->getRapPicFlag() ) 1752 1763 { … … 1760 1771 else 1761 1772 #endif 1762 1763 1773 WRITE_UVLC( pcSlice->getPPS()->getPPSId(), "slice_pic_parameter_set_id" ); 1764 1774 if ( pcSlice->getPPS()->getDependentSliceSegmentsEnabledFlag() && (sliceSegmentRsAddress!=0) ) … … 1772 1782 if ( !pcSlice->getDependentSliceSegmentFlag() ) 1773 1783 { 1774 1775 1784 #if NH_MV 1776 1785 Int esb = 0; //Don't use i, otherwise will shadow something below … … 1861 1870 } 1862 1871 } 1872 #if NH_MV 1873 if(pcSlice->getSPS()->getLongTermRefPicsPresentFlag()) 1874 #else 1863 1875 if(pcSlice->getSPS()->getLongTermRefsPresent()) 1876 #endif 1864 1877 { 1865 1878 Int numLtrpInSH = rps->getNumberOfLongtermPictures(); … … 2196 2209 Bool isDBFEnabled = (!pcSlice->getDeblockingFilterDisable()); 2197 2210 2198 if(pcSlice->getPPS()->getLoopFilterAcrossSlicesEnabledFlag() && ( isSAOEnabled || isDBFEnabled ))2211 if(pcSlice->getPPS()->getLoopFilterAcrossSlicesEnabledFlag() && ( isSAOEnabled || isDBFEnabled )) 2199 2212 { 2200 2213 WRITE_FLAG(pcSlice->getLFCrossSliceBoundaryFlag()?1:0, "slice_loop_filter_across_slices_enabled_flag"); … … 2204 2217 { 2205 2218 Int voiInVps = vps->getVoiInVps( pcSlice->getViewIndex() ); 2206 #if NH_3D_FIX_TICKET_1012207 2219 if( vps->getCpInSliceSegmentHeaderFlag( voiInVps ) ) 2208 #else2209 if( vps->getCpInSliceSegmentHeaderFlag( voiInVps ) && !pcSlice->getIsDepth() )2210 #endif2211 2220 { 2212 2221 for( Int m = 0; m < vps->getNumCp( voiInVps ); m++ ) … … 2257 2266 if( pcSlice->getPocMsbValRequiredFlag() ) 2258 2267 { 2259 pcSlice->setPocMsb ValPresentFlag( true );2268 pcSlice->setPocMsbCycleValPresentFlag( true ); 2260 2269 } 2261 2270 else 2262 2271 { 2263 pcSlice->setPocMsb ValPresentFlag( false );2264 } 2265 } 2266 2267 if( pcSlice->getPocMsb ValPresentFlag() )2272 pcSlice->setPocMsbCycleValPresentFlag( false ); 2273 } 2274 } 2275 2276 if( pcSlice->getPocMsbCycleValPresentFlag() ) 2268 2277 { 2269 2278 // Int iMaxPOClsb = 1<< pcSlice->getSPS()->getBitsForPOC(); currently unused 2270 2279 2271 2280 UInt lengthVal = 1; 2272 UInt tempVal = pcSlice->getPocMsb Val() + 1;2281 UInt tempVal = pcSlice->getPocMsbCycleVal() + 1; 2273 2282 assert ( tempVal ); 2274 2283 while( 1 != tempVal ) … … 2314 2323 if( !pcSlice->getPocMsbValRequiredFlag() && pcSlice->getVPS()->getVpsPocLsbAlignedFlag() ) 2315 2324 { 2316 WRITE_FLAG( pcSlice->getPocMsb ValPresentFlag( ) ? 1 : 0 , "poc_msb_val_present_flag" );2325 WRITE_FLAG( pcSlice->getPocMsbCycleValPresentFlag( ) ? 1 : 0 , "poc_msb_cycle_val_present_flag" ); 2317 2326 } 2318 2327 else 2319 2328 { 2320 assert( pcSlice->getPocMsb ValPresentFlag() == pcSlice->inferPocMsbValPresentFlag( ) );2329 assert( pcSlice->getPocMsbCycleValPresentFlag() == pcSlice->inferPocMsbCycleValPresentFlag( ) ); 2321 2330 } 2322 2331 2323 if( pcSlice->getPocMsb ValPresentFlag() )2324 { 2325 WRITE_UVLC( pcSlice->getPocMsb Val( ), "poc_msb_val" );2332 if( pcSlice->getPocMsbCycleValPresentFlag() ) 2333 { 2334 WRITE_UVLC( pcSlice->getPocMsbCycleVal( ), "poc_msb_cycle_val" ); 2326 2335 } 2327 2336 … … 2347 2356 for (Int i = 0; i < maxNumSubLayersMinus1; i++) 2348 2357 { 2349 #if !NH_MV2350 #endif2351 2358 WRITE_FLAG( pcPTL->getSubLayerProfilePresentFlag(i), "sub_layer_profile_present_flag[i]" ); 2352 #if !NH_MV2353 #endif2354 2359 WRITE_FLAG( pcPTL->getSubLayerLevelPresentFlag(i), "sub_layer_level_present_flag[i]" ); 2355 2360 }
Note: See TracChangeset for help on using the changeset viewer.