Commit c8837e78 authored by Xiaozhong Xu's avatar Xiaozhong Xu Committed by Xiang Li

remove hex based PSNR report

parent 172e1153
......@@ -183,9 +183,9 @@ public:
}
#if ENABLE_QPA || WCG_WPSNR
void printOut ( char cDelim, const ChromaFormat chFmt, const bool printMSEBasedSNR, const bool printSequenceMSE, const bool printHexPsnr, const BitDepths &bitDepths, const bool useWPSNR = false )
void printOut(char cDelim, const ChromaFormat chFmt, const bool printMSEBasedSNR, const bool printSequenceMSE, const BitDepths &bitDepths, const bool useWPSNR = false)
#else
void printOut ( char cDelim, const ChromaFormat chFmt, const bool printMSEBasedSNR, const bool printSequenceMSE, const bool printHexPsnr, const BitDepths &bitDepths )
void printOut(char cDelim, const ChromaFormat chFmt, const bool printMSEBasedSNR, const bool printSequenceMSE, const BitDepths &bitDepths)
#endif
{
#if !WCG_WPSNR
......@@ -234,10 +234,6 @@ public:
#endif
msg( e_msg_level, " \tTotal Frames | " "Bitrate " "Y-PSNR" );
if (printHexPsnr)
{
msg(e_msg_level, "xY-PSNR ");
}
if (printSequenceMSE)
{
......@@ -257,18 +253,6 @@ public:
#endif
getPsnr(COMPONENT_Y) / (double)getNumPic() );
if (printHexPsnr)
{
double dPsnr;
uint64_t xPsnr;
dPsnr = getPsnr(COMPONENT_Y) / (double)getNumPic();
copy(reinterpret_cast<uint8_t *>(&dPsnr),
reinterpret_cast<uint8_t *>(&dPsnr) + sizeof(dPsnr),
reinterpret_cast<uint8_t *>(&xPsnr));
msg(e_msg_level, " %16" PRIx64 " ", xPsnr);
}
if (printSequenceMSE)
{
......@@ -293,10 +277,6 @@ public:
#endif
msg( e_msg_level, "\tTotal Frames | " "Bitrate " "Y-PSNR" );
if (printHexPsnr)
{
msg(e_msg_level, "xY-PSNR ");
}
if (printSequenceMSE)
{
......@@ -316,18 +296,6 @@ public:
#endif
getPsnr(COMPONENT_Y) / (double)getNumPic() );
if (printHexPsnr)
{
double dPsnr;
uint64_t xPsnr;
dPsnr = getPsnr(COMPONENT_Y) / (double)getNumPic();
copy(reinterpret_cast<uint8_t *>(&dPsnr),
reinterpret_cast<uint8_t *>(&dPsnr) + sizeof(dPsnr),
reinterpret_cast<uint8_t *>(&xPsnr));
msg(e_msg_level, " %16" PRIx64 " ", xPsnr);
}
if (printSequenceMSE)
{
......@@ -357,10 +325,6 @@ public:
#endif
msg( e_msg_level, " \tTotal Frames | " "Bitrate " "Y-PSNR " "U-PSNR " "V-PSNR " "YUV-PSNR " );
if (printHexPsnr)
{
msg(e_msg_level, "xY-PSNR " "xU-PSNR " "xV-PSNR ");
}
if (printSequenceMSE)
{
......@@ -389,20 +353,6 @@ public:
getPsnr(COMPONENT_Cr) / (double)getNumPic(),
PSNRyuv );
if (printHexPsnr)
{
double dPsnr[MAX_NUM_COMPONENT];
uint64_t xPsnr[MAX_NUM_COMPONENT];
for (int i = 0; i < MAX_NUM_COMPONENT; i++)
{
dPsnr[i] = getPsnr((ComponentID)i) / (double)getNumPic();
copy(reinterpret_cast<uint8_t *>(&dPsnr[i]),
reinterpret_cast<uint8_t *>(&dPsnr[i]) + sizeof(dPsnr[i]),
reinterpret_cast<uint8_t *>(&xPsnr[i]));
}
msg(e_msg_level, " %16" PRIx64 " %16" PRIx64 " %16" PRIx64, xPsnr[COMPONENT_Y], xPsnr[COMPONENT_Cb], xPsnr[COMPONENT_Cr]);
}
if (printSequenceMSE)
{
......@@ -437,10 +387,6 @@ public:
m_ext360.printHeader(e_msg_level);
#endif
if (printHexPsnr)
{
msg(e_msg_level, "xY-PSNR " "xU-PSNR " "xV-PSNR ");
}
if (printSequenceMSE)
{
......@@ -469,20 +415,6 @@ public:
getPsnr(COMPONENT_Cr) / (double)getNumPic(),
PSNRyuv );
if (printHexPsnr)
{
double dPsnr[MAX_NUM_COMPONENT];
uint64_t xPsnr[MAX_NUM_COMPONENT];
for (int i = 0; i < MAX_NUM_COMPONENT; i++)
{
dPsnr[i] = getPsnr((ComponentID)i) / (double)getNumPic();
copy(reinterpret_cast<uint8_t *>(&dPsnr[i]),
reinterpret_cast<uint8_t *>(&dPsnr[i]) + sizeof(dPsnr[i]),
reinterpret_cast<uint8_t *>(&xPsnr[i]));
}
msg(e_msg_level, " %16" PRIx64 " %16" PRIx64 " %16" PRIx64 , xPsnr[COMPONENT_Y], xPsnr[COMPONENT_Cb], xPsnr[COMPONENT_Cr]);
}
#if EXTENSION_360_VIDEO
m_ext360.printPSNRs(getNumPic(), e_msg_level);
......@@ -511,7 +443,7 @@ public:
}
void printSummary(const ChromaFormat chFmt, const bool printSequenceMSE, const bool printHexPsnr, const BitDepths &bitDepths, const std::string &sFilename)
void printSummary(const ChromaFormat chFmt, const bool printSequenceMSE, const BitDepths &bitDepths, const std::string &sFilename)
{
FILE* pFile = fopen (sFilename.c_str(), "at");
......
......@@ -2801,7 +2801,7 @@ void EncGOP::compressGOP( int iPOCLast, int iNumPicRcvd, PicList& rcListPic,
}
void EncGOP::printOutSummary(uint32_t uiNumAllPicCoded, bool isField, const bool printMSEBasedSNR, const bool printSequenceMSE, const bool printHexPsnr, const BitDepths &bitDepths)
void EncGOP::printOutSummary(uint32_t uiNumAllPicCoded, bool isField, const bool printMSEBasedSNR, const bool printSequenceMSE, const BitDepths &bitDepths)
{
#if ENABLE_QPA
const bool useWPSNR = m_pcEncLib->getUseWPSNR();
......@@ -2836,16 +2836,16 @@ void EncGOP::printOutSummary(uint32_t uiNumAllPicCoded, bool isField, const bool
#if ENABLE_QPA
m_gcAnalyzeAll.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths, useWPSNR);
#else
m_gcAnalyzeAll.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, printHexPsnr, bitDepths);
m_gcAnalyzeAll.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
#endif
msg( DETAILS,"\n\nI Slices--------------------------------------------------------\n" );
m_gcAnalyzeI.printOut('i', chFmt, printMSEBasedSNR, printSequenceMSE, printHexPsnr, bitDepths);
m_gcAnalyzeI.printOut('i', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
msg( DETAILS,"\n\nP Slices--------------------------------------------------------\n" );
m_gcAnalyzeP.printOut('p', chFmt, printMSEBasedSNR, printSequenceMSE, printHexPsnr, bitDepths);
m_gcAnalyzeP.printOut('p', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
msg( DETAILS,"\n\nB Slices--------------------------------------------------------\n" );
m_gcAnalyzeB.printOut('b', chFmt, printMSEBasedSNR, printSequenceMSE, printHexPsnr, bitDepths);
m_gcAnalyzeB.printOut('b', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
#if WCG_WPSNR
if (useLumaWPSNR)
......@@ -2856,14 +2856,14 @@ void EncGOP::printOutSummary(uint32_t uiNumAllPicCoded, bool isField, const bool
#endif
if (!m_pcCfg->getSummaryOutFilename().empty())
{
m_gcAnalyzeAll.printSummary(chFmt, printSequenceMSE, printHexPsnr, bitDepths, m_pcCfg->getSummaryOutFilename());
m_gcAnalyzeAll.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryOutFilename());
}
if (!m_pcCfg->getSummaryPicFilenameBase().empty())
{
m_gcAnalyzeI.printSummary(chFmt, printSequenceMSE, printHexPsnr, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"I.txt");
m_gcAnalyzeP.printSummary(chFmt, printSequenceMSE, printHexPsnr, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"P.txt");
m_gcAnalyzeB.printSummary(chFmt, printSequenceMSE, printHexPsnr, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"B.txt");
m_gcAnalyzeI.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"I.txt");
m_gcAnalyzeP.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"P.txt");
m_gcAnalyzeB.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryPicFilenameBase()+"B.txt");
}
#if WCG_WPSNR
......@@ -2883,11 +2883,11 @@ void EncGOP::printOutSummary(uint32_t uiNumAllPicCoded, bool isField, const bool
#if ENABLE_QPA
m_gcAnalyzeAll_in.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths, useWPSNR);
#else
m_gcAnalyzeAll_in.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, printHexPsnr, bitDepths);
m_gcAnalyzeAll_in.printOut('a', chFmt, printMSEBasedSNR, printSequenceMSE, bitDepths);
#endif
if (!m_pcCfg->getSummaryOutFilename().empty())
{
m_gcAnalyzeAll_in.printSummary(chFmt, printSequenceMSE, printHexPsnr, bitDepths, m_pcCfg->getSummaryOutFilename());
m_gcAnalyzeAll_in.printSummary(chFmt, printSequenceMSE, bitDepths, m_pcCfg->getSummaryOutFilename());
#if WCG_WPSNR
if (useLumaWPSNR)
{
......
......@@ -269,7 +269,7 @@ public:
int& iNumEncoded, bool isTff );
void printSummary(bool isField) { m_cGOPEncoder.printOutSummary (m_uiNumAllPicCoded, isField, m_printMSEBasedSequencePSNR, m_printSequenceMSE, m_printHexPsnr, m_spsMap.getFirstPS()->getBitDepths()); }
void printSummary(bool isField) { m_cGOPEncoder.printOutSummary(m_uiNumAllPicCoded, isField, m_printMSEBasedSequencePSNR, m_printSequenceMSE, m_spsMap.getFirstPS()->getBitDepths()); }
};
......
......@@ -1300,9 +1300,7 @@ void HLSWriter::codeSliceHeader ( Slice* pcSlice )
}
if( pcSlice->getSliceType() != I_SLICE &&
( ( pcSlice->getColFromL0Flag() == 1 && pcSlice->getNumRefIdx( REF_PIC_LIST_0 ) > 1 ) ||
( pcSlice->getColFromL0Flag() == 0 && pcSlice->getNumRefIdx( REF_PIC_LIST_1 ) > 1 ) ) )
{
WRITE_UVLC( pcSlice->getColRefIdx(), "collocated_ref_idx" );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment