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


Ignore:
Timestamp:
22 Jul 2015, 20:12:06 (9 years ago)
Author:
seregin
Message:

use layerIdx instead of layerId in the output

File:
1 edited

Legend:

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

    r1375 r1376  
    19431943  for(layer = 0; layer < m_numLayers; layer++)
    19441944  {
    1945     UInt layerId = vps->getLayerIdInNuh(layer);
    1946     m_apcTEncTop[layerId]->getAnalyzeAll()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
    1947     m_apcTEncTop[layerId]->getAnalyzeI()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
    1948     m_apcTEncTop[layerId]->getAnalyzeP()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
    1949     m_apcTEncTop[layerId]->getAnalyzeB()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
     1945    m_apcTEncTop[layer]->getAnalyzeAll()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
     1946    m_apcTEncTop[layer]->getAnalyzeI()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
     1947    m_apcTEncTop[layer]->getAnalyzeP()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
     1948    m_apcTEncTop[layer]->getAnalyzeB()->setFrmRate( m_acLayerCfg[layer].getFrameRate() * rateMultiplier );
    19501949  }
    19511950
     
    19551954  {
    19561955    const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);   
    1957     m_apcTEncTop[vps->getLayerIdInNuh(layer)]->getAnalyzeAll()->printOut('a', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
     1956    m_apcTEncTop[layer]->getAnalyzeAll()->printOut('a', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
    19581957  }
    19591958
     
    19621961  {
    19631962    const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    1964     m_apcTEncTop[vps->getLayerIdInNuh(layer)]->getAnalyzeI()->printOut('i', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
     1963    m_apcTEncTop[layer]->getAnalyzeI()->printOut('i', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
    19651964  }
    19661965
     
    19691968  {
    19701969    const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    1971     m_apcTEncTop[vps->getLayerIdInNuh(layer)]->getAnalyzeP()->printOut('p', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
     1970    m_apcTEncTop[layer]->getAnalyzeP()->printOut('p', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
    19721971  }
    19731972
     
    19761975  {
    19771976    const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    1978     m_apcTEncTop[vps->getLayerIdInNuh(layer)]->getAnalyzeB()->printOut('b', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
     1977    m_apcTEncTop[layer]->getAnalyzeB()->printOut('b', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
    19791978  }
    19801979
    19811980  for( layer = 0; layer < m_numLayers; layer++ )
    19821981  {
    1983     const UInt layerId = vps->getLayerIdInNuh(layer);
    1984 
    1985     if (!m_apcTEncTop[layerId]->getSummaryOutFilename().empty())
     1982    if (!m_apcTEncTop[layer]->getSummaryOutFilename().empty())
    19861983    {
    19871984      const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    19881985
    1989       m_apcTEncTop[layerId]->getAnalyzeAll()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layerId]->getSummaryOutFilename());
     1986      m_apcTEncTop[layer]->getAnalyzeAll()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layer]->getSummaryOutFilename());
    19901987    }
    19911988  }
     
    19931990  for( layer = 0; layer < m_numLayers; layer++ )
    19941991  {
    1995     const UInt layerId = vps->getLayerIdInNuh(layer);
    1996 
    1997     if (!m_apcTEncTop[layerId]->getSummaryPicFilenameBase().empty())
     1992    if (!m_apcTEncTop[layer]->getSummaryPicFilenameBase().empty())
    19981993    {
    19991994      const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    20001995
    2001       m_apcTEncTop[layerId]->getAnalyzeI()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layerId]->getSummaryPicFilenameBase()+"I.txt");
    2002       m_apcTEncTop[layerId]->getAnalyzeP()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layerId]->getSummaryPicFilenameBase()+"P.txt");
    2003       m_apcTEncTop[layerId]->getAnalyzeB()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layerId]->getSummaryPicFilenameBase()+"B.txt");
     1996      m_apcTEncTop[layer]->getAnalyzeI()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layer]->getSummaryPicFilenameBase()+"I.txt");
     1997      m_apcTEncTop[layer]->getAnalyzeP()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layer]->getSummaryPicFilenameBase()+"P.txt");
     1998      m_apcTEncTop[layer]->getAnalyzeB()->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layer]->getSummaryPicFilenameBase()+"B.txt");
    20041999    }
    20052000  }
     
    20092004    for(layer = 0; layer < m_numLayers; layer++)
    20102005    {
    2011       const UInt layerId = vps->getLayerIdInNuh(layer);
    2012 
    20132006      const BitDepths bitDepths(m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_LUMA], m_acLayerCfg[layer].m_internalBitDepth[CHANNEL_TYPE_CHROMA]);
    2014       TEncAnalyze *analyze = m_apcTEncTop[layerId]->getAnalyzeAllin();
     2007      TEncAnalyze *analyze = m_apcTEncTop[layer]->getAnalyzeAllin();
    20152008
    20162009      //-- interlaced summary
    20172010      analyze->setFrmRate( m_acLayerCfg[layer].getFrameRate());
    2018       analyze->setBits(m_apcTEncTop[layerId]->getAnalyzeB()->getBits());
     2011      analyze->setBits(m_apcTEncTop[layer]->getAnalyzeB()->getBits());
    20192012      // prior to the above statement, the interlace analyser does not contain the correct total number of bits.
    20202013
     
    20222015      analyze->printOut('a', m_acLayerCfg[layer].getChromaFormatIDC(), printMSEBasedSNR, printSequenceMSE, bitDepths, layer);
    20232016
    2024       if (!m_apcTEncTop[layerId]->getSummaryOutFilename().empty())
    2025       {
    2026         analyze->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layerId]->getSummaryOutFilename());
     2017      if (!m_apcTEncTop[layer]->getSummaryOutFilename().empty())
     2018      {
     2019        analyze->printSummary(m_acLayerCfg[layer].getChromaFormatIDC(), printSequenceMSE, bitDepths, m_apcTEncTop[layer]->getSummaryOutFilename());
    20272020      }
    20282021    }
     
    20322025  for( layer = 0; layer < m_numLayers; layer++ )
    20332026  {
    2034     printf("RVM[L%d]: %.3lf\n", layer, m_apcTEncTop[vps->getLayerIdInNuh(layer)]->calculateRVM());
     2027    printf("RVM[L%d]: %.3lf\n", layer, m_apcTEncTop[layer]->calculateRVM());
    20352028  }
    20362029  printf("\n");
Note: See TracChangeset for help on using the changeset viewer.