Commit 98a20bb9 authored by Karsten Suehring's avatar Karsten Suehring
Browse files

JCTVC-Z0038: add start code bytes to per-frame and summary encoding statistics output

parent 4ce829b6
......@@ -2181,7 +2181,6 @@ Void TEncGOP::xCalculateAddPSNR( TComPic* pcPic, TComPicYuv* pcPicD, const Acces
/* calculate the size of the access unit, excluding:
* - any AnnexB contributions (start_code_prefix, zero_byte, etc.,)
* - SEI NAL units
*/
UInt numRBSPBytes = 0;
......@@ -2196,6 +2195,15 @@ Void TEncGOP::xCalculateAddPSNR( TComPic* pcPic, TComPicYuv* pcPicD, const Acces
{
numRBSPBytes += numRBSPBytes_nal;
}
// add start code bytes (Annex B)
if (it == accessUnit.begin() || (*it)->m_nalUnitType == NAL_UNIT_VPS || (*it)->m_nalUnitType == NAL_UNIT_SPS || (*it)->m_nalUnitType == NAL_UNIT_PPS)
{
numRBSPBytes += 4;
}
else
{
numRBSPBytes += 3;
}
}
UInt uibits = numRBSPBytes * 8;
......
Supports Markdown
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