Changeset 1235 in SHVCSoftware for branches/SHM-dev/source/App


Ignore:
Timestamp:
13 Jul 2015, 20:38:11 (9 years ago)
Author:
seregin
Message:

port rev 4219 and rev 4246

Location:
branches/SHM-dev/source/App
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.cpp

    r1221 r1235  
    407407    streamYUV.close();
    408408  }
    409   pcBLPic.destroy();
    410409
    411410#if CONFORMANCE_BITSTREAM_MODE
     
    705704  Int numPicsNotYetDisplayed = 0;
    706705  Int dpbFullness = 0;
    707 #if SVC_EXTENSION
    708 TComSPS* activeSPS = m_acTDecTop[layerId].getActiveSPS();
    709 #else
    710   TComSPS* activeSPS = m_cTDecTop.getActiveSPS();
    711 #endif
     706  const TComSPS* activeSPS = &(pcListPic->front()->getPicSym()->getSPS());
    712707  UInt numReorderPicsHighestTid;
    713708  UInt maxDecPicBufferingHighestTid;
     
    781776        {
    782777          const Window &conf = pcPicTop->getConformanceWindow();
    783           const Window &defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
     778          const Window  defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
    784779          const Bool isTff = pcPicTop->isTopField();
    785780
     
    815810        {
    816811          const Window &conf = pcPicTop->getConformanceWindow();
    817           const Window &defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
     812          const Window  defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
    818813          const Bool isTff = pcPicTop->isTopField();
    819814
     
    906901        {
    907902          const Window &conf = pcPic->getConformanceWindow();
    908           const Window &defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();         
     903          const Window  defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();         
    909904
    910905          UInt chromaFormatIdc = pcPic->getSlice(0)->getChromaFormatIdc();
     
    924919        {
    925920          const Window &conf    = pcPic->getConformanceWindow();
    926           const Window &defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();
     921          const Window  defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();
    927922
    928923          m_cTVideoIOYuvReconFile.write( pcPic->getPicYuvRec(),
     
    10341029        {
    10351030          const Window &conf = pcPicTop->getConformanceWindow();
    1036           const Window &defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
     1031          const Window  defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
    10371032          const Bool isTff = pcPicTop->isTopField();         
    10381033
     
    10531048        {
    10541049          const Window &conf = pcPicTop->getConformanceWindow();
    1055           const Window &defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
     1050          const Window  defDisp = m_respectDefDispWindow ? pcPicTop->getDefDisplayWindow() : Window();
    10561051          const Bool isTff = pcPicTop->isTopField();
    10571052          m_cTVideoIOYuvReconFile.write( pcPicTop->getPicYuvRec(), pcPicBottom->getPicYuvRec(),
     
    11311126        {
    11321127          const Window &conf = pcPic->getConformanceWindow();
    1133           const Window &defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();         
     1128          const Window  defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();         
    11341129
    11351130          UInt chromaFormatIdc = pcPic->getSlice(0)->getChromaFormatIdc();
     
    11491144        {
    11501145          const Window &conf    = pcPic->getConformanceWindow();
    1151           const Window &defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();
     1146          const Window  defDisp = m_respectDefDispWindow ? pcPic->getDefDisplayWindow() : Window();
    11521147
    11531148          m_cTVideoIOYuvReconFile.write( pcPic->getPicYuvRec(),
     
    16131608}
    16141609
    1615 TComVPS *TAppDecTop::findDpbParametersFromVps(std::vector<Int> const &listOfPocs, std::vector<Int> const *listOfPocsInEachLayer, std::vector<Int> const *listOfPocsPositionInEachLayer, DpbStatus &maxDpbLimit)
     1610const TComVPS *TAppDecTop::findDpbParametersFromVps(std::vector<Int> const &listOfPocs, std::vector<Int> const *listOfPocsInEachLayer, std::vector<Int> const *listOfPocsPositionInEachLayer, DpbStatus &maxDpbLimit)
    16161611{
    16171612  Int targetOutputLsIdx = getCommonDecoderParams()->getTargetOutputLayerSetIdx();
    1618   TComVPS *vps = NULL;
     1613  const TComVPS *vps = NULL;
    16191614
    16201615  if( targetOutputLsIdx == 0 )   // Only base layer is output
    16211616  {
    1622     TComSPS *sps = NULL;
     1617    const TComSPS *sps = NULL;
    16231618    assert( listOfPocsInEachLayer[0].size() != 0 );
    16241619    TComList<TComPic*>::iterator iterPic;
     
    17041699    {
    17051700      TComPic *pic = *iterPic;
     1701
     1702      assert( pic->getPicSym() );
     1703
    17061704      if( !pic->getSlice(0)->isReferenced() && !pic->getOutputMark() )
    17071705      {
     
    17431741                            )
    17441742{
    1745   TComVPS *vps = NULL;
     1743  const TComVPS *vps = NULL;
    17461744  dpbStatus.init();
    17471745
  • branches/SHM-dev/source/App/TAppDecoder/TAppDecTop.h

    r1221 r1235  
    125125  Void markAllPicturesAsErased();
    126126  Void markAllPicturesAsErased(Int layerIdx);
    127   TComVPS* findDpbParametersFromVps(std::vector<Int> const &listOfPocs, std::vector<Int> const *listOfPocsInEachLayer, std::vector<Int> const *listOfPocsPositionInEachLayer, DpbStatus &maxDpbLimit);
     127  const TComVPS* findDpbParametersFromVps(std::vector<Int> const &listOfPocs, std::vector<Int> const *listOfPocsInEachLayer, std::vector<Int> const *listOfPocsPositionInEachLayer, DpbStatus &maxDpbLimit);
    128128#endif
    129129};
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp

    r1233 r1235  
    750750  Int*    cfg_conformanceMode  [MAX_LAYERS];
    751751  Bool*   cfg_useExtendedPrecision [MAX_LAYERS];
    752 #if LAYER_CTB
     752
     753  Int*    cfg_maxCuDQPDepth[MAX_LAYERS];
     754
    753755  // coding unit (CU) definition
    754   UInt*      cfg_uiMaxCUWidth[MAX_LAYERS];                                   ///< max. CU width in pixel
    755   UInt*      cfg_uiMaxCUHeight[MAX_LAYERS];                                  ///< max. CU height in pixel
    756   UInt*      cfg_uiMaxCUDepth[MAX_LAYERS];                                   ///< max. CU depth
     756  UInt*   cfg_uiMaxCUWidth[MAX_LAYERS];                                   ///< max. CU width in pixel
     757  UInt*   cfg_uiMaxCUHeight[MAX_LAYERS];                                  ///< max. CU height in pixel
     758  UInt*   cfg_uiMaxCUDepth[MAX_LAYERS];                                   ///< max. CU depth
     759
     760  // transfom unit (TU) definition
     761  UInt*   cfg_uiQuadtreeTULog2MaxSize[MAX_LAYERS];
     762  UInt*   cfg_uiQuadtreeTULog2MinSize[MAX_LAYERS];
    757763 
    758   // transfom unit (TU) definition
    759   UInt*      cfg_uiQuadtreeTULog2MaxSize[MAX_LAYERS];
    760   UInt*      cfg_uiQuadtreeTULog2MinSize[MAX_LAYERS];
    761  
    762   UInt*      cfg_uiQuadtreeTUMaxDepthInter[MAX_LAYERS];
    763   UInt*      cfg_uiQuadtreeTUMaxDepthIntra[MAX_LAYERS];
    764 #endif
     764  UInt*   cfg_uiQuadtreeTUMaxDepthInter[MAX_LAYERS];
     765  UInt*   cfg_uiQuadtreeTUMaxDepthIntra[MAX_LAYERS];
     766
    765767#if AUXILIARY_PICTURES
    766768  Int*    cfg_auxId[MAX_LAYERS];
     
    860862    cfg_aiPadY[layer]               = &m_acLayerCfg[layer].m_aiPad[1];
    861863    cfg_useExtendedPrecision[layer] = &m_acLayerCfg[layer].m_useExtendedPrecision;
    862 #if LAYER_CTB
     864
     865    cfg_maxCuDQPDepth[layer]        = &m_acLayerCfg[layer].m_iMaxCuDQPDepth;
     866
    863867    // coding unit (CU) definition
    864868    cfg_uiMaxCUWidth[layer]  = &m_acLayerCfg[layer].m_uiMaxCUWidth;
     
    872876    cfg_uiQuadtreeTUMaxDepthInter[layer] = &m_acLayerCfg[layer].m_uiQuadtreeTUMaxDepthInter;
    873877    cfg_uiQuadtreeTUMaxDepthIntra[layer] = &m_acLayerCfg[layer].m_uiQuadtreeTUMaxDepthIntra;
    874 #endif
    875878
    876879    cfg_numSamplePredRefLayers  [layer] = &m_acLayerCfg[layer].m_numSamplePredRefLayers;
     
    12011204  ("LayerPTLIndex%d",                                 cfg_layerPTLIdx,               0, MAX_VPS_LAYER_IDX_PLUS1, "Index of PTL for each layer")
    12021205  ("ListOfProfileTierLevelOls%d",                     cfg_listOfLayerPTLOfOlss, string(""), MAX_VPS_OUTPUT_LAYER_SETS_PLUS1, "PTL Index for each layer in each OLS except the first OLS. The PTL index for layer in the first OLS is set to 1")
     1206
     1207  // Unit definition parameters
     1208  ("MaxCUWidth%d",                                    cfg_uiMaxCUWidth,                       64u, MAX_LAYERS, "Maximum CU width")
     1209  ("MaxCUHeight%d",                                   cfg_uiMaxCUHeight,                      64u, MAX_LAYERS, "Maximum CU height")
     1210  // todo: remove defaults from MaxCUSize
     1211  ("MaxCUSize%d,s",                                   cfg_uiMaxCUWidth,                       64u, MAX_LAYERS, "Maximum CU size")
     1212  ("MaxCUSize%d,s",                                   cfg_uiMaxCUHeight,                      64u, MAX_LAYERS, "Maximum CU size")
     1213  ("MaxPartitionDepth%d,h%d",                         cfg_uiMaxCUDepth,                        4u, MAX_LAYERS, "CU depth")
     1214
     1215  ("QuadtreeTULog2MaxSize%d",                         cfg_uiQuadtreeTULog2MaxSize,             5u, MAX_LAYERS, "Maximum TU size in logarithm base 2")
     1216  ("QuadtreeTULog2MinSize%d",                         cfg_uiQuadtreeTULog2MinSize,             2u, MAX_LAYERS, "Minimum TU size in logarithm base 2")
     1217                                                                                               
     1218  ("QuadtreeTUMaxDepthIntra%d",                       cfg_uiQuadtreeTUMaxDepthIntra,           3u, MAX_LAYERS, "Depth of TU tree for intra CUs")
     1219  ("QuadtreeTUMaxDepthInter%d",                       cfg_uiQuadtreeTUMaxDepthInter,           3u, MAX_LAYERS, "Depth of TU tree for inter CUs")
    12031220#else
    12041221  ("Profile",                                         extendedProfile,                                   NONE, "Profile name to use for encoding. Use main (for main), main10 (for main10), main-still-picture, main-RExt (for Range Extensions profile), any of the RExt specific profile names, or none")
     
    12141231  ("NonPackedSource",                                 m_nonPackedConstraintFlag,                        false, "Indicate that source does not contain frame packing")
    12151232  ("FrameOnly",                                       m_frameOnlyConstraintFlag,                        false, "Indicate that the bitstream contains only frames")
    1216 #endif
    1217 
    1218 #if LAYER_CTB
    1219   // Unit definition parameters
    1220   ("MaxCUWidth%d",                                    cfg_uiMaxCUWidth,             64u, MAX_LAYERS, "Maximum CU width")
    1221   ("MaxCUHeight%d",                                   cfg_uiMaxCUHeight,            64u, MAX_LAYERS, "Maximum CU height")
    1222   // todo: remove defaults from MaxCUSize
    1223   ("MaxCUSize%d,s%d",                                 cfg_uiMaxCUWidth,             64u, MAX_LAYERS, "Maximum CU size")
    1224   ("MaxCUSize%d,s%d",                                 cfg_uiMaxCUHeight,            64u, MAX_LAYERS, "Maximum CU size")
    1225   ("MaxPartitionDepth%d,h%d",                         cfg_uiMaxCUDepth,              4u, MAX_LAYERS, "CU depth")
    1226  
    1227   ("QuadtreeTULog2MaxSize%d",                         cfg_uiQuadtreeTULog2MaxSize,   6u, MAX_LAYERS, "Maximum TU size in logarithm base 2")
    1228   ("QuadtreeTULog2MinSize%d",                         cfg_uiQuadtreeTULog2MinSize,   2u, MAX_LAYERS, "Minimum TU size in logarithm base 2")
    1229  
    1230   ("QuadtreeTUMaxDepthIntra%d",                       cfg_uiQuadtreeTUMaxDepthIntra, 1u, MAX_LAYERS, "Depth of TU tree for intra CUs")
    1231   ("QuadtreeTUMaxDepthInter%d",                       cfg_uiQuadtreeTUMaxDepthInter, 2u, MAX_LAYERS, "Depth of TU tree for inter CUs")
    1232 
    1233 
    1234   // set the same CU realted settings across all the layers if config file parameters are not layer specific
    1235   ("MaxCUWidth",                                      cfg_uiMaxCUWidth,             64u, MAX_LAYERS, "Maximum CU width")
    1236   ("MaxCUHeight",                                     cfg_uiMaxCUHeight,            64u, MAX_LAYERS, "Maximum CU height")
    1237   // todo: remove defaults from MaxCUSize
    1238   ("MaxCUSize,s",                                     cfg_uiMaxCUWidth,             64u, MAX_LAYERS, "Maximum CU size")
    1239   ("MaxCUSize,s",                                     cfg_uiMaxCUHeight,            64u, MAX_LAYERS, "Maximum CU size")
    1240   ("MaxPartitionDepth,h",                             cfg_uiMaxCUDepth,              4u, MAX_LAYERS, "CU depth")
    1241  
    1242   ("QuadtreeTULog2MaxSize",                           cfg_uiQuadtreeTULog2MaxSize,   6u, MAX_LAYERS, "Maximum TU size in logarithm base 2")
    1243   ("QuadtreeTULog2MinSize",                           cfg_uiQuadtreeTULog2MinSize,   2u, MAX_LAYERS, "Minimum TU size in logarithm base 2")
    1244  
    1245   ("QuadtreeTUMaxDepthIntra",                         cfg_uiQuadtreeTUMaxDepthIntra, 1u, MAX_LAYERS, "Depth of TU tree for intra CUs")
    1246   ("QuadtreeTUMaxDepthInter",                         cfg_uiQuadtreeTUMaxDepthInter, 2u, MAX_LAYERS, "Depth of TU tree for inter CUs")
    1247 #else
     1233
    12481234  // Unit definition parameters
    12491235  ("MaxCUWidth",                                      m_uiMaxCUWidth,                                     64u)
     
    13031289  ("DeltaQpRD,-dqr",                                  m_uiDeltaQpRD,                                       0u, "max dQp offset for slice")
    13041290  ("MaxDeltaQP,d",                                    m_iMaxDeltaQP,                                        0, "max dQp offset for block")
     1291#if SVC_EXTENSION
     1292  ("MaxCuDQPDepth%d,-dqd",                            cfg_maxCuDQPDepth,                        0, MAX_LAYERS, "max depth for a minimum CuDQP")
     1293#else
    13051294  ("MaxCuDQPDepth,-dqd",                              m_iMaxCuDQPDepth,                                     0, "max depth for a minimum CuDQP")
     1295#endif
    13061296  ("MaxCUChromaQpAdjustmentDepth",                    m_maxCUChromaQpAdjustmentDepth,                      -1, "Maximum depth for CU chroma Qp adjustment - set less than 0 to disable")
    13071297
     
    17321722  m_pchdQPFile = cfg_dQPFile.empty() ? NULL : strdup(cfg_dQPFile.c_str());
    17331723#if Q0074_COLOUR_REMAPPING_SEI
    1734   m_colourRemapSEIFileRoot = cfg_colourRemapSEIFileRoot.empty() ? NULL : strdup(cfg_colourRemapSEIFileRoot.c_str());
     1724  if( !cfg_colourRemapSEIFileRoot.empty() )
     1725  {
     1726    m_colourRemapSEIFileRoot = strdup(cfg_colourRemapSEIFileRoot.c_str());
     1727  }
    17351728#endif
    17361729#endif //SVC_EXTENSION
     
    25942587      fclose(fpt);
    25952588    }
    2596   }
    2597   m_iWaveFrontSubstreams = m_iWaveFrontSynchro ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1;
    2598 #endif
     2589  } 
     2590#endif
     2591
    25992592  if( m_masteringDisplay.colourVolumeSEIEnabled )
    26002593  {
     
    28142807
    28152808  // set global varibles
    2816 #if LAYER_CTB
    2817   for(Int layer = 0; layer < MAX_LAYERS; layer++)
     2809#if SVC_EXTENSION
     2810  for(Int layer = 0; layer < m_numLayers; layer++)
    28182811  {
    28192812    xSetGlobal(layer);
     
    31003093  xConfirmPara( m_bipredSearchRange < 0 ,                                                   "Search Range must be more than 0" );
    31013094  xConfirmPara( m_iMaxDeltaQP > 7,                                                          "Absolute Delta QP exceeds supported range (0 to 7)" );
    3102 #if LAYER_CTB
    3103   for(UInt layer = 0; layer < MAX_LAYERS; layer++)
    3104   {
    3105     xConfirmPara( m_iMaxCuDQPDepth > m_acLayerCfg[layer].m_uiMaxCUDepth - 1,                "Absolute depth for a minimum CuDQP exceeds maximum coding unit depth" );
    3106   }
    3107 #else
     3095#if !SVC_EXTENSION 
    31083096  xConfirmPara( m_iMaxCuDQPDepth > m_uiMaxCUDepth - 1,                                          "Absolute depth for a minimum CuDQP exceeds maximum coding unit depth" );
    31093097#endif
     
    31203108    xConfirmPara( m_iIntraPeriod > 0 && m_iIntraPeriod <= m_iGOPSize ,                      "Intra period must be larger than GOP size for periodic IDR pictures");
    31213109  }
    3122 #endif
    3123 #if !LAYER_CTB
    31243110  xConfirmPara( (m_uiMaxCUWidth  >> m_uiMaxCUDepth) < 4,                                    "Minimum partition width size should be larger than or equal to 8");
    31253111  xConfirmPara( (m_uiMaxCUHeight >> m_uiMaxCUDepth) < 4,                                    "Minimum partition height size should be larger than or equal to 8");
    31263112  xConfirmPara( m_uiMaxCUWidth < 16,                                                        "Maximum partition width size should be larger than or equal to 16");
    31273113  xConfirmPara( m_uiMaxCUHeight < 16,                                                       "Maximum partition height size should be larger than or equal to 16");
    3128 #endif
    3129 #if !SVC_EXTENSION
    31303114  xConfirmPara( (m_iSourceWidth  % (m_uiMaxCUWidth  >> (m_uiMaxCUDepth-1)))!=0,             "Resulting coded frame width must be a multiple of the minimum CU size");
    31313115  xConfirmPara( (m_iSourceHeight % (m_uiMaxCUHeight >> (m_uiMaxCUDepth-1)))!=0,             "Resulting coded frame height must be a multiple of the minimum CU size");
    3132 #endif
    3133  
    3134 #if !LAYER_CTB
     3116
    31353117  xConfirmPara( m_uiQuadtreeTULog2MinSize < 2,                                        "QuadtreeTULog2MinSize must be 2 or greater.");
    31363118  xConfirmPara( m_uiQuadtreeTULog2MaxSize > 5,                                        "QuadtreeTULog2MaxSize must be 5 or smaller.");
     
    32053187    xConfirmPara( m_defDispWinBottomOffset % TComSPS::getWinUnitY(m_chromaFormatIDC) != 0, "Bottom default display window offset must be an integer multiple of the specified chroma subsampling");
    32063188  }
    3207 #endif
    3208 
    3209 #if !LAYER_CTB
     3189
    32103190  // max CU width and height should be power of 2
    32113191  UInt ui = m_uiMaxCUWidth;
     
    39253905  Int m_iSourceWidth = m_acLayerCfg[layerIdx].m_iSourceWidth;
    39263906  Int m_iSourceHeight = m_acLayerCfg[layerIdx].m_iSourceHeight;
    3927 #if LAYER_CTB
    39283907  Int m_uiMaxCUWidth = m_acLayerCfg[layerIdx].m_uiMaxCUWidth;
    39293908  Int m_uiMaxCUHeight = m_acLayerCfg[layerIdx].m_uiMaxCUHeight;
    3930 #endif
    39313909
    39323910  Bool tileFlag = (m_numTileColumnsMinus1 > 0 || m_numTileRowsMinus1 > 0 );
     
    40103988#if !SVC_EXTENSION
    40113989  xConfirmPara( m_iWaveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" );
    4012   xConfirmPara( m_iWaveFrontSubstreams <= 0, "WaveFrontSubstreams must be positive" );
    4013   xConfirmPara( m_iWaveFrontSubstreams > 1 && !m_iWaveFrontSynchro, "Must have WaveFrontSynchro > 0 in order to have WaveFrontSubstreams > 1" );
    40143990#endif
    40153991
     
    42324208}
    42334209#else
     4210#if SVC_EXTENSION
     4211Void TAppEncCfg::xSetGlobal(UInt layerId)
     4212#else
    42344213Void TAppEncCfg::xSetGlobal()
     4214#endif
    42354215{
    42364216#if SVC_EXTENSION
     
    42444224
    42454225  // set max CU width & height
     4226#if SVC_EXTENSION
     4227  g_uiMaxCUWidth  = m_acLayerCfg[layerId].m_uiMaxCUWidth;
     4228  g_uiMaxCUHeight = m_acLayerCfg[layerId].m_uiMaxCUHeight;
     4229
     4230  // compute actual CU depth with respect to config depth and max transform size
     4231  g_uiAddCUDepth  = 0;
     4232  while( (m_acLayerCfg[layerId].m_uiMaxCUWidth>>m_acLayerCfg[layerId].m_uiMaxCUDepth) > ( 1 << ( m_acLayerCfg[layerId].m_uiQuadtreeTULog2MinSize + g_uiAddCUDepth )  ) ) g_uiAddCUDepth++;
     4233
     4234  g_uiAddCUDepth+=getMaxCUDepthOffset(m_chromaFormatIDC, m_acLayerCfg[layerId].m_uiQuadtreeTULog2MinSize); // if minimum TU larger than 4x4, allow for additional part indices for 4:2:2 SubTUs.
     4235
     4236  m_acLayerCfg[layerId].m_uiMaxCUDepth += g_uiAddCUDepth;
     4237  g_uiAddCUDepth++;
     4238  g_uiMaxCUDepth = m_acLayerCfg[layerId].m_uiMaxCUDepth;
     4239#else
    42464240  g_uiMaxCUWidth  = m_uiMaxCUWidth;
    42474241  g_uiMaxCUHeight = m_uiMaxCUHeight;
     
    42564250  g_uiAddCUDepth++;
    42574251  g_uiMaxCUDepth = m_uiMaxCUDepth;
     4252#endif
    42584253
    42594254  // set internal bit-depth and constants
     
    43584353    printf("Profile                           : %s\n", profileToString(m_profile) );
    43594354  }
    4360 #endif
    4361 #if !LAYER_CTB
     4355
    43624356  printf("CU size / depth                   : %d / %d\n", m_uiMaxCUWidth, m_uiMaxCUDepth );
    43634357  printf("RQT trans. size (min / max)       : %d / %d\n", 1 << m_uiQuadtreeTULog2MinSize, 1 << m_uiQuadtreeTULog2MaxSize );
     
    43734367#if !SVC_EXTENSION
    43744368  printf("QP                                : %5.2f\n", m_fQP );
    4375 #endif
    43764369  printf("Max dQP signaling depth           : %d\n", m_iMaxCuDQPDepth);
     4370#endif
    43774371
    43784372  printf("Cb QP Offset                      : %d\n", m_cbQpOffset   );
     
    44654459  printf("CIP:%d ", m_bUseConstrainedIntraPred);
    44664460  printf("SAO:%d ", (m_bUseSAO)?(1):(0));
    4467 #if !LAYER_CTB
     4461#if !SVC_EXTENSION
    44684462  printf("PCM:%d ", (m_usePCM && (1<<m_uiPCMLog2MinSize) <= m_uiMaxCUWidth)? 1 : 0);
    44694463#endif
     
    44824476  printf("PME:%d ", m_log2ParallelMergeLevel);
    44834477#if !SVC_EXTENSION
     4478  const Int iWaveFrontSubstreams = m_iWaveFrontSynchro ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1;
    44844479  printf(" WaveFrontSynchro:%d WaveFrontSubstreams:%d",
    4485           m_iWaveFrontSynchro, m_iWaveFrontSubstreams);
     4480          m_iWaveFrontSynchro, iWaveFrontSubstreams);
    44864481#endif
    44874482  printf(" ScalingList:%d ", m_useScalingListId );
     
    44974492  printf("REF_IDX_ME_ZEROMV: %d ", REF_IDX_ME_ZEROMV);
    44984493  printf("ENCODER_FAST_MODE: %d ", ENCODER_FAST_MODE);
     4494#if CGS_3D_ASYMLUT
     4495  printf("CGS: %d CGSMaxOctantDepth: %d CGSMaxYPartNumLog2: %d CGSLUTBit:%d ", m_nCGSFlag, m_nCGSMaxOctantDepth, m_nCGSMaxYPartNumLog2, m_nCGSLUTBit );
     4496  printf("CGSAdaptC:%d ", m_nCGSAdaptiveChroma );
     4497#if R0179_ENC_OPT_3DLUT_SIZE
     4498  printf("CGSSizeRDO:%d ", m_nCGSLutSizeRDO );
     4499#endif
     4500#endif
    44994501#else
    45004502  printf("RecalQP:%d", m_recalculateQPAccordingToLambda ? 1 : 0 );
    4501 #endif
    4502 #if CGS_3D_ASYMLUT
    4503   printf("CGS: %d CGSMaxOctantDepth: %d CGSMaxYPartNumLog2: %d CGSLUTBit:%d " , m_nCGSFlag , m_nCGSMaxOctantDepth , m_nCGSMaxYPartNumLog2 , m_nCGSLUTBit );
    4504 #endif
    4505   printf("CGSAdaptC:%d " , m_nCGSAdaptiveChroma );
    4506 #if R0179_ENC_OPT_3DLUT_SIZE
    4507   printf("CGSSizeRDO:%d " , m_nCGSLutSizeRDO );
    45084503#endif
    45094504
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h

    r1230 r1235  
    193193  Int       m_iMaxDeltaQP;                                    ///< max. |delta QP|
    194194  UInt      m_uiDeltaQpRD;                                    ///< dQP range for multi-pass slice QP optimization
     195#if !SVC_EXTENSION
    195196  Int       m_iMaxCuDQPDepth;                                 ///< Max. depth for a minimum CuDQPSize (0:default)
     197#endif
    196198  Int       m_maxCUChromaQpAdjustmentDepth;
    197199
     
    209211  Int       m_maxTempLayer;                                  ///< Max temporal layer
    210212
    211 #if !LAYER_CTB
    212213  // coding unit (CU) definition
    213214  // TODO: Remove MaxCUWidth/MaxCUHeight and replace with MaxCUSize.
     215#if !SVC_EXTENSION
    214216  UInt      m_uiMaxCUWidth;                                   ///< max. CU width in pixel
    215217  UInt      m_uiMaxCUHeight;                                  ///< max. CU height in pixel
     
    287289  std::vector<Int> m_tileColumnWidth;
    288290  std::vector<Int> m_tileRowHeight;
     291
    289292#if !SVC_EXTENSION
    290293  Int       m_iWaveFrontSynchro; //< 0: no WPP. >= 1: WPP is enabled, the "Top right" from which inheritance occurs is this LCU offset in the line above the current.
    291   Int       m_iWaveFrontFlush; //< enable(1)/disable(0) the CABAC flush at the end of each line of LCUs.
    292   Int       m_iWaveFrontSubstreams; //< If iWaveFrontSynchro, this is the number of substreams per frame (dependent tiles) or per tile (independent tiles).
    293 #endif
     294#endif
     295
    294296  Bool      m_bUseConstrainedIntraPred;                       ///< flag for using constrained intra prediction
    295297
     
    453455#endif
    454456  // internal member functions
    455 #if LAYER_CTB
     457#if SVC_EXTENSION
    456458  Void  xSetGlobal      (UInt layerId);                       ///< set global variables
     459  Void  xCheckParameter (UInt layerIdx);                       ///< check validity of configuration values per layer
    457460#else
    458461  Void  xSetGlobal      ();                                   ///< set global variables
    459 #endif
    460 #if SVC_EXTENSION
    461   Void  xCheckParameter (UInt layerIdx);                       ///< check validity of configuration values per layer
    462 #else
    463462  Void  xCheckParameter ();                                   ///< check validity of configuration values
    464463#endif
     
    527526 
    528527#if SVC_EXTENSION
    529   Int  getNumFrameToBeEncoded()    {return m_framesToBeEncoded; }
    530   Int  getNumLayer()               {return m_numLayers;         }
    531   Int  getGOPSize()                {return m_iGOPSize;          }
    532 
    533   UInt getInternalBitDepth(Int iLayer, ChannelType type)      {return m_acLayerCfg[iLayer].m_internalBitDepth[type]; }
    534   Bool getPCMInputBitDepthFlag()                              {return m_bPCMInputBitDepthFlag;                       }
    535 
    536 #if !LAYER_CTB
    537   UInt getMaxCUWidth()             {return m_uiMaxCUWidth;      }
    538   UInt getMaxCUHeight()            {return m_uiMaxCUHeight;     }
    539   UInt getMaxCUDepth()             {return m_uiMaxCUDepth;      }
    540 #endif
    541   Int  getDecodingRefreshType()    {return m_iDecodingRefreshType; }
    542   Int  getWaveFrontSynchro(Int layerIdx)        { return m_acLayerCfg[layerIdx].m_waveFrontSynchro; }
     528  Int  getNumFrameToBeEncoded()                               { return m_framesToBeEncoded;                          }
     529  Int  getNumLayer()                                          { return m_numLayers;                                  }
     530  Int  getGOPSize()                                           { return m_iGOPSize;                                   }
     531
     532  RepFormatCfg* getRepFormatCfg(Int i)                        { return &m_repFormatCfg[i];                           }
     533  Bool getUsePCM()                                            { return m_usePCM;                                     }
     534  UInt getPCMLog2MinSize  ()                                  { return  m_uiPCMLog2MinSize;                          }
     535
     536  UInt getInternalBitDepth(Int iLayer, ChannelType type)      { return m_acLayerCfg[iLayer].m_internalBitDepth[type];}
     537  Bool getPCMInputBitDepthFlag()                              { return m_bPCMInputBitDepthFlag;                      }
     538
     539  Int  getDecodingRefreshType()                               { return m_iDecodingRefreshType;                       }
     540  Int  getWaveFrontSynchro(Int layerIdx)                      { return m_acLayerCfg[layerIdx].m_waveFrontSynchro;    }
    543541  Void getDirFilename(string& filename, string& dir, const string path);
    544542
     
    549547  Bool scanStringToArrayNumEntries(string const cfgString, Int &numEntries, const char* logString, std::vector<Int> &  returnVector);
    550548  Void cfgStringToArrayNumEntries(Int **arr, string const cfgString, Int &numEntries, const char* logString);
    551 
    552   RepFormatCfg* getRepFormatCfg(Int i)  { return &m_repFormatCfg[i]; }
    553 #if LAYER_CTB
    554   Bool getUsePCM()                  { return m_usePCM;               }
    555   UInt getPCMLog2MinSize  ()        { return  m_uiPCMLog2MinSize;    }
    556 #endif
    557549#endif
    558550};// END CLASS DEFINITION TAppEncCfg
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncLayerCfg.cpp

    r1203 r1235  
    184184#endif
    185185#if Q0074_COLOUR_REMAPPING_SEI
    186   m_colourRemapSEIFileRoot = cfg_colourRemapSEIFileRoot.empty() ? NULL : strdup(cfg_colourRemapSEIFileRoot.c_str());
     186  if( !cfg_colourRemapSEIFileRoot.empty() )
     187  {
     188    m_colourRemapSEIFileRoot = strdup(cfg_colourRemapSEIFileRoot.c_str());
     189  }
    187190#endif
    188191
     
    212215  printf("Input File                        : %s\n", m_cInputFile.c_str()  );
    213216  printf("Reconstruction File               : %s\n", m_cReconFile.c_str()  );
    214 #if SVC_EXTENSION
    215217  printf("Real     Format                   : %dx%d %dHz\n", m_iSourceWidth - ( m_confWinLeft + m_confWinRight ) * TComSPS::getWinUnitX( m_chromaFormatIDC ), m_iSourceHeight - ( m_confWinTop + m_confWinBottom ) * TComSPS::getWinUnitY( m_chromaFormatIDC ), m_iFrameRate );
    216 #else
    217   printf("Real     Format                   : %dx%d %dHz\n", m_iSourceWidth - m_confWinLeft - m_confWinRight, m_iSourceHeight - m_confWinTop - m_confWinBottom, m_iFrameRate );
    218 #endif
    219218  printf("Internal Format                   : %dx%d %dHz\n", m_iSourceWidth, m_iSourceHeight, m_iFrameRate );
    220219  printf("PTL index                         : %d\n", m_layerPTLIdx );
    221 #if SVC_EXTENSION
    222220  printf("Input bit depth                   : (Y:%d, C:%d)\n", m_inputBitDepth[CHANNEL_TYPE_LUMA], m_inputBitDepth[CHANNEL_TYPE_CHROMA] );
    223221  printf("Internal bit depth                : (Y:%d, C:%d)\n", m_internalBitDepth[CHANNEL_TYPE_LUMA], m_internalBitDepth[CHANNEL_TYPE_CHROMA] );
    224222  printf("PCM sample bit depth              : (Y:%d, C:%d)\n", m_cAppEncCfg->getPCMInputBitDepthFlag() ? m_inputBitDepth[CHANNEL_TYPE_LUMA] : m_internalBitDepth[CHANNEL_TYPE_LUMA], m_cAppEncCfg->getPCMInputBitDepthFlag() ? m_inputBitDepth[CHANNEL_TYPE_CHROMA] : m_internalBitDepth[CHANNEL_TYPE_CHROMA] );
    225 #endif
    226223  std::cout << "Input ChromaFormatIDC             :";
    227224
     
    250247  }
    251248  printf("\n");
    252 #if LAYER_CTB
    253249  printf("CU size / depth                   : %d / %d\n", m_uiMaxCUWidth, m_uiMaxCUDepth );
    254250  printf("RQT trans. size (min / max)       : %d / %d\n", 1 << m_uiQuadtreeTULog2MinSize, 1 << m_uiQuadtreeTULog2MaxSize );
    255251  printf("Max RQT depth inter               : %d\n", m_uiQuadtreeTUMaxDepthInter);
    256252  printf("Max RQT depth intra               : %d\n", m_uiQuadtreeTUMaxDepthIntra);
    257 #endif
    258253  printf("QP                                : %5.2f\n", m_fQP );
     254  printf("Max dQP signaling depth           : %d\n", m_iMaxCuDQPDepth);
    259255  printf("Intra period                      : %d\n", m_iIntraPeriod );
    260256#if RC_SHVC_HARMONIZATION                   
     
    271267#endif
    272268  printf("WaveFrontSynchro                  : %d\n", m_waveFrontSynchro);
    273   printf("WaveFrontSubstreams               : %d\n", m_iWaveFrontSubstreams);
    274 #if LAYER_CTB
     269
     270  const Int iWaveFrontSubstreams = m_waveFrontSynchro ? (m_iSourceHeight + m_uiMaxCUHeight - 1) / m_uiMaxCUHeight : 1;
     271  printf("WaveFrontSubstreams               : %d\n", iWaveFrontSubstreams);
    275272  printf("PCM                               : %d ", (m_cAppEncCfg->getUsePCM() && (1<<m_cAppEncCfg->getPCMLog2MinSize()) <= m_uiMaxCUWidth)? 1 : 0);
    276 #endif
    277273}
    278274
     
    303299
    304300      // automatic padding to minimum CU size
    305 #if LAYER_CTB
    306301      Int minCuSize = m_uiMaxCUHeight >> (m_uiMaxCUDepth - 1);
    307 #else
    308       Int minCuSize = m_cAppEncCfg->getMaxCUHeight() >> (m_cAppEncCfg->getMaxCUDepth() - 1);
    309 #endif
     302
    310303      if (m_iSourceWidth % minCuSize)
    311304      {
    312305        m_aiPad[0] = m_confWinRight  = ((m_iSourceWidth / minCuSize) + 1) * minCuSize - m_iSourceWidth;
    313306        m_iSourceWidth  += m_confWinRight;
    314 #if SVC_EXTENSION
    315307        m_confWinRight /= TComSPS::getWinUnitX( m_chromaFormatIDC );
    316 #endif
    317308      }
    318309      if (m_iSourceHeight % minCuSize)
     
    325316          m_aiPad[1] = m_confWinBottom << 1;
    326317        }
    327 #if SVC_EXTENSION
    328318        m_confWinBottom /= TComSPS::getWinUnitY( m_chromaFormatIDC );
    329 #endif
    330319      }
    331320      break;
     
    344333      m_confWinRight  = m_aiPad[0];
    345334      m_confWinBottom = m_aiPad[1];
    346 #if SVC_EXTENSION
    347335      m_confWinRight /= TComSPS::getWinUnitX( m_chromaFormatIDC );
    348336      m_confWinBottom /= TComSPS::getWinUnitY( m_chromaFormatIDC );
    349 #endif
    350337      break;
    351338    }
     
    388375  }
    389376
    390 #if LAYER_CTB
    391377  UInt maxCUWidth = m_uiMaxCUWidth;
    392378  UInt maxCUHeight = m_uiMaxCUHeight;
    393379  UInt maxCUDepth = m_uiMaxCUDepth;
    394 #else
    395   UInt maxCUWidth = m_cAppEncCfg->getMaxCUWidth();
    396   UInt maxCUHeight = m_cAppEncCfg->getMaxCUHeight();
    397   UInt maxCUDepth = m_cAppEncCfg->getMaxCUDepth();
    398 #endif
    399380  bool check_failed = false; /* abort if there is a fatal configuration problem */
    400381#define xConfirmPara(a,b) check_failed |= confirmPara(a,b)
     
    409390  }
    410391
    411 #if SVC_EXTENSION
    412392  xConfirmPara( m_iQP <  -6 * (m_internalBitDepth[CHANNEL_TYPE_LUMA] - 8) || m_iQP > 51,                "QP exceeds supported range (-QpBDOffsety to 51)" );
    413 #else
    414   xConfirmPara( m_iQP <  -6 * ((Int)m_cAppEncCfg->getInternalBitDepthY() - 8) || m_iQP > 51,                "QP exceeds supported range (-QpBDOffsety to 51)" );
    415 #endif
    416 
    417   m_iWaveFrontSubstreams = m_waveFrontSynchro ? (m_iSourceHeight + maxCUHeight - 1) / maxCUHeight : 1;
     393
    418394  xConfirmPara( m_waveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" );
    419   xConfirmPara( m_iWaveFrontSubstreams <= 0, "WaveFrontSubstreams must be positive" );
    420   xConfirmPara( m_iWaveFrontSubstreams > 1 && !m_waveFrontSynchro, "Must have WaveFrontSynchro > 0 in order to have WaveFrontSubstreams > 1" );
    421395
    422396  //chekc parameters
     
    427401  xConfirmPara( m_aiPad[1] % TComSPS::getWinUnitY(CHROMA_420) != 0, "Vertical padding must be an integer multiple of the specified chroma subsampling");
    428402
    429 #if !SVC_EXTENSION
    430   xConfirmPara( m_confLeft   % TComSPS::getWinUnitX(CHROMA_420) != 0, "Left conformance window offset must be an integer multiple of the specified chroma subsampling");
    431   xConfirmPara( m_confRight  % TComSPS::getWinUnitX(CHROMA_420) != 0, "Right conformance window offset must be an integer multiple of the specified chroma subsampling");
    432   xConfirmPara( m_confTop    % TComSPS::getWinUnitY(CHROMA_420) != 0, "Top conformance window offset must be an integer multiple of the specified chroma subsampling");
    433   xConfirmPara( m_confBottom % TComSPS::getWinUnitY(CHROMA_420) != 0, "Bottom conformance window offset must be an integer multiple of the specified chroma subsampling");
    434 #endif
    435 
    436 #if LAYER_CTB 
     403  xConfirmPara( m_iMaxCuDQPDepth > m_uiMaxCUDepth - 1,                                          "Absolute depth for a minimum CuDQP exceeds maximum coding unit depth" );
     404
    437405  xConfirmPara( (m_uiMaxCUWidth  >> m_uiMaxCUDepth) < 4,                                    "Minimum partition width size should be larger than or equal to 8");
    438406  xConfirmPara( (m_uiMaxCUHeight >> m_uiMaxCUDepth) < 4,                                    "Minimum partition height size should be larger than or equal to 8");
     
    467435      xConfirmPara( ui != 1 , "Height should be 2^n");
    468436  }
    469 #endif
    470437
    471438#undef xConfirmPara
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncLayerCfg.h

    r1203 r1235  
    6060  Int       m_numActiveRefLayers;
    6161
    62 #if LAYER_CTB
     62  Int       m_iMaxCuDQPDepth;                                 ///< Max. depth for a minimum CuDQPSize (0:default)
     63
    6364  // coding unit (CU) definition
    6465  UInt      m_uiMaxCUWidth;                                   ///< max. CU width in pixel
     
    7273  UInt      m_uiQuadtreeTUMaxDepthInter;
    7374  UInt      m_uiQuadtreeTUMaxDepthIntra;
    74 #endif
    7575
    7676#if RC_SHVC_HARMONIZATION
     
    8686  Int       m_maxTidIlRefPicsPlus1;
    8787  Int       m_waveFrontSynchro;                   ///< 0: no WPP. >= 1: WPP is enabled, the "Top right" from which inheritance occurs is this LCU offset in the line above the current.
    88   Int       m_iWaveFrontSubstreams;               ///< If iWaveFrontSynchro, this is the number of substreams per frame (dependent tiles) or per tile (independent tiles).
    8988
    9089  Int       m_iQP;                                            ///< QP value of key-picture (integer)
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp

    r1226 r1235  
    422422    //====== Quality control ========
    423423    m_acTEncTop[layer].setMaxDeltaQP                                       ( m_iMaxDeltaQP  );
    424     m_acTEncTop[layer].setMaxCuDQPDepth                                    ( m_iMaxCuDQPDepth  );
     424    m_acTEncTop[layer].setMaxCuDQPDepth                                    ( m_acLayerCfg[layer].m_iMaxCuDQPDepth  );
    425425    m_acTEncTop[layer].setMaxCUChromaQpAdjustmentDepth                     ( m_maxCUChromaQpAdjustmentDepth );
    426426    m_acTEncTop[layer].setChromaCbQpOffset                                 ( m_cbQpOffset     );
     
    446446    m_acTEncTop[layer].setUseRDOQTS                                        ( m_useRDOQTS   );
    447447    m_acTEncTop[layer].setRDpenalty                                        ( m_rdPenalty );
    448 #if LAYER_CTB
     448
    449449    m_acTEncTop[layer].setQuadtreeTULog2MaxSize                            ( m_acLayerCfg[layer].m_uiQuadtreeTULog2MaxSize );
    450450    m_acTEncTop[layer].setQuadtreeTULog2MinSize                            ( m_acLayerCfg[layer].m_uiQuadtreeTULog2MinSize );
    451451    m_acTEncTop[layer].setQuadtreeTUMaxDepthInter                          ( m_acLayerCfg[layer].m_uiQuadtreeTUMaxDepthInter );
    452452    m_acTEncTop[layer].setQuadtreeTUMaxDepthIntra                          ( m_acLayerCfg[layer].m_uiQuadtreeTUMaxDepthIntra );
    453 #else
    454     m_acTEncTop[layer].setQuadtreeTULog2MaxSize                            ( m_uiQuadtreeTULog2MaxSize );
    455     m_acTEncTop[layer].setQuadtreeTULog2MinSize                            ( m_uiQuadtreeTULog2MinSize );
    456     m_acTEncTop[layer].setQuadtreeTUMaxDepthInter                          ( m_uiQuadtreeTUMaxDepthInter );
    457     m_acTEncTop[layer].setQuadtreeTUMaxDepthIntra                          ( m_uiQuadtreeTUMaxDepthIntra );
    458 #endif
     453
    459454    m_acTEncTop[layer].setUseFastEnc                                       ( m_bUseFastEnc  );
    460455    m_acTEncTop[layer].setUseEarlyCU                                       ( m_bUseEarlyCU  );
     
    656651    m_acTEncTop[layer].setLFCrossTileBoundaryFlag               ( m_bLFCrossTileBoundaryFlag );
    657652    m_acTEncTop[layer].setWaveFrontSynchro                      ( m_acLayerCfg[layer].m_waveFrontSynchro );
    658     m_acTEncTop[layer].setWaveFrontSubstreams                   ( m_acLayerCfg[layer].m_iWaveFrontSubstreams );
    659653    m_acTEncTop[layer].setTMVPModeId                            ( m_TMVPModeId );
    660654    m_acTEncTop[layer].setUseScalingListId                      ( m_useScalingListId  );
     
    10201014  m_cTEncTop.setLFCrossTileBoundaryFlag                           ( m_bLFCrossTileBoundaryFlag );
    10211015  m_cTEncTop.setWaveFrontSynchro                                  ( m_iWaveFrontSynchro );
    1022   m_cTEncTop.setWaveFrontSubstreams                               ( m_iWaveFrontSubstreams );
    10231016  m_cTEncTop.setTMVPModeId                                        ( m_TMVPModeId );
    10241017  m_cTEncTop.setUseScalingListId                                  ( m_useScalingListId  );
     
    12841277  vps->setAvcBaseLayerFlag(false);
    12851278#endif
     1279 
     1280  for( Int idx = vps->getBaseLayerInternalFlag() ? 2 : 1; idx < vps->getNumProfileTierLevel(); idx++ )
     1281  {
     1282    vps->setProfilePresentFlag(idx, true);
     1283  }
    12861284
    12871285  vps->setSplittingFlag(false);
     
    15361534  }
    15371535
    1538   vps->setCrossLayerPictureTypeAlignFlag( m_crossLayerPictureTypeAlignFlag );
     1536  vps->setCrossLayerPictureTypeAlignFlag( m_crossLayerPictureTypeAlignFlag ); 
    15391537  vps->setCrossLayerAlignedIdrOnlyFlag( m_crossLayerAlignedIdrOnlyFlag );
    15401538  vps->setCrossLayerIrapAlignFlag( m_crossLayerIrapAlignFlag );
     1539
     1540  if( vps->getCrossLayerPictureTypeAlignFlag() )
     1541  {
     1542    // When not present, the value of cross_layer_irap_aligned_flag is inferred to be equal to vps_vui_present_flag,   
     1543    assert( m_crossLayerIrapAlignFlag == true );
     1544    vps->setCrossLayerIrapAlignFlag( true );
     1545  }
     1546
    15411547  for(UInt layerCtr = 1;layerCtr <= vps->getMaxLayers() - 1; layerCtr++)
    15421548  {
     
    15801586      Int iPicWidth         = pcCfgLayer->getSourceWidth();
    15811587      Int iPicHeight        = pcCfgLayer->getSourceHeight();
    1582 #if LAYER_CTB
    1583       UInt uiWidthInCU       = ( iPicWidth  % m_acLayerCfg[layerIdx].m_uiMaxCUWidth  ) ? iPicWidth  / m_acLayerCfg[layerIdx].m_uiMaxCUWidth  + 1 : iPicWidth  / m_acLayerCfg[layerIdx].m_uiMaxCUWidth;
    1584       UInt uiHeightInCU      = ( iPicHeight % m_acLayerCfg[layerIdx].m_uiMaxCUHeight ) ? iPicHeight / m_acLayerCfg[layerIdx].m_uiMaxCUHeight + 1 : iPicHeight / m_acLayerCfg[layerIdx].m_uiMaxCUHeight;
     1588
     1589      UInt uiWidthInCU      = ( iPicWidth  % m_acLayerCfg[layerIdx].m_uiMaxCUWidth  ) ? iPicWidth  / m_acLayerCfg[layerIdx].m_uiMaxCUWidth  + 1 : iPicWidth  / m_acLayerCfg[layerIdx].m_uiMaxCUWidth;
     1590      UInt uiHeightInCU     = ( iPicHeight % m_acLayerCfg[layerIdx].m_uiMaxCUHeight ) ? iPicHeight / m_acLayerCfg[layerIdx].m_uiMaxCUHeight + 1 : iPicHeight / m_acLayerCfg[layerIdx].m_uiMaxCUHeight;
    15851591      UInt maxCU = pcCfgLayer->getSliceArgument() >> ( m_acLayerCfg[layerIdx].m_uiMaxCUDepth << 1);
    1586 #else
    1587       UInt uiWidthInCU       = ( iPicWidth %m_uiMaxCUWidth  ) ? iPicWidth /m_uiMaxCUWidth  + 1 : iPicWidth /m_uiMaxCUWidth;
    1588       UInt uiHeightInCU      = ( iPicHeight%m_uiMaxCUHeight ) ? iPicHeight/m_uiMaxCUHeight + 1 : iPicHeight/m_uiMaxCUHeight;
    1589       UInt maxCU = pcCfgLayer->getSliceArgument() >> ( m_uiMaxCUDepth << 1);
    1590 #endif
     1592
    15911593      UInt uiNumCUsInFrame   = uiWidthInCU * uiHeightInCU;
    15921594
     
    16981700    if( m_isField )
    16991701    {
    1700 #if LAYER_CTB
     1702#if SVC_EXTENSION
    17011703      pcPicYuvOrg[layer]->create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeightOrg(), m_acLayerCfg[layer].getChromaFormatIDC(), m_acLayerCfg[layer].m_uiMaxCUWidth, m_acLayerCfg[layer].m_uiMaxCUHeight, m_acLayerCfg[layer].m_uiMaxCUDepth, NULL );
    17021704      acPicYuvTrueOrg[layer].create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeightOrg(), m_acLayerCfg[layer].getChromaFormatIDC(), m_acLayerCfg[layer].m_uiMaxCUWidth, m_acLayerCfg[layer].m_uiMaxCUHeight, m_acLayerCfg[layer].m_uiMaxCUDepth, NULL );
     
    17081710    else
    17091711    {
    1710 #if LAYER_CTB
     1712#if SVC_EXTENSION
    17111713      pcPicYuvOrg[layer]->create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeight(), m_acLayerCfg[layer].getChromaFormatIDC(), m_acLayerCfg[layer].m_uiMaxCUWidth, m_acLayerCfg[layer].m_uiMaxCUHeight, m_acLayerCfg[layer].m_uiMaxCUDepth, NULL );
    17121714      acPicYuvTrueOrg[layer].create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeight(), m_acLayerCfg[layer].getChromaFormatIDC(), m_acLayerCfg[layer].m_uiMaxCUWidth, m_acLayerCfg[layer].m_uiMaxCUHeight, m_acLayerCfg[layer].m_uiMaxCUDepth, NULL );
     
    21422144  {
    21432145    rpcPicYuvRec = m_acListPicYuvRec[layer].popFront();
    2144 
    21452146  }
    21462147  else
     
    21482149    rpcPicYuvRec = new TComPicYuv;
    21492150
    2150 #if LAYER_CTB
    21512151    rpcPicYuvRec->create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeight(), m_acLayerCfg[layer].getChromaFormatIDC(), m_acLayerCfg[layer].m_uiMaxCUWidth, m_acLayerCfg[layer].m_uiMaxCUHeight, m_acLayerCfg[layer].m_uiMaxCUDepth, NULL );
    2152 #else
    2153     rpcPicYuvRec->create( m_acLayerCfg[layer].getSourceWidth(), m_acLayerCfg[layer].getSourceHeight(), m_acLayerCfg[layer].getChromaFormatIDC(), m_uiMaxCUWidth, m_uiMaxCUHeight, m_uiMaxCUDepth, NULL );
    2154 #endif
    2155 
    21562152  }
    21572153  m_acListPicYuvRec[layer].pushBack( rpcPicYuvRec );
Note: See TracChangeset for help on using the changeset viewer.