本文整理汇总了C++中MbDataAccess::getLastQp4LF方法的典型用法代码示例。如果您正苦于以下问题:C++ MbDataAccess::getLastQp4LF方法的具体用法?C++ MbDataAccess::getLastQp4LF怎么用?C++ MbDataAccess::getLastQp4LF使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MbDataAccess
的用法示例。
在下文中一共展示了MbDataAccess::getLastQp4LF方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ROF
// JVT-V035
ErrVal
SliceEncoder::updatePictureAVCRewrite( ControlData& rcControlData, UInt uiMbInRow )
{
ROF( m_bInitDone );
SliceHeader& rcSliceHeader = *rcControlData.getSliceHeader();
FMO& rcFMO = *rcSliceHeader.getFMO();
MbDataCtrl* pcMbDataCtrl = rcControlData.getMbDataCtrl();
MbDataCtrl* pcBaseLayerCtrl = rcControlData.getBaseLayerCtrl();
//====== initialization ======
RNOK( pcMbDataCtrl->initSlice( rcSliceHeader, DECODE_PROCESS, false, NULL ) );
if( rcSliceHeader.getTCoeffLevelPredictionFlag() == true )
{
// Update the macroblock state
// Must be done after the bit-stream has been constructed
for( Int iSliceGroupId = rcFMO.getFirstSliceGroupId(); ! rcFMO.SliceGroupCompletelyCoded( iSliceGroupId ); iSliceGroupId = rcFMO.getNextSliceGroupId( iSliceGroupId ) )
{
UInt uiFirstMbInSliceGroup = rcFMO.getFirstMBOfSliceGroup( iSliceGroupId );
UInt uiLastMbInSliceGroup = rcFMO.getLastMBInSliceGroup ( iSliceGroupId );
for( UInt uiMbAddress = uiFirstMbInSliceGroup; uiMbAddress <= uiLastMbInSliceGroup; uiMbAddress = rcFMO.getNextMBNr( uiMbAddress ) )
{
UInt uiMbY = 0;
UInt uiMbX = 0;
MbDataAccess* pcMbDataAccess = 0;
MbDataAccess* pcMbDataAccessBase = 0;
rcSliceHeader.getMbPositionFromAddress( uiMbY, uiMbX, uiMbAddress );
RNOK( pcMbDataCtrl->initMb( pcMbDataAccess, uiMbY, uiMbX ) );
if( pcBaseLayerCtrl )
{
RNOK( pcBaseLayerCtrl ->initMb( pcMbDataAccessBase, uiMbY, uiMbX ) );
pcMbDataAccess->setMbDataAccessBase( pcMbDataAccessBase );
}
// modify QP values (as specified in G.8.1.5.1.2)
if( pcMbDataAccess->getMbData().getMbCbp() == 0 && ( pcMbDataAccess->getMbData().getMbMode() == INTRA_BL || pcMbDataAccess->getMbData().getResidualPredFlag() ) )
{
pcMbDataAccess->getMbData().setQp( pcMbDataAccessBase->getMbData().getQp() );
}
if( pcMbDataAccess->isTCoeffPred() )
{
if( pcMbDataAccess->getMbData().getMbMode() == INTRA_BL )
{
// We're going to use the BL skip flag to correctly decode the intra prediction mode
AOT( pcMbDataAccess->getMbData().getBLSkipFlag() == false );
// Inherit the mode of the base block
pcMbDataAccess->getMbData().setMbMode( pcMbDataAccessBase->getMbData().getMbMode() );
// Inherit intra prediction modes
for( B4x4Idx cIdx; cIdx.isLegal(); cIdx++ )
pcMbDataAccess->getMbData().intraPredMode(cIdx) = pcMbDataAccessBase->getMbData().intraPredMode(cIdx);
pcMbDataAccess->getMbData().setChromaPredMode( pcMbDataAccessBase->getMbData().getChromaPredMode() );
}
// The 8x8 transform flag is present in the bit-stream unless transform coefficients
// are not transmitted at the enhancement layer. In this case, inherit the base layer
// transform type. This makes intra predition work correctly, etc.
if( ( pcMbDataAccess->getMbData().getMbCbp() & 0x0F ) == 0 )
{
pcMbDataAccess->getMbData().setTransformSize8x8( pcMbDataAccessBase->getMbData().isTransformSize8x8() );
}
xAddTCoeffs2( *pcMbDataAccess, *pcMbDataAccessBase );
}
if( pcMbDataAccess->getMbAddress() != uiFirstMbInSliceGroup &&
pcMbDataAccess->getSH().getTCoeffLevelPredictionFlag() &&
!pcMbDataAccess->getSH().getNoInterLayerPredFlag() &&
!pcMbDataAccess->getMbData().isIntra16x16() &&
pcMbDataAccess->getMbData().getMbExtCbp() == 0 )
{
pcMbDataAccess->getMbData().setQp4LF( pcMbDataAccess->getLastQp4LF() );
}
else
{
pcMbDataAccess->getMbData().setQp4LF( pcMbDataAccess->getMbData().getQp() );
}
}
}
}
return Err::m_nOK;
}