Changeset 875 in SHVCSoftware for branches/SHM-dev/source/App/TAppEncoder


Ignore:
Timestamp:
28 Aug 2014, 01:40:54 (10 years ago)
Author:
seregin
Message:

WPP setting per layer

Location:
branches/SHM-dev/source/App/TAppEncoder
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.cpp

    r874 r875  
    485485  string* cfg_colourRemapSEIFile[MAX_LAYERS];
    486486#endif
     487  Int*    cfg_waveFrontSynchro[MAX_LAYERS];
     488
    487489  for(UInt layer = 0; layer < MAX_LAYERS; layer++)
    488490  {
     
    523525#endif
    524526    cfg_numScaledRefLayerOffsets [layer] = &m_acLayerCfg[layer].m_numScaledRefLayerOffsets;
     527    cfg_waveFrontSynchro[layer]  = &m_acLayerCfg[layer].m_waveFrontSynchro;
    525528    for(Int i = 0; i < MAX_LAYERS; i++)
    526529    {
     
    959962  ("TileRowHeightArray",          cfgRowHeight,                    string(""), "Array containing tile row height values in units of LCU")
    960963  ("LFCrossTileBoundaryFlag",      m_bLFCrossTileBoundaryFlag,             true,          "1: cross-tile-boundary loop filtering. 0:non-cross-tile-boundary loop filtering")
     964#if SVC_EXTENSION
     965  ("WaveFrontSynchro%d",          cfg_waveFrontSynchro,             0,  MAX_LAYERS,          "0: no synchro; 1 synchro with TR; 2 TRR etc")
     966#else
    961967  ("WaveFrontSynchro",            m_iWaveFrontSynchro,             0,          "0: no synchro; 1 synchro with TR; 2 TRR etc")
     968#endif
    962969  ("ScalingList",                 m_useScalingListId,              0,          "0: no scaling list, 1: default scaling lists, 2: scaling lists specified in ScalingListFile")
    963970  ("ScalingListFile",             cfg_ScalingListFile,             string(""), "Scaling list file name")
     
    24582465  }
    24592466 
     2467#if !SVC_EXTENSION
    24602468  Bool tileFlag = (m_numTileColumnsMinus1 > 0 || m_numTileRowsMinus1 > 0 );
    24612469  xConfirmPara( tileFlag && m_iWaveFrontSynchro,            "Tile and Wavefront can not be applied together");
    24622470
    24632471  //TODO:ChromaFmt assumes 4:2:0 below
    2464 #if !SVC_EXTENSION
    24652472  xConfirmPara( m_iSourceWidth  % TComSPS::getWinUnitX(CHROMA_420) != 0, "Picture width must be an integer multiple of the specified chroma subsampling");
    24662473  xConfirmPara( m_iSourceHeight % TComSPS::getWinUnitY(CHROMA_420) != 0, "Picture height must be an integer multiple of the specified chroma subsampling");
     
    32283235    Int m_uiMaxCUHeight = m_acLayerCfg[layer].m_uiMaxCUHeight;
    32293236#endif
    3230 #endif
     3237
     3238    Bool tileFlag = (m_numTileColumnsMinus1 > 0 || m_numTileRowsMinus1 > 0 );
     3239    Int m_iWaveFrontSynchro = m_acLayerCfg[layer].m_waveFrontSynchro;
     3240    xConfirmPara( tileFlag && m_iWaveFrontSynchro,            "Tile and Wavefront can not be applied together");
     3241#endif
     3242
    32313243  if(m_vuiParametersPresentFlag && m_bitstreamRestrictionFlag)
    32323244  {
     
    33053317  }
    33063318#endif
     3319#if !SVC_EXTENSION
    33073320  xConfirmPara( m_iWaveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" );
    3308 #if !SVC_EXTENSION
    33093321  xConfirmPara( m_iWaveFrontSubstreams <= 0, "WaveFrontSubstreams must be positive" );
    33103322  xConfirmPara( m_iWaveFrontSubstreams > 1 && !m_iWaveFrontSynchro, "Must have WaveFrontSynchro > 0 in order to have WaveFrontSubstreams > 1" );
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncCfg.h

    r874 r875  
    257257  std::vector<Int> m_tileColumnWidth;
    258258  std::vector<Int> m_tileRowHeight;
     259#if !SVC_EXTENSION
    259260  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.
    260 #if !SVC_EXTENSION
    261261  Int       m_iWaveFrontSubstreams; //< If iWaveFrontSynchro, this is the number of substreams per frame (dependent tiles) or per tile (independent tiles).
    262262#endif
     
    497497#endif
    498498  Int  getDecodingRefreshType()    {return m_iDecodingRefreshType; }
    499   Int  getWaveFrontSynchro()        { return m_iWaveFrontSynchro; }
     499  Int  getWaveFrontSynchro(Int layerId)        { return m_acLayerCfg[layerId].m_waveFrontSynchro; }
    500500  Void getDirFilename(string& filename, string& dir, const string path);
    501501#if OUTPUT_LAYER_SETS_CONFIG
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncLayerCfg.cpp

    r868 r875  
    333333  }
    334334#endif
    335   printf("WaveFrontSynchro:%d WaveFrontSubstreams:%d", m_cAppEncCfg->getWaveFrontSynchro(), m_iWaveFrontSubstreams);
     335  printf("WaveFrontSynchro:%d WaveFrontSubstreams:%d", m_waveFrontSynchro, m_iWaveFrontSubstreams);
    336336#if LAYER_CTB
    337337  printf("PCM:%d ", (m_cAppEncCfg->getUsePCM() && (1<<m_cAppEncCfg->getPCMLog2MinSize()) <= m_uiMaxCUWidth)? 1 : 0);
     
    464464#endif
    465465
    466 
    467   m_iWaveFrontSubstreams = m_cAppEncCfg->getWaveFrontSynchro() ? (m_iSourceHeight + maxCUHeight - 1) / maxCUHeight : 1;
     466  m_iWaveFrontSubstreams = m_waveFrontSynchro ? (m_iSourceHeight + maxCUHeight - 1) / maxCUHeight : 1;
     467  xConfirmPara( m_waveFrontSynchro < 0, "WaveFrontSynchro cannot be negative" );
    468468  xConfirmPara( m_iWaveFrontSubstreams <= 0, "WaveFrontSubstreams must be positive" );
    469   xConfirmPara( m_iWaveFrontSubstreams > 1 && !m_cAppEncCfg->getWaveFrontSynchro(), "Must have WaveFrontSynchro > 0 in order to have WaveFrontSubstreams > 1" );
     469  xConfirmPara( m_iWaveFrontSubstreams > 1 && !m_waveFrontSynchro, "Must have WaveFrontSynchro > 0 in order to have WaveFrontSubstreams > 1" );
    470470
    471471  //chekc parameters
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncLayerCfg.h

    r868 r875  
    8181
    8282  Int       m_maxTidIlRefPicsPlus1;
    83   Int       m_iWaveFrontSubstreams; //< If iWaveFrontSynchro, this is the number of substreams per frame (dependent tiles) or per tile (independent tiles).
     83  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.
     84  Int       m_iWaveFrontSubstreams;               ///< If iWaveFrontSynchro, this is the number of substreams per frame (dependent tiles) or per tile (independent tiles).
    8485
    8586  Int       m_iQP;                                            ///< QP value of key-picture (integer)
     
    147148  Int*      m_colourRemapSEIPostLutTargetValue[3];
    148149#endif
     150
    149151public:
    150152  TAppEncLayerCfg();
  • branches/SHM-dev/source/App/TAppEncoder/TAppEncTop.cpp

    r874 r875  
    609609    }
    610610    m_acTEncTop[layer].setLFCrossTileBoundaryFlag( m_bLFCrossTileBoundaryFlag );
    611     m_acTEncTop[layer].setWaveFrontSynchro           ( m_iWaveFrontSynchro );
     611    m_acTEncTop[layer].setWaveFrontSynchro           ( m_acLayerCfg[layer].m_waveFrontSynchro );
    612612    m_acTEncTop[layer].setWaveFrontSubstreams        ( m_acLayerCfg[layer].m_iWaveFrontSubstreams );
    613613    m_acTEncTop[layer].setTMVPModeId ( m_TMVPModeId );
Note: See TracChangeset for help on using the changeset viewer.