Changeset 77 in 3DVCSoftware for trunk/source/App
- Timestamp:
- 14 Jun 2012, 16:38:29 (13 years ago)
- Location:
- trunk/source/App
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/App/TAppDecoder/TAppDecTop.cpp
r57 r77 82 82 Void TAppDecTop::decode() 83 83 { 84 #if VIDYO_VPS_INTEGRATION 85 increaseNumberOfViews( 0, 0, 0 ); 86 #else 84 87 increaseNumberOfViews( 1 ); 88 #endif 89 85 90 #if SONY_COLPIC_AVAILABILITY 86 91 m_tDecTop[0]->setViewOrderIdx(0); … … 140 145 { 141 146 read(nalu, nalUnit); 147 #if VIDYO_VPS_INTEGRATION 148 Int viewId = 0; 149 Int depth = 0; 150 151 if(nalu.m_nalUnitType != NAL_UNIT_VPS || nalu.m_layerId) 152 { 153 // code assumes that the first nal unit is VPS 154 // currently, this is a hack that requires non-first VPSs have non-zero layer_id 155 viewId = getVPSAccess()->getActiveVPS()->getViewId(nalu.m_layerId); 156 depth = getVPSAccess()->getActiveVPS()->getDepthFlag(nalu.m_layerId); 157 } 158 viewDepthId = nalu.m_layerId; // coding order T0D0T1D1T2D2 159 #else 142 160 Int viewId = nalu.m_viewId; 143 161 Int depth = nalu.m_isDepth ? 1 : 0; 144 162 viewDepthId = viewId * 2 + depth; // coding order T0D0T1D1T2D2 163 #endif 164 145 165 newPicture[viewDepthId] = false; 146 166 if( viewDepthId >= m_tDecTop.size() ) 147 167 { 168 #if VIDYO_VPS_INTEGRATION 169 increaseNumberOfViews( viewDepthId, viewId, depth ); 170 #else 148 171 increaseNumberOfViews( viewDepthId +1 ); 172 #endif 149 173 } 150 174 if(m_iMaxTemporalLayer >= 0 && nalu.m_temporalId > m_iMaxTemporalLayer) … … 392 416 m_pocLastDisplay[viewDepthId] = -MAX_INT; 393 417 } 394 418 #if VIDYO_VPS_INTEGRATION 419 Void TAppDecTop::increaseNumberOfViews ( UInt layerId, UInt viewId, UInt isDepth ) 420 #else 395 421 Void TAppDecTop::increaseNumberOfViews ( Int newNumberOfViewDepth ) 396 { 422 #endif 423 { 424 #if VIDYO_VPS_INTEGRATION 425 Int newNumberOfViewDepth = layerId + 1; 426 #endif 397 427 if ( m_outputBitDepth == 0 ) 398 428 { 399 429 m_outputBitDepth = g_uiBitDepth + g_uiBitIncrement; 400 430 } 431 #if !VIDYO_VPS_INTEGRATION 401 432 Int viewId = (newNumberOfViewDepth-1)>>1; // coding order T0D0T1D1T2D2 402 433 Bool isDepth = ((newNumberOfViewDepth % 2) == 0); // coding order T0D0T1D1T2D2 434 #endif 403 435 if( isDepth ) 404 436 m_useDepth = true; -
trunk/source/App/TAppDecoder/TAppDecTop.h
r56 r77 74 74 CamParsCollector m_cCamParsCollector; 75 75 #if DEPTH_MAP_GENERATION 76 #if VIDYO_VPS_INTEGRATION 77 TComVPSAccess m_cVPSAccess; 78 #endif 76 79 TComSPSAccess m_cSPSAccess; 77 80 TComAUPicAccess m_cAUPicAccess; … … 85 88 Void destroy (); ///< destroy internal members 86 89 Void decode (); ///< main decoding function 90 #if VIDYO_VPS_INTEGRATION 91 Void increaseNumberOfViews (UInt layerId, UInt viewId, UInt isDepth); 92 #else 87 93 Void increaseNumberOfViews (Int newNumberOfViewDepth); 94 #endif 88 95 TDecTop* getTDecTop ( Int viewId, Bool isDepth ); 89 96 … … 92 99 93 100 #if DEPTH_MAP_GENERATION 101 #if VIDYO_VPS_INTEGRATION 102 TComVPSAccess* getVPSAccess () { return &m_cVPSAccess; } 103 #endif 94 104 TComSPSAccess* getSPSAccess () { return &m_cSPSAccess; } 95 105 TComAUPicAccess* getAUPicAccess() { return &m_cAUPicAccess; } -
trunk/source/App/TAppEncoder/TAppEncTop.cpp
r56 r77 67 67 Void TAppEncTop::xInitLibCfg() 68 68 { 69 #if VIDYO_VPS_INTEGRATION 70 UInt layerId = 0; 71 // TODO: fix the assumption here that the temporal structures are all equal across all layers??? 72 m_cVPS.setMaxTLayers( m_maxTempLayer[0] ); 73 m_cVPS.setMaxLayers( m_iNumberOfViews * (m_bUsingDepthMaps ? 2:1) ); 74 for(Int i = 0; i < MAX_TLAYER; i++) 75 { 76 m_cVPS.setNumReorderPics( m_numReorderPics[0][i], i ); 77 m_cVPS.setMaxDecPicBuffering( m_maxDecPicBuffering[0][i], i ); 78 } 79 #endif 80 69 81 for(Int iViewIdx=0; iViewIdx<m_iNumberOfViews; iViewIdx++) 70 82 { … … 90 102 m_acTEncTopList[iViewIdx]->setIsDepth ( false ); 91 103 m_acTEncTopList[iViewIdx]->setViewOrderIdx ( m_cCameraData.getViewOrderIndex()[ iViewIdx ] ); 104 #if VIDYO_VPS_INTEGRATION 105 layerId = iViewIdx * (m_bUsingDepthMaps ? 2:1); 106 m_acTEncTopList[iViewIdx]->setLayerId ( layerId ); 107 m_cVPS.setDepthFlag ( false, layerId ); 108 m_cVPS.setViewId ( iViewIdx, layerId ); 109 m_cVPS.setViewOrderIdx ( m_cCameraData.getViewOrderIndex()[ iViewIdx ], layerId ); 110 // TODO: set correct dependentFlag and dependentLayer 111 m_cVPS.setDependentFlag ( iViewIdx ? true:false, layerId ); 112 m_cVPS.setDependentLayer ( layerId - (m_bUsingDepthMaps ? 2:1), layerId ); 113 #endif 114 92 115 m_acTEncTopList[iViewIdx]->setCamParPrecision ( m_cCameraData.getCamParsCodedPrecision () ); 93 116 m_acTEncTopList[iViewIdx]->setCamParInSliceHeader ( m_cCameraData.getVaryingCameraParameters() ); … … 364 387 m_acTEncDepthTopList[iViewIdx]->setIsDepth ( true ); 365 388 m_acTEncDepthTopList[iViewIdx]->setViewOrderIdx ( m_cCameraData.getViewOrderIndex()[ iViewIdx ] ); 389 #if VIDYO_VPS_INTEGRATION 390 layerId = iViewIdx * 2 + 1; 391 m_acTEncDepthTopList[iViewIdx]->setLayerId ( layerId ); 392 m_cVPS.setDepthFlag ( true, layerId ); 393 m_cVPS.setViewId ( iViewIdx, layerId ); 394 m_cVPS.setViewOrderIdx ( m_cCameraData.getViewOrderIndex()[ iViewIdx ], layerId ); 395 m_cVPS.setDependentFlag ( true, layerId ); 396 m_cVPS.setDependentLayer ( layerId-1, layerId); 397 #endif 366 398 m_acTEncDepthTopList[iViewIdx]->setCamParPrecision ( 0 ); 367 399 m_acTEncDepthTopList[iViewIdx]->setCamParInSliceHeader ( false ); … … 1134 1166 case NAL_UNIT_SPS: 1135 1167 case NAL_UNIT_PPS: 1168 #if VIDYO_VPS_INTEGRATION 1169 case NAL_UNIT_VPS: 1170 #endif 1136 1171 m_essentialBytes += *it_stats; 1137 1172 break; -
trunk/source/App/TAppEncoder/TAppEncTop.h
r56 r77 80 80 81 81 #if DEPTH_MAP_GENERATION 82 #if VIDYO_VPS_INTEGRATION 83 TComVPSAccess m_cVPSAccess; 84 #endif 82 85 TComSPSAccess m_cSPSAccess; 83 86 TComAUPicAccess m_cAUPicAccess; 84 87 #endif 85 88 89 #if VIDYO_VPS_INTEGRATION 90 TComVPS m_cVPS; 91 #endif 92 86 93 #if HHI_VSO 87 94 TRenTop m_cRendererTop; … … 131 138 #endif 132 139 140 #if VIDYO_VPS_INTEGRATION 141 TComVPS* getVPS() { return &m_cVPS; } 142 TComVPSAccess* getVPSAccess () { return &m_cVPSAccess; } 143 #endif 144 133 145 #if DEPTH_MAP_GENERATION 134 146 TComSPSAccess* getSPSAccess () { return &m_cSPSAccess; }
Note: See TracChangeset for help on using the changeset viewer.