Changeset 1196 in 3DVCSoftware for trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp


Ignore:
Timestamp:
4 May 2015, 17:47:40 (9 years ago)
Author:
tech
Message:

Merged 14.0-dev0@1187.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/Lib/TLibDecoder/TDecCAVLC.cpp

    r1179 r1196  
    3939#include "SEIread.h"
    4040#include "TDecSlice.h"
    41 #if H_3D_ANNEX_SELECTION_FIX
     41#if H_3D
    4242#include "TDecTop.h"
    4343#endif
     
    9393TDecCavlc::TDecCavlc()
    9494{
    95 #if !HHI_CAM_PARA_K0052
    96 #if H_3D
    97   m_aaiTempScale            = new Int* [ MAX_NUM_LAYERS ];
    98   m_aaiTempOffset           = new Int* [ MAX_NUM_LAYERS ];
    99   for( UInt uiVId = 0; uiVId < MAX_NUM_LAYERS; uiVId++ )
    100   {
    101     m_aaiTempScale            [ uiVId ] = new Int [ MAX_NUM_LAYERS ];
    102     m_aaiTempOffset           [ uiVId ] = new Int [ MAX_NUM_LAYERS ];
    103   }
    104 #endif
    105 #endif
    10695}
    10796
    10897TDecCavlc::~TDecCavlc()
    10998{
    110 #if !HHI_CAM_PARA_K0052
    111 #if H_3D
    112   for( UInt uiVId = 0; uiVId < MAX_NUM_LAYERS; uiVId++ )
    113   {
    114     delete [] m_aaiTempScale            [ uiVId ];
    115     delete [] m_aaiTempOffset           [ uiVId ];
    116   }
    117   delete [] m_aaiTempScale;
    118   delete [] m_aaiTempOffset;
    119 #endif
    120 #endif
    12199}
    122100
     
    10481026      READ_FLAG( uiCode, "qt_pred_flag" ); sps3dExt->setQtPredFlag( d, uiCode == 1 );
    10491027      READ_FLAG( uiCode, "inter_sdc_flag" ); sps3dExt->setInterSdcFlag( d, uiCode == 1 );
    1050 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
    10511028      READ_FLAG( uiCode, "intra_skip_flag" ); sps3dExt->setDepthIntraSkipFlag( d, uiCode == 1 );
    1052 #else
    1053       READ_FLAG( uiCode, "intra_single_flag" ); sps3dExt->setIntraSingleFlag( d, uiCode == 1 );
    1054 #endif
    10551029    }
    10561030  }
     
    10631037  READ_FLAG( uiCode, "poc_reset_info_present_flag" ); pcPPS->setPocResetInfoPresentFlag( uiCode == 1 );
    10641038  READ_FLAG( uiCode, "pps_infer_scaling_list_flag" ); pcPPS->setPpsInferScalingListFlag( uiCode == 1 );
    1065 #if FIX_TICKET_95
    10661039  if (pcPPS->getPpsInferScalingListFlag())
    10671040  {
    10681041  READ_CODE( 6, uiCode, "pps_scaling_list_ref_layer_id" ); pcPPS->setPpsScalingListRefLayerId( uiCode );
    10691042  }
    1070 #else
    1071   READ_CODE( 6, uiCode, "pps_scaling_list_ref_layer_id" ); pcPPS->setPpsScalingListRefLayerId( uiCode );
    1072 #endif
    10731043
    10741044  UInt numRefLocOffsets;;
     
    13361306  }
    13371307
    1338 #if HHI_INTER_COMP_PRED_K0052
    13391308#if H_3D
    13401309  pcVPS->initViewCompLayer( );
    1341 #endif
    13421310#endif
    13431311
     
    19291897Void TDecCavlc::parseVPS3dExtension( TComVPS* pcVPS )
    19301898{
    1931 #if HHI_CAM_PARA_K0052
    19321899  UInt uiCode;   
    19331900  READ_UVLC( uiCode, "cp_precision"); pcVPS->setCpPrecision( uiCode ) ;
     
    19591926  }
    19601927  pcVPS->deriveCpPresentFlag();
    1961 #else
    1962   UInt uiCode;
    1963 
    1964   UInt uiCamParPrecision = 0;
    1965   Bool bCamParSlice      = false;
    1966   Bool bCamParPresentFlag = false;
    1967 
    1968   READ_UVLC( uiCamParPrecision, "cp_precision" );
    1969 #if HHI_VIEW_ID_LIST_I5_J0107
    1970   for (Int n = 1; n < pcVPS->getNumViews(); n++)
    1971   {
    1972     Int viewIndex = pcVPS->getViewOIdxList( n );
    1973 #else
    1974   for (UInt viewIndex=1; viewIndex<pcVPS->getNumViews(); viewIndex++)
    1975   {
    1976 #endif
    1977     pcVPS->setCamParPresent         ( viewIndex, false );
    1978     pcVPS->setHasCamParInSliceHeader( viewIndex, false );
    1979     READ_FLAG( uiCode, "cp_present_flag[i]" );                  bCamParPresentFlag = ( uiCode == 1);
    1980     if ( bCamParPresentFlag )
    1981     {
    1982       READ_FLAG( uiCode, "cp_in_slice_segment_header_flag[i]" );          bCamParSlice = ( uiCode == 1);
    1983       if ( !bCamParSlice )
    1984       {
    1985 #if HHI_VIEW_ID_LIST_I5_J0107
    1986         for( UInt m = 0; m < n; n++ )
    1987         {
    1988           Int uiBaseIndex = pcVPS->getViewOIdxList ( m );
    1989           Int iCode;
    1990           READ_SVLC( iCode, "vps_cp_scale" );                m_aaiTempScale  [ uiBaseIndex ][ viewIndex ]   = iCode;
    1991           READ_SVLC( iCode, "vps_cp_off" );                  m_aaiTempOffset [ uiBaseIndex ][ viewIndex ]   = iCode;
    1992           READ_SVLC( iCode, "vps_cp_inv_scale_plus_scale" ); m_aaiTempScale  [ viewIndex   ][ uiBaseIndex ] = iCode - m_aaiTempScale [ uiBaseIndex ][ viewIndex ];
    1993           READ_SVLC( iCode, "vps_cp_inv_off_plus_off" );     m_aaiTempOffset [ viewIndex   ][ uiBaseIndex ] = iCode - m_aaiTempOffset[ uiBaseIndex ][ viewIndex ];
    1994         }
    1995       }
    1996       pcVPS->initCamParaVPS( viewIndex, bCamParPresentFlag, uiCamParPrecision, bCamParSlice, m_aaiTempScale, m_aaiTempOffset );
    1997 #else
    1998         for( UInt uiBaseIndex = 0; uiBaseIndex < viewIndex; uiBaseIndex++ )
    1999         {
    2000           Int iCode;
    2001           READ_SVLC( iCode, "vps_cp_scale" );                m_aaiTempScale  [ uiBaseIndex ][ viewIndex ]   = iCode;
    2002           READ_SVLC( iCode, "vps_cp_off" );                  m_aaiTempOffset [ uiBaseIndex ][ viewIndex ]   = iCode;
    2003           READ_SVLC( iCode, "vps_cp_inv_scale_plus_scale" ); m_aaiTempScale  [ viewIndex   ][ uiBaseIndex ] = iCode - m_aaiTempScale [ uiBaseIndex ][ viewIndex ];
    2004           READ_SVLC( iCode, "vps_cp_inv_off_plus_off" );     m_aaiTempOffset [ viewIndex   ][ uiBaseIndex ] = iCode - m_aaiTempOffset[ uiBaseIndex ][ viewIndex ];
    2005         }
    2006       }
    2007       pcVPS->initCamParaVPS( viewIndex, bCamParPresentFlag, uiCamParPrecision, bCamParSlice, m_aaiTempScale, m_aaiTempOffset );
    2008 #endif
    2009     }
    2010   }
    2011 #endif
    20121928}
    20131929#endif
     
    20701986#endif
    20711987  rpcSlice->setSPS(sps);
    2072 #if !HHI_INTER_COMP_PRED_K0052
    2073 #if H_3D
    2074   rpcSlice->init3dToolParameters();
    2075 #endif
    2076 #endif
    20771988  rpcSlice->setPPS(pps);
    20781989  if( pps->getDependentSliceSegmentsEnabledFlag() && ( !firstSliceSegmentInPic ))
     
    24682379      }
    24692380    }
    2470 #if HHI_INTER_COMP_PRED_K0052
    24712381#if H_3D
    24722382    if ( getDecTop()->decProcAnnexI() )
     
    24812391#endif
    24822392#endif
    2483 #endif
    24842393    if(sps->getUseSAO())
    24852394    {
     
    24882397      if( rpcSlice->getSPS()->getChromaFormatIdc() != 0 )
    24892398      {
    2490       READ_FLAG(uiCode, "slice_sao_chroma_flag");  rpcSlice->setSaoEnabledFlagChroma((Bool)uiCode);
    2491     }
     2399        READ_FLAG(uiCode, "slice_sao_chroma_flag");  rpcSlice->setSaoEnabledFlagChroma((Bool)uiCode);
     2400      }
    24922401      else
    24932402      {
    24942403        rpcSlice->setSaoEnabledFlagChroma( false );
    24952404      }
    2496      
    24972405#else
    24982406      READ_FLAG(uiCode, "slice_sao_chroma_flag");  rpcSlice->setSaoEnabledFlagChroma((Bool)uiCode);
     
    26622570    }
    26632571#if H_3D_IC
    2664 #if H_3D_ANNEX_SELECTION_FIX
    26652572    else if(    rpcSlice->getViewIndex() && ( rpcSlice->getSliceType() == P_SLICE || rpcSlice->getSliceType() == B_SLICE )
    26662573             && !rpcSlice->getIsDepth() && vps->getNumRefListLayers( layerId ) > 0
    26672574             && getDecTop()->decProcAnnexI()
    26682575           )
    2669 #else
    2670     else if( rpcSlice->getViewIndex() && ( rpcSlice->getSliceType() == P_SLICE || rpcSlice->getSliceType() == B_SLICE ) && !rpcSlice->getIsDepth() && vps->getNumRefListLayers( layerId ) > 0 )
    2671 #endif
    26722576    {
    26732577      UInt uiCodeTmp = 0;
     
    27662670    rpcSlice->setLFCrossSliceBoundaryFlag( (uiCode==1)?true:false);
    27672671
    2768 #if HHI_CAM_PARA_K0052
    27692672#if H_3D
    27702673    if ( getDecTop()->decProcAnnexI() )
     
    27842687    }
    27852688#endif
    2786 #endif
    27872689  }
    27882690 
     
    28082710  }
    28092711
    2810 #if !HHI_CAM_PARA_K0052
    2811 #if H_3D
    2812 #if H_3D_FCO
    2813   if( rpcSlice->getVPS()->hasCamParInSliceHeader( rpcSlice->getViewIndex() )  && rpcSlice->getIsDepth() )
    2814 #else
    2815   if( rpcSlice->getVPS()->hasCamParInSliceHeader( rpcSlice->getViewIndex() )  && !rpcSlice->getIsDepth() )
    2816 #endif
    2817   {
    2818     UInt uiViewIndex = rpcSlice->getViewIndex();
    2819     for( UInt uiBaseIndex = 0; uiBaseIndex < uiViewIndex; uiBaseIndex++ )
    2820     {
    2821       READ_SVLC( iCode, "cp_scale" );                m_aaiTempScale [ uiBaseIndex ][ uiViewIndex ] = iCode;
    2822       READ_SVLC( iCode, "cp_off" );                  m_aaiTempOffset[ uiBaseIndex ][ uiViewIndex ] = iCode;
    2823       READ_SVLC( iCode, "cp_inv_scale_plus_scale" ); m_aaiTempScale [ uiViewIndex ][ uiBaseIndex ] = iCode - m_aaiTempScale [ uiBaseIndex ][ uiViewIndex ];
    2824       READ_SVLC( iCode, "cp_inv_off_plus_off" );     m_aaiTempOffset[ uiViewIndex ][ uiBaseIndex ] = iCode - m_aaiTempOffset[ uiBaseIndex ][ uiViewIndex ];
    2825     }
    2826     rpcSlice->setCamparaSlice( m_aaiTempScale, m_aaiTempOffset );
    2827   }
    2828 #endif
    2829 #endif
    28302712
    28312713  if(pps->getSliceHeaderExtensionPresentFlag())
     
    31002982  assert(0);
    31012983}
    3102 
    3103 #if SEC_DEPTH_INTRA_SKIP_MODE_K0033
     2984#if H_3D
    31042985Void TDecCavlc::parseDIS( TComDataCU* /*pcCU*/, UInt /*uiAbsPartIdx*/, UInt /*uiDepth*/ )
    31052986{
    31062987  assert(0);
    31072988}
    3108 #else
    3109 #if H_3D_SINGLE_DEPTH
    3110 Void TDecCavlc::parseSingleDepthMode( TComDataCU* /*pcCU*/, UInt /*uiAbsPartIdx*/, UInt /*uiDepth*/ )
    3111 {
    3112   assert(0);
    3113 }
    3114 #endif
    31152989#endif
    31162990
Note: See TracChangeset for help on using the changeset viewer.