Skip to content
Snippets Groups Projects
Commit 77508dc6 authored by Taoran Lu's avatar Taoran Lu
Browse files

add decoder check: all slices in one picture shall use same LMCS aps id

parent 82b08e52
No related branches found
No related tags found
No related merge requests found
......@@ -410,6 +410,9 @@ DecLib::DecLib()
, m_lastNoIncorrectPicOutputFlag(false)
#else
, m_craNoRaslOutputFlag(false)
#endif
#if JVET_O0428_LMCS_CLEANUP
, m_sliceLmcsApsId(-1)
#endif
, m_pDecodedSEIOutputStream(NULL)
, m_decodedPictureHashSEIEnabled(false)
......@@ -1562,6 +1565,16 @@ bool DecLib::xDecodeSlice(InputNALUnit &nalu, int &iSkipFrame, int iPOCLastDispl
if (pcSlice->getLmcsEnabledFlag())
{
APS* lmcsAPS = pcSlice->getLmcsAPS();
#if JVET_O0428_LMCS_CLEANUP
if (m_bFirstSliceInPicture)
{
m_sliceLmcsApsId = lmcsAPS->getAPSId();
}
else
{
CHECK(lmcsAPS->getAPSId() != m_sliceLmcsApsId, "same APS ID shall be used for all slices in one picture");
}
#endif
SliceReshapeInfo& sInfo = lmcsAPS->getReshaperAPSInfo();
SliceReshapeInfo& tInfo = m_cReshaper.getSliceReshaperInfo();
tInfo.reshaperModelMaxBinIdx = sInfo.reshaperModelMaxBinIdx;
......
......@@ -121,6 +121,9 @@ private:
bool m_lastNoIncorrectPicOutputFlag; //value of variable NoIncorrectPicOutputFlag of the last CRA / GDR pic
#else
bool m_craNoRaslOutputFlag; //value of variable NoRaslOutputFlag of the last CRA pic
#endif
#if JVET_O0428_LMCS_CLEANUP
int m_sliceLmcsApsId; //value of LmcsApsId, constraint is same id for all slices in one picture
#endif
std::ostream *m_pDecodedSEIOutputStream;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment