Newer
Older
Philipp Merkle
committed
#if JVET_P0199_P0289_P0303_MIP_FULLMATRIX
else if( block.width == 4 || block.height == 4 || (block.width == 8 && block.height == 8) )
#else
else if (block.width <= 8 && block.height <= 8)
Philipp Merkle
committed
#endif
{
return 19;
}
else
{
return 11;
}
Philipp Merkle
committed
#if JVET_P0803_COMBINED_MIP_CLEANUP || JVET_P0199_P0289_P0303_MIP_FULLMATRIX
int getMipSizeId(const Size& block)
{
if( block.width == 4 && block.height == 4 )
{
return 0;
}
Philipp Merkle
committed
#if JVET_P0199_P0289_P0303_MIP_FULLMATRIX
else if( block.width == 4 || block.height == 4 || (block.width == 8 && block.height == 8) )
#else
else if( block.width <= 8 && block.height <= 8 )
Philipp Merkle
committed
#endif
{
return 1;
}
else
{
return 2;
}
}
#endif
#if !JVET_P0803_COMBINED_MIP_CLEANUP
bool mipModesAvailable(const Size& block)
{
return (getNumModesMip(block));
}
bool allowLfnstWithMip(const Size& block)
{
if (block.width >= 16 && block.height >= 16)
{
return true;
}
return false;
}

Karsten Suehring
committed
bool PU::isRefPicSameSize( const PredictionUnit& pu )
{
bool samePicSize = true;
int curPicWidth = pu.cs->pps->getPicWidthInLumaSamples();
int curPicHeight = pu.cs->pps->getPicHeightInLumaSamples();
if( pu.refIdx[0] >= 0 )
{
int refPicWidth = pu.cu->slice->getRefPic( REF_PIC_LIST_0, pu.refIdx[0] )->getPicWidthInLumaSamples();
int refPicHeight = pu.cu->slice->getRefPic( REF_PIC_LIST_0, pu.refIdx[0] )->getPicHeightInLumaSamples();
samePicSize = refPicWidth == curPicWidth && refPicHeight == curPicHeight;
}
if( pu.refIdx[1] >= 0 )
{
int refPicWidth = pu.cu->slice->getRefPic( REF_PIC_LIST_1, pu.refIdx[1] )->getPicWidthInLumaSamples();
int refPicHeight = pu.cu->slice->getRefPic( REF_PIC_LIST_1, pu.refIdx[1] )->getPicHeightInLumaSamples();
samePicSize = samePicSize && ( refPicWidth == curPicWidth && refPicHeight == curPicHeight );
}
return samePicSize;
}