Commit b406e015 authored by Mischa Siekmann's avatar Mischa Siekmann

fixed typo in document number

parent f05b549a
......@@ -289,7 +289,7 @@ class CUCtx
public:
CUCtx() : isDQPCoded(false), isChromaQpAdjCoded(false),
qgStart(false),
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
numNonZeroCoeffNonTs(0)
{
violatesLfnstConstrained[CHANNEL_TYPE_LUMA ] = false;
......@@ -300,7 +300,7 @@ public:
#endif
CUCtx(int _qp) : isDQPCoded(false), isChromaQpAdjCoded(false),
qgStart(false),
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
numNonZeroCoeffNonTs(0), qp(_qp)
{
violatesLfnstConstrained[CHANNEL_TYPE_LUMA ] = false;
......@@ -316,7 +316,7 @@ public:
bool qgStart;
uint32_t numNonZeroCoeffNonTs;
int8_t qp; // used as a previous(last) QP and for QP prediction
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
bool violatesLfnstConstrained[MAX_NUM_CHANNEL_TYPE];
#endif
};
......
......@@ -869,7 +869,7 @@ namespace DQIntern
m_goRicePar = 0;
m_goRiceZero = 0;
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void checkRdCosts( const ScanPosType spt, const PQData& pqDataA, const PQData& pqDataB, Decision& decisionA, Decision& decisionB ) const
#else
void checkRdCosts( const ScanPosType spt, const PQData& pqDataA, const PQData& pqDataB, Decision& decisionA, Decision& decisionB, bool zeroOut ) const
......@@ -879,7 +879,7 @@ namespace DQIntern
int64_t rdCostA = m_rdCost + pqDataA.deltaDist;
int64_t rdCostB = m_rdCost + pqDataB.deltaDist;
int64_t rdCostZ = m_rdCost;
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( zeroOut )
{
rdCostZ = m_rdCost;
......@@ -980,7 +980,7 @@ namespace DQIntern
decisionB.prevId = m_stateId;
}
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
}
#endif
......@@ -1377,7 +1377,7 @@ namespace DQIntern
{
::memcpy( decisions, startDec, 8*sizeof(Decision) );
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( zeroOut )
{
if( spt==SCAN_EOCSBB )
......@@ -1393,7 +1393,7 @@ namespace DQIntern
PQData pqData[4];
m_quant.preQuantCoeff( absCoeff, pqData, quanCoeff );
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
m_prevStates[0].checkRdCosts( spt, pqData[0], pqData[2], decisions[0], decisions[2]);
m_prevStates[1].checkRdCosts( spt, pqData[0], pqData[2], decisions[2], decisions[0]);
m_prevStates[2].checkRdCosts( spt, pqData[3], pqData[1], decisions[1], decisions[3]);
......@@ -1406,7 +1406,7 @@ namespace DQIntern
#endif
if( spt==SCAN_EOCSBB )
{
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( zeroOut )
{
m_skipStates[0].checkRdCostSkipSbbZeroOut( decisions[0] );
......@@ -1421,18 +1421,18 @@ namespace DQIntern
m_skipStates[1].checkRdCostSkipSbb( decisions[1] );
m_skipStates[2].checkRdCostSkipSbb( decisions[2] );
m_skipStates[3].checkRdCostSkipSbb( decisions[3] );
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
}
#endif
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( !zeroOut )
{
#endif
m_startState.checkRdCostStart( lastOffset, pqData[0], decisions[0] );
m_startState.checkRdCostStart( lastOffset, pqData[2], decisions[2] );
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
}
#endif
}
......@@ -1456,7 +1456,7 @@ namespace DQIntern
m_currStates[3].updateStateEOS( scanInfo, m_prevStates, m_skipStates, decisions[3] );
::memcpy( decisions+4, decisions, 4*sizeof(Decision) );
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
else if( !zeroOut )
#else
else
......@@ -1545,7 +1545,7 @@ namespace DQIntern
zeroOutforThres = zeroOut || (32 < tuPars.m_height || 32 < tuPars.m_width);
//===== find first test position =====
int firstTestPos = numCoeff - 1;
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( lfnstIdx > 0 && tu.mtsIdx != MTS_SKIP && width >= 4 && height >= 4 )
{
firstTestPos = ( ( width == 4 && height == 4 ) || ( width == 8 && height == 8 ) ) ? 7 : 15 ;
......@@ -1590,7 +1590,7 @@ namespace DQIntern
for( int scanIdx = firstTestPos; scanIdx >= 0; scanIdx-- )
{
const ScanInfo& scanInfo = tuPars.m_scanInfo[ scanIdx ];
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
bool lfnstZeroOut = lfnstIdx > 0 && tu.mtsIdx != MTS_SKIP && width >= 4 && height >= 4 &&
( ( ( ( width >= 8 && height >= 8 ) && scanIdx >= 16 ) || ( ( ( width == 4 && height == 4 ) || ( width == 8 && height == 8 ) ) && scanIdx >= 8 ) ) && scanIdx < 48 );
if (enableScalingLists)
......
......@@ -272,7 +272,7 @@ void TrQuant::xInvLfnst( const TransformUnit &tu, const ComponentID compID )
#endif
bool transposeFlag = getTransposeFlag( intraMode );
const int sbSize = whge3 ? 8 : 4;
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
const int subGrpXMax = ( height == 4 && width > 8 ) ? 2 : 1;
const int subGrpYMax = ( width == 4 && height > 8 ) ? 2 : 1;
#endif
......@@ -280,7 +280,7 @@ void TrQuant::xInvLfnst( const TransformUnit &tu, const ComponentID compID )
bool tu8x8Flag = ( width == 8 && height == 8 );
TCoeff* lfnstTemp;
TCoeff* coeffTemp;
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
for( int subGroupX = 0; subGroupX < subGrpXMax; subGroupX++ )
{
for( int subGroupY = 0; subGroupY < subGrpYMax; subGroupY++ )
......@@ -345,7 +345,7 @@ void TrQuant::xInvLfnst( const TransformUnit &tu, const ComponentID compID )
coeffTemp += width;
}
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
}
} // subGroupX
#endif
......@@ -378,7 +378,7 @@ void TrQuant::xFwdLfnst( const TransformUnit &tu, const ComponentID compID, cons
bool transposeFlag = getTransposeFlag( intraMode );
const int sbSize = whge3 ? 8 : 4;
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
const int subGrpXMax = ( height == 4 && width > 8 ) ? 2 : 1;
const int subGrpYMax = ( width == 4 && height > 8 ) ? 2 : 1;
#endif
......@@ -388,7 +388,7 @@ void TrQuant::xFwdLfnst( const TransformUnit &tu, const ComponentID compID, cons
TCoeff* coeffTemp;
TCoeff* tempCoeff = loadTr ? m_mtsCoeffs[ tu.mtsIdx ] : m_plTempCoeff;
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
for( int subGroupX = 0; subGroupX < subGrpXMax; subGroupX++ )
{
for( int subGroupY = 0; subGroupY < subGrpYMax; subGroupY++ )
......@@ -446,7 +446,7 @@ void TrQuant::xFwdLfnst( const TransformUnit &tu, const ComponentID compID, cons
fwdLfnstNxN( m_tempInMatrix, m_tempOutMatrix, g_lfnstLut[ intraMode ], lfnstIdx - 1, sbSize, ( tu4x4Flag || tu8x8Flag ) ? 8 : 16 );
lfnstTemp = m_tempOutMatrix; // forward spectral rearrangement
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
coeffTemp = tempCoeff + offsetX + offsetY;
#else
coeffTemp = tempCoeff;
......@@ -458,7 +458,7 @@ void TrQuant::xFwdLfnst( const TransformUnit &tu, const ComponentID compID, cons
coeffTemp[ scanPtr->idx ] = *lfnstTemp++;
scanPtr++;
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
}
} // subGroupX
#endif
......@@ -673,7 +673,7 @@ void TrQuant::xT( const TransformUnit &tu, const ComponentID &compID, const CPel
getTrTypes ( tu, compID, trTypeHor, trTypeVer );
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
const int skipWidth = ( trTypeHor != DCT2 && width == 32 ) ? 16 : width > JVET_C0024_ZERO_OUT_TH ? width - JVET_C0024_ZERO_OUT_TH : 0;
const int skipHeight = ( trTypeVer != DCT2 && height == 32 ) ? 16 : height > JVET_C0024_ZERO_OUT_TH ? height - JVET_C0024_ZERO_OUT_TH : 0;
#else
......@@ -758,7 +758,7 @@ void TrQuant::xIT( const TransformUnit &tu, const ComponentID &compID, const CCo
int trTypeVer = DCT2;
getTrTypes ( tu, compID, trTypeHor, trTypeVer );
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
const int skipWidth = ( trTypeHor != DCT2 && width == 32 ) ? 16 : width > JVET_C0024_ZERO_OUT_TH ? width - JVET_C0024_ZERO_OUT_TH : 0;
const int skipHeight = ( trTypeVer != DCT2 && height == 32 ) ? 16 : height > JVET_C0024_ZERO_OUT_TH ? height - JVET_C0024_ZERO_OUT_TH : 0;
#else
......
......@@ -84,7 +84,7 @@
#define JVET_O0364_PDPC_DC 1 // JVET-O0364 Part 4: align PDPC process for DC with the one for Planar
#define JVET_O0364_PDPC_ANGULAR 1 // JVET-O0364 Part 5: simplify PDPC process for angular modes
#define JVET_O0049_LFNST_ZERO_PRIM_COEFFS 1 // JVET-O0049: CE6-2.1a, LFNST involves zeroing of primary only coefficient positions
#define JVET_O0094_LFNST_ZERO_PRIM_COEFFS 1 // JVET-O0049: CE6-2.1a, LFNST involves zeroing of primary only coefficient positions
#define FIX_DB_MAX_TRANSFORM_SIZE 1
......
......@@ -261,7 +261,7 @@ uint32_t CU::getNumNonZeroCoeffNonTs( const CodingUnit& cu, const bool lumaFlag,
return count;
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
uint32_t CU::getNumNonZeroCoeffNonTsCorner8x8( const CodingUnit& cu, const bool lumaFlag, const bool chromaFlag )
{
uint32_t count = 0;
......@@ -4535,7 +4535,7 @@ uint32_t TU::getNumNonZeroCoeffsNonTS( const TransformUnit& tu, const bool bLuma
}
return count;
}
#if !JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if !JVET_O0094_LFNST_ZERO_PRIM_COEFFS
uint32_t TU::getNumNonZeroCoeffsNonTSCorner8x8( const TransformUnit& tu, const bool lumaFlag, const bool chromaFlag )
{
const uint32_t lumaWidth = tu.blocks[ 0 ].width, chromaWidth = tu.blocks[ 1 ].width;
......
......@@ -1355,7 +1355,7 @@ void CABACReader::cu_residual( CodingUnit& cu, Partitioner &partitioner, CUCtx&
return;
}
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_LUMA] = false;
cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_CHROMA] = false;
#endif
......@@ -1370,7 +1370,7 @@ void CABACReader::cu_residual( CodingUnit& cu, Partitioner &partitioner, CUCtx&
{
transform_tree( *cu.cs, partitioner, cuCtx, chromaCbfs );
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
residual_lfnst_mode( cu, cuCtx );
#else
residual_lfnst_mode( cu );
......@@ -2343,7 +2343,7 @@ void CABACReader::transform_unit( TransformUnit& tu, CUCtx& cuCtx, ChromaCbfs& c
}
if( cbfLuma )
{
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
residual_coding( tu, COMPONENT_Y, cuCtx );
#else
residual_coding( tu, COMPONENT_Y );
......@@ -2359,7 +2359,7 @@ void CABACReader::transform_unit( TransformUnit& tu, CUCtx& cuCtx, ChromaCbfs& c
}
if( tu.cbf[ compID ] )
{
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
residual_coding( tu, compID, cuCtx );
#else
residual_coding( tu, compID );
......@@ -2430,7 +2430,7 @@ void CABACReader::joint_cb_cr( TransformUnit& tu )
tu.jointCbCr = m_BinDecoder.decodeBin( Ctx::JointCbCrFlag( 0 ) );
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void CABACReader::residual_coding( TransformUnit& tu, ComponentID compID, CUCtx& cuCtx )
#else
void CABACReader::residual_coding( TransformUnit& tu, ComponentID compID )
......@@ -2477,7 +2477,7 @@ void CABACReader::residual_coding( TransformUnit& tu, ComponentID compID )
// parse last coeff position
cctx.setScanPosLast( last_sig_coeff( cctx, tu, compID ) );
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( tu.mtsIdx != MTS_SKIP && tu.blocks[ compID ].height >= 4 && tu.blocks[ compID ].width >= 4 )
{
const int maxLfnstPos = ((tu.blocks[compID].height == 4 && tu.blocks[compID].width == 4) || (tu.blocks[compID].height == 8 && tu.blocks[compID].width == 8)) ? 7 : 15;
......@@ -2619,7 +2619,7 @@ void CABACReader::explicit_rdpcm_mode( TransformUnit& tu, ComponentID compID )
}
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void CABACReader::residual_lfnst_mode( CodingUnit& cu, CUCtx& cuCtx )
#else
void CABACReader::residual_lfnst_mode( CodingUnit& cu )
......@@ -2638,7 +2638,7 @@ void CABACReader::residual_lfnst_mode( CodingUnit& cu )
const bool lumaFlag = CS::isDualITree( *cu.cs ) ? ( isLuma( cu.chType ) ? true : false ) : true;
const bool chromaFlag = CS::isDualITree( *cu.cs ) ? ( isChroma( cu.chType ) ? true : false ) : true;
bool nonZeroCoeffNonTs;
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
bool nonZeroCoeffNonTsCorner8x8 = ( lumaFlag && cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_LUMA] ) || (chromaFlag && cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_CHROMA] );
#else
bool nonZeroCoeffNonTsCorner8x8 = CU::getNumNonZeroCoeffNonTsCorner8x8( cu, lumaFlag, chromaFlag ) > 0;
......
......@@ -129,13 +129,13 @@ public:
void cu_chroma_qp_offset ( CodingUnit& cu );
// residual coding (clause 7.3.8.11)
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void residual_coding ( TransformUnit& tu, ComponentID compID, CUCtx& cuCtx );
#else
void residual_coding ( TransformUnit& tu, ComponentID compID );
#endif
void mts_coding ( TransformUnit& tu, ComponentID compID );
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void residual_lfnst_mode ( CodingUnit& cu, CUCtx& cuCtx );
#else
void residual_lfnst_mode ( CodingUnit& cu );
......
......@@ -1249,7 +1249,7 @@ void CABACWriter::cu_residual( const CodingUnit& cu, Partitioner& partitioner, C
}
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_LUMA] = false;
cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_CHROMA] = false;
#endif
......@@ -2219,7 +2219,7 @@ void CABACWriter::transform_unit( const TransformUnit& tu, CUCtx& cuCtx, ChromaC
}
if( cbfLuma )
{
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
residual_coding( tu, COMPONENT_Y, &cuCtx );
#else
residual_coding( tu, COMPONENT_Y );
......@@ -2235,7 +2235,7 @@ void CABACWriter::transform_unit( const TransformUnit& tu, CUCtx& cuCtx, ChromaC
}
if( cbf[ compID ] )
{
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
residual_coding( tu, compID, &cuCtx );
#else
residual_coding( tu, compID );
......@@ -2307,7 +2307,7 @@ void CABACWriter::joint_cb_cr( const TransformUnit& tu )
m_BinEncoder.encodeBin( tu.jointCbCr ? 1 : 0, Ctx::JointCbCrFlag( 0 ) );
}
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void CABACWriter::residual_coding( const TransformUnit& tu, ComponentID compID, CUCtx* cuCtx )
#else
void CABACWriter::residual_coding( const TransformUnit& tu, ComponentID compID)
......@@ -2367,7 +2367,7 @@ void CABACWriter::residual_coding( const TransformUnit& tu, ComponentID compID)
CHECK( scanPosLast < 0, "Coefficient coding called for empty TU" );
cctx.setScanPosLast(scanPosLast);
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
if( cuCtx && tu.mtsIdx != MTS_SKIP && tu.blocks[ compID ].height >= 4 && tu.blocks[ compID ].width >= 4 )
{
const int maxLfnstPos = ((tu.blocks[compID].height == 4 && tu.blocks[compID].width == 4) || (tu.blocks[compID].height == 8 && tu.blocks[compID].width == 8)) ? 7 : 15;
......@@ -2510,7 +2510,7 @@ void CABACWriter::residual_lfnst_mode( const CodingUnit& cu, CUCtx& cuCtx )
const bool lumaFlag = CS::isDualITree( *cu.cs ) ? ( isLuma( cu.chType ) ? true : false ) : true;
const bool chromaFlag = CS::isDualITree( *cu.cs ) ? ( isChroma( cu.chType ) ? true : false ) : true;
bool nonZeroCoeffNonTs;
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
bool nonZeroCoeffNonTsCorner8x8 = ( lumaFlag && cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_LUMA] ) || (chromaFlag && cuCtx.violatesLfnstConstrained[CHANNEL_TYPE_CHROMA] );
#else
bool nonZeroCoeffNonTsCorner8x8 = CU::getNumNonZeroCoeffNonTsCorner8x8( cu, lumaFlag, chromaFlag ) > 0;
......
......@@ -141,7 +141,7 @@ public:
void cu_chroma_qp_offset ( const CodingUnit& cu );
// residual coding (clause 7.3.8.11)
#if JVET_O0049_LFNST_ZERO_PRIM_COEFFS
#if JVET_O0094_LFNST_ZERO_PRIM_COEFFS
void residual_coding ( const TransformUnit& tu, ComponentID compID, CUCtx* cuCtx = nullptr );
#else
void residual_coding ( const TransformUnit& tu, ComponentID compID );
......
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