Changeset 1333 in SHVCSoftware for branches/SHM-dev/source/Lib


Ignore:
Timestamp:
22 Jul 2015, 01:50:55 (9 years ago)
Author:
seregin
Message:

port rev 4411

Location:
branches/SHM-dev/source/Lib
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibCommon/CommonDef.h

    r1330 r1333  
    116116// ====================================================================================================================
    117117
    118 #define _SUMMARY_OUT_               0           ///< print-out PSNR results of all slices to summary.txt
    119 #define _SUMMARY_PIC_               0           ///< print-out PSNR results for each slice type to summary.txt
    120 
    121118#define MAX_GOP                     64          ///< max. value of hierarchical GOP size
    122119
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncAnalyze.h

    r1292 r1333  
    376376
    377377
    378   Void    printSummary(const ChromaFormat chFmt, const Bool printSequenceMSE, const BitDepths &bitDepths, Char ch='T')
     378  Void    printSummary(const ChromaFormat chFmt, const Bool printSequenceMSE, const BitDepths &bitDepths, const std::string &sFilename)
    379379  {
    380     FILE* pFile = NULL;
    381 
    382     switch( ch )
    383     {
    384       case 'T':
    385         pFile = fopen ("summaryTotal.txt", "at");
    386         break;
    387       case 'I':
    388         pFile = fopen ("summary_I.txt", "at");
    389         break;
    390       case 'P':
    391         pFile = fopen ("summary_P.txt", "at");
    392         break;
    393       case 'B':
    394         pFile = fopen ("summary_B.txt", "at");
    395         break;
    396       default:
    397         assert(0);
    398         return;
    399         break;
    400     }
     380    FILE* pFile = fopen (sFilename.c_str(), "at");
    401381
    402382    Double dFps     =   m_dFrmRate; //--CFG_KDY
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncCfg.h

    r1332 r1333  
    379379  Bool      m_bEfficientFieldIRAPEnabled;                     ///< enable to code fields in a specific, potentially more efficient, order.
    380380  Bool      m_bHarmonizeGopFirstFieldCoupleEnabled;
     381
     382  std::string m_summaryOutFilename;                           ///< filename to use for producing summary output file.
     383  std::string m_summaryPicFilenameBase;                       ///< Base filename to use for producing summary picture output files. The actual filenames used will have I.txt, P.txt and B.txt appended.
    381384
    382385#if SVC_EXTENSION
     
    10211024  Void      setChromaSamplingVerFilterIdc(Int i)                     { m_chromaSamplingVerFilterIdc = i;}
    10221025
     1026  Void      setSummaryOutFilename(const std::string &s)              { m_summaryOutFilename = s; }
     1027  const std::string& getSummaryOutFilename() const                   { return m_summaryOutFilename; }
     1028  Void      setSummaryPicFilenameBase(const std::string &s)          { m_summaryPicFilenameBase = s; }
     1029  const std::string& getSummaryPicFilenameBase() const               { return m_summaryPicFilenameBase; }
     1030
    10231031#if Q0189_TMVP_CONSTRAINTS
    10241032  Void  setTMVPConstraintsSEIEnabled(Int b)                  { m_TMVPConstraintsSEIEnabled = b; }
  • branches/SHM-dev/source/Lib/TLibEncoder/TEncGOP.cpp

    r1332 r1333  
    29332933  m_gcAnalyzeB.printOut('b', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
    29342934
    2935 #if _SUMMARY_OUT_
    2936   m_gcAnalyzeAll.printSummary(chFmt, printSequenceMSE, bitDepths);
    2937 #endif
    2938 #if _SUMMARY_PIC_
    2939   m_gcAnalyzeI.printSummary(chFmt, printSequenceMSE, bitDepths, 'I');
    2940   m_gcAnalyzeP.printSummary(chFmt, printSequenceMSE, bitDepths, 'P');
    2941   m_gcAnalyzeB.printSummary(chFmt, printSequenceMSE, bitDepths, 'B');
    2942 #endif
     2935  if (!m_pcCfg->getSummaryOutFilename().empty())
     2936  {
     2937    m_gcAnalyzeAll.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryOutFilename());
     2938  }
     2939
     2940  if (!m_pcCfg->getSummaryPicFilenameBase().empty())
     2941  {
     2942    m_gcAnalyzeI.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"I.txt");
     2943    m_gcAnalyzeP.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"P.txt");
     2944    m_gcAnalyzeB.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"B.txt");
     2945  }
    29432946
    29442947  if(isField)
     
    29522955    m_gcAnalyzeAll_in.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
    29532956
    2954 #if _SUMMARY_OUT_
    2955     m_gcAnalyzeAll_in.printSummary(chFmt, printSequenceMSE, bitDepths);
    2956 #endif
     2957    if (!m_pcCfg->getSummaryOutFilename().empty())
     2958    {
     2959      m_gcAnalyzeAll_in.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryOutFilename());
     2960    }
    29572961  }
    29582962
Note: See TracChangeset for help on using the changeset viewer.