Changeset 878 in 3DVCSoftware


Ignore:
Timestamp:
27 Mar 2014, 19:51:52 (11 years ago)
Author:
tech
Message:

Cleanups part 3.

Location:
branches/HTM-10.1-dev0/source/Lib
Files:
13 edited

Legend:

Unmodified
Added
Removed
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/ContextTables.h

    r877 r878  
    104104
    105105#if H_3D_DIM
    106 #if QC_GENERIC_SDC_G0122
    107106#define NUM_DEPTH_INTRA_MODE_CTX      1       ///< number of context models for depth intra modes
    108 #else
    109 #define NUM_DEPTH_INTRA_MODE_CTX      8       ///< number of context models for depth intra modes
    110 #endif
    111107#define NUM_DDC_FLAG_CTX              2       ///< number of context models for deltaDC flag (DMM or RBC)
    112108#define NUM_DDC_DATA_CTX              1       ///< number of context models for deltaDC data (DMM or RBC)
     
    114110#define NUM_DMM1_DATA_CTX             1       ///< number of context models for DMM1 data
    115111#endif
    116 #if QC_GENERIC_SDC_G0122
    117112#define NUM_ANGLE_FLAG_CTX            3
    118 #endif
    119113#endif
    120114
     
    366360#endif
    367361#if H_3D_DIM
    368 #if QC_GENERIC_SDC_G0122
    369362static const UChar
    370363INIT_DEPTH_INTRA_MODE[3][NUM_DEPTH_INTRA_MODE_CTX] =
     
    374367  { 154, }
    375368};
    376 #else
    377 static const UChar
    378 INIT_DEPTH_INTRA_MODE[3][NUM_DEPTH_INTRA_MODE_CTX] =
    379 {
    380     {0,  0,  64, 168, 168, 124, CNU, 0},
    381     {0, 64,   0, 183, CNU, 108,   0, 0},
    382     {64, 0, CNU, CNU, 168, 109,   0, 0}
    383 };
    384 #endif
    385 
    386 #if QC_GENERIC_SDC_G0122
     369
    387370static const UChar
    388371INIT_ANGLE_FLAG[3][NUM_ANGLE_FLAG_CTX] =
     
    392375  { 155, 170, 157 },
    393376};
    394 #endif
    395377
    396378static const UChar
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/TComDataCU.cpp

    r877 r878  
    23752375#endif
    23762376
    2377 #if QC_GENERIC_SDC_G0122
     2377#if H_3D_DIM_SDC
    23782378UInt TComDataCU::getCtxSDCFlag( UInt uiAbsPartIdx )
    23792379{
     
    26242624  // check general CU information
    26252625  if( !getSlice()->getIsDepth() || !isIntra(uiAbsPartIdx) || getPartitionSize(uiAbsPartIdx) != SIZE_2Nx2N )
     2626  {
    26262627    return false;
    2627 #if QC_GENERIC_SDC_G0122
     2628  }
     2629
    26282630  if( isDimMode( getLumaIntraDir( uiAbsPartIdx ) ) && !isDimDeltaDC( getLumaIntraDir( uiAbsPartIdx ) ) )
    26292631  {
     
    26372639
    26382640  return false;
    2639 #endif
    26402641  // check prediction mode
    26412642  UInt uiLumaPredMode = getLumaIntraDir( uiAbsPartIdx ); 
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/TComDataCU.h

    r877 r878  
    556556  Pel           getSDCSegmentDCOffset( UInt uiSeg, UInt uiPartIdx ) { return m_apSegmentDCOffset[uiSeg][uiPartIdx]; }
    557557  Void          setSDCSegmentDCOffset( Pel pOffset, UInt uiSeg, UInt uiPartIdx) { m_apSegmentDCOffset[uiSeg][uiPartIdx] = pOffset; }
    558 #if QC_GENERIC_SDC_G0122
    559558  UInt          getCtxSDCFlag          ( UInt   uiAbsPartIdx );
    560559  UInt          getCtxAngleFlag        ( UInt   uiAbsPartIdx );
    561 #endif
    562560#endif
    563561#endif
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/TComPrediction.cpp

    r872 r878  
    416416
    417417#if H_3D_DIM
    418 Void TComPrediction::predIntraLumaDepth( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiIntraMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bFastEnc
    419 #if QC_GENERIC_SDC_G0122
    420   , TComWedgelet* dmm4Segmentation
    421 #endif
    422   )
     418Void TComPrediction::predIntraLumaDepth( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiIntraMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bFastEnc, TComWedgelet* dmm4Segmentation  )
    423419{
    424420  assert( iWidth == iHeight  );
     
    446442    case( DMM4_IDX ):
    447443      {
    448 #if QC_GENERIC_SDC_G0122
    449444        if( dmm4Segmentation == NULL )
    450445        {
     
    457452          dmmSegmentation = dmm4Segmentation;
    458453        }
    459 #else
    460         dmmSegmentation = new TComWedgelet( iWidth, iHeight );
    461         xPredContourFromTex( pcCU, uiAbsPartIdx, iWidth, iHeight, dmmSegmentation );
    462 #endif
    463454      } break;
    464455    default: assert(0);
     
    511502
    512503#if H_3D_DIM_DMM
    513 #if QC_GENERIC_SDC_G0122
    514504  if( dimType == DMM4_IDX && dmm4Segmentation == NULL ) { dmmSegmentation->destroy(); delete dmmSegmentation; }
    515 #else
    516   if( dimType == DMM4_IDX ) { dmmSegmentation->destroy(); delete dmmSegmentation; }
    517 #endif
    518505#endif
    519506}
     
    25932580  Int iSumPix[2];
    25942581  memset(iSumPix, 0, sizeof(Int)*2);
    2595 #if QC_GENERIC_SDC_G0122
    25962582  for( Int i = 0; i < uiNumSegments; i++ )
    25972583  {
    25982584    rpSegMeans[i] = 0;
    25992585  }
    2600 #endif
    26012586  if (orgDC == false)
    26022587  {
     
    26132598      rpSegMeans[ucSegmentRB] = pOrig[uiStride * (uiSize-1) + (uiSize-1) ];
    26142599    }
    2615 #if QC_GENERIC_SDC_G0122
    26162600    else if( getDimType( uiIntraMode ) == DMM4_IDX )
    26172601    {
     
    26472631    }
    26482632    else
    2649 #else
    2650     else if (uiIntraMode == PLANAR_IDX)
    2651 #endif
    26522633    {
    26532634      Pel* pLeftTop = pOrig;
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/TComPrediction.h

    r872 r878  
    172172  // Depth intra
    173173  Void predIntraLumaDepth         ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiIntraMode, Pel* piPred, UInt uiStride, Int iWidth, Int iHeight, Bool bFastEnc = false
    174 #if QC_GENERIC_SDC_G0122
    175174    , TComWedgelet* dmm4Segmentation = NULL
    176 #endif
    177175    );
    178176#if H_3D_DIM_SDC
  • branches/HTM-10.1-dev0/source/Lib/TLibCommon/TypeDef.h

    r877 r878  
    184184                                              // QC_DIM_DELTADC_UNIFY_F0132 Unify delta DC coding in depth intra modes
    185185                                              // Unify intra SDC and inter SDC
     186                                              // QC_GENERIC_SDC_G0122 Generalize SDC to all depth intra modes
    186187
    187188
     
    317318#endif
    318319#define SCU_HS_DEPTH_DC_PRED_G0143        1
    319 #define QC_GENERIC_SDC_G0122              1  // Generalize SDC to all depth intra modes
     320
    320321#endif
    321322
  • branches/HTM-10.1-dev0/source/Lib/TLibDecoder/TDecCu.cpp

    r877 r878  
    11191119#if QC_PKU_SDC_SPLIT_G0123
    11201120#if HS_TSINGHUA_SDC_SPLIT_G0111
    1121 #if QC_GENERIC_SDC_G0122
    11221121  TComWedgelet* dmm4SegmentationOrg = new TComWedgelet( uiWidth, uiHeight );
    1123 #endif
    11241122#else
    1125 #if QC_GENERIC_SDC_G0122
    11261123  TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );
    1127 #endif
    11281124#endif
    11291125#endif
     
    12101206#endif
    12111207#if !QC_PKU_SDC_SPLIT_G0123
    1212 #if QC_GENERIC_SDC_G0122
    12131208  TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );
    1214 #endif
    12151209#endif
    12161210#if HS_TSINGHUA_SDC_SPLIT_G0111
     
    12221216  {
    12231217    m_pcPrediction->predIntraLumaDepth( pcCU, uiAbsPartIdx, uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight
    1224 #if QC_GENERIC_SDC_G0122
    12251218      , false, dmm4Segmentation
    1226 #endif
    12271219      );
    12281220#if HS_TSINGHUA_SDC_SPLIT_G0111
     
    12921284    uiMaskStride = pcWedgelet->getStride();
    12931285  }
    1294 #if QC_GENERIC_SDC_G0122
    12951286  if( getDimType( uiLumaPredMode ) == DMM4_IDX )
    12961287  {
     
    13041295#endif
    13051296  }
    1306 #endif
    13071297  // get DC prediction for each segment
    13081298  Pel apDCPredValues[2];
     
    13661356    pRecCr += uiStrideC;
    13671357  }
    1368 #if QC_GENERIC_SDC_G0122
    13691358#if HS_TSINGHUA_SDC_SPLIT_G0111
    13701359  dmm4SegmentationOrg->destroy(); delete dmm4SegmentationOrg;
    13711360#else
    13721361  dmm4Segmentation->destroy(); delete dmm4Segmentation;
    1373 #endif
    13741362#endif
    13751363}
  • branches/HTM-10.1-dev0/source/Lib/TLibDecoder/TDecSbac.cpp

    r877 r878  
    8686, m_cDdcFlagSCModel           ( 1,             1,               NUM_DDC_FLAG_CTX              , m_contextModels + m_numContextModels, m_numContextModels)
    8787, m_cDdcDataSCModel           ( 1,             1,               NUM_DDC_DATA_CTX              , m_contextModels + m_numContextModels, m_numContextModels)
    88 #if QC_GENERIC_SDC_G0122
    8988, m_cAngleFlagSCModel         ( 1,             1,               NUM_ANGLE_FLAG_CTX            , m_contextModels + m_numContextModels, m_numContextModels)
    90 #endif
    9189#if H_3D_DIM_DMM
    9290, m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
     
    172170  m_cDdcFlagSCModel.initBuffer           ( sliceType, qp, (UChar*)INIT_DDC_FLAG );
    173171  m_cDdcDataSCModel.initBuffer           ( sliceType, qp, (UChar*)INIT_DDC_DATA );
    174 #if QC_GENERIC_SDC_G0122
    175172  m_cAngleFlagSCModel.initBuffer         ( sliceType, qp, (UChar*)INIT_ANGLE_FLAG );
    176 #endif
    177173#if H_3D_DIM_DMM
    178174  m_cDmm1DataSCModel.initBuffer          ( sliceType, qp, (UChar*)INIT_DMM1_DATA );
     
    244240  m_cDdcFlagSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_FLAG );
    245241  m_cDdcDataSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_DATA );
    246 #if QC_GENERIC_SDC_G0122
    247242  m_cAngleFlagSCModel.initBuffer         ( eSliceType, iQp, (UChar*)INIT_ANGLE_FLAG );
    248 #endif
    249243#if H_3D_DIM_DMM
    250244  m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
     
    10171011    }
    10181012    if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE )
    1019 #if H_3D_DIM_SDC
    1020 #if QC_GENERIC_SDC_G0122
    1021       if( 1 ) // This should be cleaned up.
    1022 #else
    1023       if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )
    1024 #endif
    1025 #endif
    10261013    {
    10271014#endif
     
    10391026#if H_3D_DIM
    10401027    if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE )
    1041 #if H_3D_DIM_SDC
    1042 #if QC_GENERIC_SDC_G0122
    1043       if( 1 )  // This should be cleaned up.
    1044 #else
    1045       if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )
    1046 #endif
    1047 #endif
    10481028    {
    10491029#endif
     
    11501130}
    11511131
    1152 #if QC_GENERIC_SDC_G0122
    11531132Void TDecSbac::parseIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx, UInt depth )
    11541133{
     
    11801159  }
    11811160}
    1182 #else
    1183 Void TDecSbac::parseIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx, UInt depth )
    1184 {
    1185   UInt puIdx = (pcCU->getWidth(absPartIdx) == 64) ? 2 : ( (pcCU->getPartitionSize(absPartIdx) == SIZE_NxN && pcCU->getWidth(absPartIdx) == 8) ? 0 : 1 );
    1186   UInt dir = 0;
    1187   Bool sdcFlag = 0;
    1188   UInt symbol = 1;
    1189   UInt modeCode = 0 ;
    1190   UInt binNum = 0;
    1191   UInt ctxDepthMode = 0;
    1192 
    1193   if( puIdx == 2 )
    1194   {
    1195     {
    1196       ctxDepthMode = puIdx*3 + binNum;
    1197       m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );
    1198       modeCode = (modeCode<<1) + symbol;
    1199       binNum++;
    1200     }
    1201          if( modeCode == 0 ) { dir = PLANAR_IDX; sdcFlag = 1;}
    1202     else if( modeCode == 1 ) { dir = 0;          sdcFlag = 0;}
    1203   }
    1204   else if( puIdx == 0 )
    1205   {
    1206     while( binNum < 1 && symbol )
    1207     {
    1208       ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);
    1209       m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );
    1210       modeCode = (modeCode<<1) + symbol;
    1211       binNum++;
    1212     }
    1213     if( modeCode == 0 )
    1214     {
    1215       dir = 0;
    1216       sdcFlag = 0;
    1217     }
    1218     else if ( modeCode == 1 )
    1219     {
    1220       dir = (2*DMM1_IDX+DIM_OFFSET);
    1221       sdcFlag = 0;
    1222     }
    1223   }
    1224   else
    1225   {
    1226     while( binNum < 4 && symbol )
    1227     {
    1228       ctxDepthMode = puIdx*3 + ((binNum >= 2) ? 2 : binNum);
    1229       m_pcTDecBinIf->decodeBin( symbol, m_cDepthIntraModeSCModel.get(0,0,ctxDepthMode) );
    1230       modeCode = (modeCode<<1) + symbol;
    1231       binNum++;
    1232     }
    1233     if ( modeCode == 0 )        { dir =  PLANAR_IDX;             sdcFlag = 1;}
    1234     else if ( modeCode == 2 )   { dir = 5;                       sdcFlag = 0;}
    1235     else if ( modeCode == 6 )   { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 1;}
    1236     else if ( modeCode == 14 )  { dir = (2*DMM1_IDX+DIM_OFFSET); sdcFlag = 0;}
    1237     else if ( modeCode == 15 )  { dir = (2*DMM4_IDX+DIM_OFFSET); sdcFlag = 0;}
    1238 
    1239   }
    1240   pcCU->setLumaIntraDirSubParts( (UChar)dir, absPartIdx, depth );
    1241 #if H_3D_DIM_SDC
    1242   pcCU->setSDCFlagSubParts( sdcFlag, absPartIdx, depth );
    1243 #endif
    1244 }
    1245 #endif
    12461161#endif
    12471162
  • branches/HTM-10.1-dev0/source/Lib/TLibDecoder/TDecSbac.h

    r877 r878  
    213213  ContextModel3DBuffer m_cDdcFlagSCModel;
    214214  ContextModel3DBuffer m_cDdcDataSCModel;
    215 #if QC_GENERIC_SDC_G0122
    216215  ContextModel3DBuffer m_cAngleFlagSCModel;
    217 #endif
    218216#if H_3D_DIM_DMM
    219217  ContextModel3DBuffer m_cDmm1DataSCModel;
  • branches/HTM-10.1-dev0/source/Lib/TLibEncoder/TEncSbac.cpp

    r877 r878  
    9292, m_cDdcFlagSCModel           ( 1,             1,               NUM_DDC_FLAG_CTX              , m_contextModels + m_numContextModels, m_numContextModels)
    9393, m_cDdcDataSCModel           ( 1,             1,               NUM_DDC_DATA_CTX              , m_contextModels + m_numContextModels, m_numContextModels)
    94 #if QC_GENERIC_SDC_G0122
    9594, m_cAngleFlagSCModel         ( 1,             1,               NUM_ANGLE_FLAG_CTX            , m_contextModels + m_numContextModels, m_numContextModels)
    96 #endif
    9795#if H_3D_DIM_DMM
    9896, m_cDmm1DataSCModel          ( 1,             1,               NUM_DMM1_DATA_CTX             , m_contextModels + m_numContextModels, m_numContextModels)
     
    170168  m_cDdcFlagSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_FLAG );
    171169  m_cDdcDataSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_DATA );
    172 #if QC_GENERIC_SDC_G0122
    173170  m_cAngleFlagSCModel.initBuffer         ( eSliceType, iQp, (UChar*)INIT_ANGLE_FLAG );
    174 #endif
    175171#if H_3D_DIM_DMM
    176172  m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
     
    258254      curCost += m_cDdcFlagSCModel.calcCost           ( curSliceType, qp, (UChar*)INIT_DDC_FLAG );
    259255      curCost += m_cDdcDataSCModel.calcCost           ( curSliceType, qp, (UChar*)INIT_DDC_DATA );
    260 #if QC_GENERIC_SDC_G0122
    261256      curCost += m_cAngleFlagSCModel.calcCost         ( curSliceType, qp, (UChar*)INIT_ANGLE_FLAG ); 
    262 #endif
    263257#if H_3D_DIM_DMM
    264258      curCost += m_cDmm1DataSCModel.calcCost          ( curSliceType, qp, (UChar*)INIT_DMM1_DATA );
     
    324318  m_cDdcFlagSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_FLAG );
    325319  m_cDdcDataSCModel.initBuffer           ( eSliceType, iQp, (UChar*)INIT_DDC_DATA );
    326 #if QC_GENERIC_SDC_G0122
    327320  m_cAngleFlagSCModel.initBuffer         ( eSliceType, iQp, (UChar*)INIT_ANGLE_FLAG );
    328 #endif
    329321#if H_3D_DIM_DMM
    330322  m_cDmm1DataSCModel.initBuffer          ( eSliceType, iQp, (UChar*)INIT_DMM1_DATA );
     
    640632  this->m_cDepthIntraModeSCModel .copyFrom( &pSrc->m_cDepthIntraModeSCModel );
    641633  this->m_cDdcFlagSCModel        .copyFrom( &pSrc->m_cDdcFlagSCModel );
    642 #if QC_GENERIC_SDC_G0122
    643634  this->m_cAngleFlagSCModel      .copyFrom( &pSrc->m_cAngleFlagSCModel );
    644 #endif
    645635}
    646636#endif
     
    11211111    }
    11221112    if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE )
    1123 #if H_3D_DIM_SDC
    1124 #if QC_GENERIC_SDC_G0122
    1125       if( 1 )
    1126 #else
    1127       if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )
    1128 #endif
    1129 #endif
    1130     {
    1131 #endif
    1132     predNum[j] = pcCU->getIntraDirLumaPredictor(absPartIdx+partOffset*j, preds[j]); 
    1133     for(UInt i = 0; i < predNum[j]; i++)
    1134     {
    1135       if(dir[j] == preds[j][i])
    1136       {
    1137         predIdx[j] = i;
    1138       }
    1139     }
    1140     m_pcBinIf->encodeBin((predIdx[j] != -1)? 1 : 0, m_cCUIntraPredSCModel.get( 0, 0, 0 ) );
     1113    {
     1114#endif
     1115      predNum[j] = pcCU->getIntraDirLumaPredictor(absPartIdx+partOffset*j, preds[j]); 
     1116      for(UInt i = 0; i < predNum[j]; i++)
     1117      {
     1118        if(dir[j] == preds[j][i])
     1119        {
     1120          predIdx[j] = i;
     1121        }
     1122      }
     1123      m_pcBinIf->encodeBin((predIdx[j] != -1)? 1 : 0, m_cCUIntraPredSCModel.get( 0, 0, 0 ) );
    11411124#if H_MV_ENC_DEC_TRAC
    1142     DTRACE_CU("prev_intra_luma_pred_flag", (predIdx[j] != -1)? 1 : 0);
     1125      DTRACE_CU("prev_intra_luma_pred_flag", (predIdx[j] != -1)? 1 : 0);
    11431126#endif
    11441127#if H_3D_DIM
     
    11511134#if H_3D_DIM
    11521135    if( pcCU->getLumaIntraDir( absPartIdx+partOffset*j ) < NUM_INTRA_MODE )
    1153 #if H_3D_DIM_SDC
    1154 #if QC_GENERIC_SDC_G0122
    1155       if( 1 )
    1156 #else
    1157       if( !pcCU->getSDCFlag( absPartIdx+partOffset*j ) )
    1158 #endif
    1159 #endif
    11601136    {
    11611137#endif
     
    12571233}
    12581234
    1259 #if QC_GENERIC_SDC_G0122
    12601235Void TEncSbac::codeIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx )
    12611236{
     
    12801255  }
    12811256}
    1282 #else
    1283 Void TEncSbac::codeIntraDepthMode( TComDataCU* pcCU, UInt absPartIdx )
    1284 {
    1285   UInt codeWordTable[3][7] =    {{0, 0, 0, 1, 0, 0, 0},{0, 2, 6, 14, 15, 0, 0},{0, 1, 0, 0, 0, 0, 0}};
    1286   UInt codeWordLenTable[3][7] = {{0, 1, 0, 1, 0, 0, 0},{1, 2, 3,  4,  4, 0, 0},{1, 1, 0, 0, 0, 0, 0}};
    1287   UInt dir = pcCU->getLumaIntraDir( absPartIdx );
    1288   UInt puIdx = (pcCU->getWidth(absPartIdx) == 64) ? 2 : ( (pcCU->getPartitionSize(absPartIdx) == SIZE_NxN && pcCU->getWidth(absPartIdx) == 8) ? 0 : 1 );
    1289   UInt codeIdx = 0;
    1290 
    1291   if( dir < NUM_INTRA_MODE )
    1292   {
    1293     codeIdx = 1;
    1294   }
    1295   if( isDimMode( dir ) )
    1296   {
    1297     switch( getDimType( dir ) )
    1298     {
    1299     case DMM1_IDX: codeIdx = 3; break;
    1300     case DMM4_IDX: codeIdx = 4; break;
    1301     default:                    break;
    1302     }
    1303   }
    1304 
    1305 #if H_3D_DIM_SDC
    1306   if( pcCU->getSDCFlag( absPartIdx ) )
    1307   {
    1308     switch( dir )
    1309     {
    1310       case PLANAR_IDX:  codeIdx = 0; break;
    1311       default:          codeIdx = 2; break;
    1312     }
    1313   }
    1314 #endif
    1315   //mode coding
    1316   for( UInt i = 0; i < codeWordLenTable[puIdx][codeIdx]; i++ )
    1317   {
    1318     UInt bit = codeWordTable[puIdx][codeIdx] & ( 1<<(codeWordLenTable[puIdx][codeIdx] - i - 1) );
    1319     UInt ctxDepthMode = puIdx*3 + ( (i >= 2) ? 2 : i );
    1320     m_pcBinIf->encodeBin( bit!=0 , m_cDepthIntraModeSCModel.get(0, 0, ctxDepthMode) );
    1321   }
    1322 }
    1323 #endif
    13241257#endif
    13251258
  • branches/HTM-10.1-dev0/source/Lib/TLibEncoder/TEncSbac.h

    r877 r878  
    257257  ContextModel3DBuffer m_cDdcFlagSCModel;
    258258  ContextModel3DBuffer m_cDdcDataSCModel;
    259 #if QC_GENERIC_SDC_G0122
    260259  ContextModel3DBuffer m_cAngleFlagSCModel;
    261 #endif
    262260#if H_3D_DIM_DMM
    263261  ContextModel3DBuffer m_cDmm1DataSCModel;
  • branches/HTM-10.1-dev0/source/Lib/TLibEncoder/TEncSearch.cpp

    r877 r878  
    18621862#if H_3D_DIM_SDC
    18631863Void TEncSearch::xIntraCodingSDC( TComDataCU* pcCU, UInt uiAbsPartIdx, TComYuv* pcOrgYuv, TComYuv* pcPredYuv, Dist& ruiDist, Double& dRDCost,
    1864 #if QC_GENERIC_SDC_G0122
    18651864  Bool bZeroResidual, Int iSDCDeltaResi
    1866 #else
    1867   Bool bResidual
    1868 #endif
    18691865  )
    18701866{
     
    18741870#if QC_PKU_SDC_SPLIT_G0123
    18751871#if HS_TSINGHUA_SDC_SPLIT_G0111
    1876 #if QC_GENERIC_SDC_G0122
    18771872  TComWedgelet* dmm4SegmentationOrg = new TComWedgelet( uiWidth, uiHeight );
    1878 #endif
    18791873#else
    1880 #if QC_GENERIC_SDC_G0122
    1881   TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );
    1882 #endif
    18831874#endif
    18841875#endif
     
    19381929  AOF( pcCU->getSDCAvailable(uiAbsPartIdx) );
    19391930  AOF( pcCU->getSDCFlag(uiAbsPartIdx) );
    1940 #endif
    1941 #if !QC_GENERIC_SDC_G0122
    1942   AOF( uiLumaPredMode == DC_IDX || uiLumaPredMode == PLANAR_IDX || ( getDimType( uiLumaPredMode ) == DMM1_IDX && !isDimDeltaDC( uiLumaPredMode ) ) );
    1943   AOF( uiLumaPredMode == DC_IDX || uiLumaPredMode == PLANAR_IDX || uiWidth < 64  );
    19441931#endif
    19451932 
     
    19561943#endif
    19571944#if !QC_PKU_SDC_SPLIT_G0123
    1958 #if QC_GENERIC_SDC_G0122
    19591945  TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );
    19601946#endif
    1961 #endif
    19621947#if HS_TSINGHUA_SDC_SPLIT_G0111
    1963 #if QC_GENERIC_SDC_G0122
    19641948  TComWedgelet* dmm4Segmentation = new TComWedgelet( uiWidth, uiHeight );
    1965 #endif
    19661949#endif
    19671950  //===== get prediction signal =====
     
    19821965#endif
    19831966    predIntraLumaDepth( pcCU, uiAbsPartIdx, uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight, true
    1984 #if QC_GENERIC_SDC_G0122
    19851967      , dmm4Segmentation
    1986 #endif
    19871968      );
    19881969#if HS_TSINGHUA_SDC_SPLIT_G0111
     
    20532034    uiMaskStride = pcWedgelet->getStride();
    20542035  }
    2055 #if QC_GENERIC_SDC_G0122
    20562036  if( getDimType( uiLumaPredMode ) == DMM4_IDX )
    20572037  {
     
    20652045#endif
    20662046  }
    2067 #endif
    20682047 
    20692048  // get DC prediction for each segment
     
    20782057  {
    20792058    // remap reconstructed value to valid depth values
    2080 #if QC_GENERIC_SDC_G0122
    20812059    Pel pDCRec = ( !bZeroResidual ) ? apDCOrigValues[uiSegment] : apDCPredValues[uiSegment];
    2082 #else
    2083     Pel pDCRec = bResidual?apDCOrigValues[uiSegment]:apDCPredValues[uiSegment];
    2084 #endif
    20852060    // get residual (idx)
    20862061#if H_3D_DIM_DLT
     
    20892064    Pel pResidualIdx = pDCRec - apDCPredValues[uiSegment];
    20902065#endif
    2091 #if QC_GENERIC_SDC_G0122
    20922066    if( !bZeroResidual )
    20932067    {
     
    20992073      }
    21002074    }
    2101 #endif
    21022075    // save SDC DC offset
    21032076    pcCU->setSDCSegmentDCOffset(pResidualIdx, uiSegment, uiAbsPartIdx);
     
    22032176#endif
    22042177    dRDCost = m_pcRdCost->calcRdCost( uiBits, ruiDist );
    2205 #if QC_GENERIC_SDC_G0122
    22062178#if HS_TSINGHUA_SDC_SPLIT_G0111
    22072179  dmm4SegmentationOrg->destroy(); delete dmm4SegmentationOrg;
    22082180#else
    22092181  dmm4Segmentation->destroy(); delete dmm4Segmentation;
    2210 #endif
    22112182#endif
    22122183}
     
    30753046          case( DMM4_IDX ):
    30763047            {
    3077 #if !QC_GENERIC_SDC_G0122
    3078               if( uiWidth > 4 )
    3079 #endif
    30803048              {
    30813049                biSegmentation = new TComWedgelet( uiWidth, uiHeight );
     
    31333101      {
    31343102        pcCU->setSDCFlagSubParts( (uiSDC != 0), uiPartOffset, uiDepth + uiInitTrDepth );
    3135 #if QC_GENERIC_SDC_G0122
    31363103        for( Int iSDCDeltaResi = -2; iSDCDeltaResi <= 2; iSDCDeltaResi++ )
    31373104        {
     
    31403107            continue;
    31413108          }
    3142 #endif
    31433109#endif
    31443110     
     
    31513117      bTestZeroResi |= pcCU->getSDCFlag(uiPartOffset);
    31523118#endif
    3153 #if QC_GENERIC_SDC_G0122
    31543119      if( uiSDC != 0 && iSDCDeltaResi != 0 )
    31553120      {
    31563121        bTestZeroResi = false;
    31573122      }
    3158 #endif
    31593123#endif
    31603124     
     
    31873151
    31883152          // start encoding with SDC
    3189 #if QC_GENERIC_SDC_G0122
    31903153          xIntraCodingSDC(pcCU, uiPartOffset, pcOrgYuv, pcPredYuv, uiPUDistY, dPUCost, ( testZeroResi != 0 ), iSDCDeltaResi );
    3191 #else
    3192           xIntraCodingSDC(pcCU, uiPartOffset, pcOrgYuv, pcPredYuv, uiPUDistY, dPUCost, (testZeroResi!=0));
    3193 #endif
    31943154        }
    31953155        else
     
    32643224#if H_3D_DIM_ENC || H_3D_DIM_SDC
    32653225      }
    3266 #endif
    3267 #if QC_GENERIC_SDC_G0122
    32683226        } // SDC residual loop
    32693227#endif
  • branches/HTM-10.1-dev0/source/Lib/TLibEncoder/TEncSearch.h

    r877 r878  
    353353#endif
    354354#if H_3D_DIM_SDC
    355   Void xIntraCodingSDC            ( TComDataCU* pcCU, UInt uiAbsPartIdx, TComYuv* pcOrgYuv, TComYuv* pcPredYuv, Dist& ruiDist, Double& dRDCost,
    356 #if QC_GENERIC_SDC_G0122
    357     Bool bZeroResidual, Int iSDCDeltaResi
    358 #else
    359     Bool bResidual
    360 #endif
    361     );
     355  Void xIntraCodingSDC            ( TComDataCU* pcCU, UInt uiAbsPartIdx, TComYuv* pcOrgYuv, TComYuv* pcPredYuv, Dist& ruiDist, Double& dRDCost, Bool bZeroResidual, Int iSDCDeltaResi    );
    362356#endif
    363357#endif
Note: See TracChangeset for help on using the changeset viewer.