[x265-commits] [x265] simplify AMVPInfo to MV[2]
Satoshi Nakagawa
nakagawa424 at oki.com
Fri Aug 22 00:00:35 CEST 2014
details: http://hg.videolan.org/x265/rev/97ea21754381
branches:
changeset: 7846:97ea21754381
user: Satoshi Nakagawa <nakagawa424 at oki.com>
date: Thu Aug 21 18:34:53 2014 +0900
description:
simplify AMVPInfo to MV[2]
Subject: [x265] encoder: disable --cu-lossless until coding errors can be fixed (refs #73)
details: http://hg.videolan.org/x265/rev/c1e4fc0162c1
branches: stable
changeset: 7847:c1e4fc0162c1
user: Steve Borho <steve at borho.org>
date: Thu Aug 21 16:49:02 2014 -0500
description:
encoder: disable --cu-lossless until coding errors can be fixed (refs #73)
Subject: [x265] Added tag 1.3 for changeset c1e4fc0162c1
details: http://hg.videolan.org/x265/rev/2e7d1569845e
branches: stable
changeset: 7848:2e7d1569845e
user: Steve Borho <steve at borho.org>
date: Thu Aug 21 16:50:35 2014 -0500
description:
Added tag 1.3 for changeset c1e4fc0162c1
diffstat:
.hgtags | 1 +
doc/reST/introduction.rst | 4 +-
source/Lib/TLibCommon/TComDataCU.cpp | 75 ++--
source/Lib/TLibCommon/TComDataCU.h | 9 +-
source/Lib/TLibCommon/TComPattern.cpp | 4 +-
source/Lib/TLibCommon/TComPicSym.cpp | 14 +-
source/Lib/TLibCommon/TComPicSym.h | 7 +
source/Lib/TLibCommon/TComPicYuv.cpp | 15 +-
source/Lib/TLibCommon/TComPicYuv.h | 2 +-
source/Lib/TLibCommon/TComRom.cpp | 42 +-
source/Lib/TLibCommon/TComRom.h | 22 +-
source/Lib/TLibCommon/TComSampleAdaptiveOffset.cpp | 5 +-
source/Lib/TLibEncoder/TEncSearch.cpp | 307 +++++++++--------
source/common/deblock.cpp | 31 +-
source/common/deblock.h | 2 +-
source/common/frame.cpp | 4 +-
source/common/frame.h | 4 +
source/common/param.cpp | 26 +-
source/common/quant.cpp | 10 +-
source/common/slice.h | 1 +
source/encoder/analysis.cpp | 344 ++++++++++++++------
source/encoder/analysis.h | 32 +-
source/encoder/cturow.cpp | 8 +-
source/encoder/cturow.h | 20 +-
source/encoder/encoder.cpp | 54 ++-
source/encoder/encoder.h | 1 +
source/encoder/entropy.cpp | 190 +---------
source/encoder/entropy.h | 19 +-
source/encoder/frameencoder.cpp | 57 +-
source/encoder/frameencoder.h | 1 -
30 files changed, 704 insertions(+), 607 deletions(-)
diffs (truncated from 2878 to 300 lines):
diff -r 9461fc801cd2 -r 2e7d1569845e .hgtags
--- a/.hgtags Wed Aug 20 14:57:41 2014 -0500
+++ b/.hgtags Thu Aug 21 16:50:35 2014 -0500
@@ -14,3 +14,4 @@ 82bbd2bf3b49ba086be0f0922f91fe0084896351
cea97c4d79456842e00ade6be6fd5ec34610e5f8 1.0
ae9609aeebdc3271114168ece003679e9b1dca1b 1.1
d6257335c5370ee54317a0426a12c1f0724b18b9 1.2
+c1e4fc0162c14fdb84f5c3bd404fb28cfe10a17f 1.3
diff -r 9461fc801cd2 -r 2e7d1569845e doc/reST/introduction.rst
--- a/doc/reST/introduction.rst Wed Aug 20 14:57:41 2014 -0500
+++ b/doc/reST/introduction.rst Thu Aug 21 16:50:35 2014 -0500
@@ -74,8 +74,8 @@ executable software created from the x26
responsible for understanding the laws in your country, and for
licensing all applicable patent rights needed for use or distribution of
software applications created from the x265 source code. A good place
-to start is with the `Motion Picture Experts Group - Licensing Authority
-- HEVC Licensing Program<http://www.mpegla.com/main/PID/HEVC/default.aspx>`_.
+to start is with the Motion Picture Experts Group - Licensing Authority
+- HEVC Licensing Program.
x265 is a registered trademark of MulticoreWare, Inc. The x265 logo is
a trademark of MulticoreWare, and may only be used with explicit written
diff -r 9461fc801cd2 -r 2e7d1569845e source/Lib/TLibCommon/TComDataCU.cpp
--- a/source/Lib/TLibCommon/TComDataCU.cpp Wed Aug 20 14:57:41 2014 -0500
+++ b/source/Lib/TLibCommon/TComDataCU.cpp Thu Aug 21 16:50:35 2014 -0500
@@ -129,7 +129,7 @@ fail:
return ok;
}
-void TComDataCU::create(TComDataCU *cu, uint32_t numPartition, uint32_t cuSize, int csp, int index, bool isLossless)
+void TComDataCU::create(TComDataCU *cu, uint32_t numPartition, uint32_t cuSize, int unitSize, int csp, int index, bool isLossless)
{
m_hChromaShift = CHROMA_H_SHIFT(csp);
m_vChromaShift = CHROMA_V_SHIFT(csp);
@@ -139,6 +139,12 @@ void TComDataCU::create(TComDataCU *cu,
m_slice = NULL;
m_numPartitions = numPartition;
+ uint32_t tmp = 4 * AMVP_DECIMATION_FACTOR / unitSize;
+ tmp = tmp * tmp;
+ X265_CHECK(tmp == (1 << (g_log2Size[tmp])), "unexpected pixel count\n");
+ tmp = g_log2Size[tmp];
+ m_unitMask = ~((1 << tmp) - 1);
+
uint32_t sizeL = cuSize * cuSize;
uint32_t sizeC = sizeL >> (m_hChromaShift + m_vChromaShift);
@@ -571,7 +577,7 @@ void TComDataCU::copyPartFrom(TComDataCU
// Copy current predicted part to a CU in picture.
// It is used to predict for next part
-void TComDataCU::copyToPic(uint32_t depth)
+void TComDataCU::copyToPic(uint8_t depth)
{
TComDataCU* cu = m_pic->getCU(m_cuAddr);
@@ -616,7 +622,7 @@ void TComDataCU::copyToPic(uint32_t dept
m_cuMvField[1].copyTo(cu->getCUMvField(REF_PIC_LIST_1), m_absIdxInLCU);
uint32_t tmpY = 1 << ((g_maxLog2CUSize - depth) * 2);
- uint32_t tmpY2 = m_absIdxInLCU << LOG2_UNIT_SIZE * 2;
+ uint32_t tmpY2 = m_absIdxInLCU << m_pic->getLog2UnitSize() * 2;
memcpy(cu->getCoeffY() + tmpY2, m_trCoeff[0], sizeof(coeff_t) * tmpY);
uint32_t tmpC = tmpY >> (m_hChromaShift + m_vChromaShift);
@@ -627,7 +633,7 @@ void TComDataCU::copyToPic(uint32_t dept
if (m_slice->m_pps->bTransquantBypassEnabled)
{
uint32_t tmp = 1 << ((g_maxLog2CUSize - depth) * 2);
- uint32_t tmp2 = m_absIdxInLCU << LOG2_UNIT_SIZE * 2;
+ uint32_t tmp2 = m_absIdxInLCU << m_pic->getLog2UnitSize() * 2;
memcpy(cu->getLumaOrigYuv() + tmp2, m_tqBypassOrigYuv[0], sizeof(pixel) * tmp);
memcpy(cu->getChromaOrigYuv(1) + tmpC2, m_tqBypassOrigYuv[1], sizeof(pixel) * tmpC);
@@ -635,7 +641,7 @@ void TComDataCU::copyToPic(uint32_t dept
}
}
-void TComDataCU::copyCodedToPic(uint32_t depth)
+void TComDataCU::copyCodedToPic(uint8_t depth)
{
TComDataCU* cu = m_pic->getCU(m_cuAddr);
@@ -654,7 +660,7 @@ void TComDataCU::copyCodedToPic(uint32_t
memcpy(cu->getCbf(TEXT_CHROMA_V) + m_absIdxInLCU, m_cbf[2], sizeInChar);
uint32_t tmpY = 1 << ((g_maxLog2CUSize - depth) * 2);
- uint32_t tmpY2 = m_absIdxInLCU << LOG2_UNIT_SIZE * 2;
+ uint32_t tmpY2 = m_absIdxInLCU << m_pic->getLog2UnitSize() * 2;
memcpy(cu->getCoeffY() + tmpY2, m_trCoeff[0], sizeof(coeff_t) * tmpY);
tmpY >>= m_hChromaShift + m_vChromaShift;
tmpY2 >>= m_hChromaShift + m_vChromaShift;
@@ -662,7 +668,7 @@ void TComDataCU::copyCodedToPic(uint32_t
memcpy(cu->m_trCoeff[2] + tmpY2, m_trCoeff[2], sizeof(coeff_t) * tmpY);
}
-void TComDataCU::copyToPic(uint32_t depth, uint32_t partIdx, uint32_t partDepth)
+void TComDataCU::copyToPic(uint8_t depth, uint32_t partIdx, uint32_t partDepth)
{
TComDataCU* cu = m_pic->getCU(m_cuAddr);
uint32_t qNumPart = m_numPartitions >> (partDepth << 1);
@@ -707,7 +713,7 @@ void TComDataCU::copyToPic(uint32_t dept
m_cuMvField[1].copyTo(cu->getCUMvField(REF_PIC_LIST_1), m_absIdxInLCU, partStart, qNumPart);
uint32_t tmpY = 1 << ((g_maxLog2CUSize - depth - partDepth) * 2);
- uint32_t tmpY2 = partOffset << LOG2_UNIT_SIZE * 2;
+ uint32_t tmpY2 = partOffset << m_pic->getLog2UnitSize() * 2;
memcpy(cu->getCoeffY() + tmpY2, m_trCoeff[0], sizeof(coeff_t) * tmpY);
uint32_t tmpC = tmpY >> (m_hChromaShift + m_vChromaShift);
@@ -819,7 +825,7 @@ TComDataCU* TComDataCU::getPUAboveRight(
uint32_t absPartIdxRT = g_zscanToRaster[curPartUnitIdx];
uint32_t numPartInCUSize = m_pic->getNumPartInCUSize();
- if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxRT] + UNIT_SIZE) >= m_slice->m_sps->picWidthInLumaSamples)
+ if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxRT] + m_pic->getUnitSize()) >= m_slice->m_sps->picWidthInLumaSamples)
return NULL;
if (RasterAddress::lessThanCol(absPartIdxRT, numPartInCUSize - 1, numPartInCUSize))
@@ -828,7 +834,7 @@ TComDataCU* TComDataCU::getPUAboveRight(
{
if (curPartUnitIdx > g_rasterToZscan[absPartIdxRT - numPartInCUSize + 1])
{
- uint32_t absZorderCUIdx = g_zscanToRaster[m_absIdxInLCU] + (1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1;
+ uint32_t absZorderCUIdx = g_zscanToRaster[m_absIdxInLCU] + (1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1;
arPartUnitIdx = g_rasterToZscan[absPartIdxRT - numPartInCUSize + 1];
if (RasterAddress::isEqualRowOrCol(absPartIdxRT, absZorderCUIdx, numPartInCUSize))
{
@@ -859,7 +865,7 @@ TComDataCU* TComDataCU::getPUBelowLeft(u
{
uint32_t absPartIdxLB = g_zscanToRaster[curPartUnitIdx];
- if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxLB] + UNIT_SIZE) >= m_slice->m_sps->picHeightInLumaSamples)
+ if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxLB] + m_pic->getUnitSize()) >= m_slice->m_sps->picHeightInLumaSamples)
{
return NULL;
}
@@ -872,7 +878,7 @@ TComDataCU* TComDataCU::getPUBelowLeft(u
{
if (curPartUnitIdx > g_rasterToZscan[absPartIdxLB + numPartInCUSize - 1])
{
- uint32_t absZorderCUIdxLB = g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1) * m_pic->getNumPartInCUSize();
+ uint32_t absZorderCUIdxLB = g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1) * m_pic->getNumPartInCUSize();
blPartUnitIdx = g_rasterToZscan[absPartIdxLB + numPartInCUSize - 1];
if (RasterAddress::isEqualRowOrCol(absPartIdxLB, absZorderCUIdxLB, numPartInCUSize))
{
@@ -897,7 +903,7 @@ TComDataCU* TComDataCU::getPUBelowLeftAd
{
uint32_t absPartIdxLB = g_zscanToRaster[curPartUnitIdx];
- if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxLB] + (partUnitOffset << LOG2_UNIT_SIZE)) >=
+ if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxLB] + (partUnitOffset << m_pic->getLog2UnitSize())) >=
m_slice->m_sps->picHeightInLumaSamples)
{
return NULL;
@@ -911,7 +917,7 @@ TComDataCU* TComDataCU::getPUBelowLeftAd
{
if (curPartUnitIdx > g_rasterToZscan[absPartIdxLB + partUnitOffset * numPartInCUSize - 1])
{
- uint32_t absZorderCUIdxLB = g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1) * m_pic->getNumPartInCUSize();
+ uint32_t absZorderCUIdxLB = g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1) * m_pic->getNumPartInCUSize();
blPartUnitIdx = g_rasterToZscan[absPartIdxLB + partUnitOffset * numPartInCUSize - 1];
if (RasterAddress::isEqualRowOrCol(absPartIdxLB, absZorderCUIdxLB, numPartInCUSize))
{
@@ -940,7 +946,7 @@ TComDataCU* TComDataCU::getPUAboveRightA
{
uint32_t absPartIdxRT = g_zscanToRaster[curPartUnitIdx];
- if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxRT] + (partUnitOffset << LOG2_UNIT_SIZE)) >=
+ if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxRT] + (partUnitOffset << m_pic->getLog2UnitSize())) >=
m_slice->m_sps->picWidthInLumaSamples)
{
return NULL;
@@ -954,7 +960,7 @@ TComDataCU* TComDataCU::getPUAboveRightA
{
if (curPartUnitIdx > g_rasterToZscan[absPartIdxRT - numPartInCUSize + partUnitOffset])
{
- uint32_t absZorderCUIdx = g_zscanToRaster[m_absIdxInLCU] + (1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1;
+ uint32_t absZorderCUIdx = g_zscanToRaster[m_absIdxInLCU] + (1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1;
arPartUnitIdx = g_rasterToZscan[absPartIdxRT - numPartInCUSize + partUnitOffset];
if (RasterAddress::isEqualRowOrCol(absPartIdxRT, absZorderCUIdx, numPartInCUSize))
{
@@ -998,7 +1004,8 @@ TComDataCU* TComDataCU::getPUAboveRightA
TComDataCU* TComDataCU::getQpMinCuLeft(uint32_t& lPartUnitIdx, uint32_t curAbsIdxInLCU)
{
uint32_t numPartInCUSize = m_pic->getNumPartInCUSize();
- uint32_t absZorderQpMinCUIdx = curAbsIdxInLCU & (0xFF << (g_maxFullDepth - m_slice->m_pps->maxCuDQPDepth) * 2);
+ uint32_t absZorderQpMinCUIdx = (curAbsIdxInLCU >> ((g_maxCUDepth - m_slice->m_pps->maxCuDQPDepth) << 1)) <<
+ ((g_maxCUDepth - m_slice->m_pps->maxCuDQPDepth) << 1);
uint32_t absRorderQpMinCUIdx = g_zscanToRaster[absZorderQpMinCUIdx];
// check for left LCU boundary
@@ -1022,7 +1029,8 @@ TComDataCU* TComDataCU::getQpMinCuLeft(u
TComDataCU* TComDataCU::getQpMinCuAbove(uint32_t& aPartUnitIdx, uint32_t curAbsIdxInLCU)
{
uint32_t numPartInCUSize = m_pic->getNumPartInCUSize();
- uint32_t absZorderQpMinCUIdx = curAbsIdxInLCU & (0xFF << (g_maxFullDepth - m_slice->m_pps->maxCuDQPDepth) * 2);
+ uint32_t absZorderQpMinCUIdx = (curAbsIdxInLCU >> ((g_maxCUDepth - m_slice->m_pps->maxCuDQPDepth) << 1)) <<
+ ((g_maxCUDepth - m_slice->m_pps->maxCuDQPDepth) << 1);
uint32_t absRorderQpMinCUIdx = g_zscanToRaster[absZorderQpMinCUIdx];
// check for top LCU boundary
@@ -1066,7 +1074,7 @@ int TComDataCU::getLastValidPartIdx(int
char TComDataCU::getLastCodedQP(uint32_t absPartIdx)
{
- uint32_t quPartIdxMask = 0xFF << (g_maxFullDepth - m_slice->m_pps->maxCuDQPDepth) * 2;
+ uint32_t quPartIdxMask = ~((1 << ((g_maxCUDepth - m_slice->m_pps->maxCuDQPDepth) << 1)) - 1);
int lastValidPartIdx = getLastValidPartIdx(absPartIdx & quPartIdxMask);
if (lastValidPartIdx >= 0)
@@ -1518,7 +1526,7 @@ void TComDataCU::getMvField(TComDataCU*
void TComDataCU::deriveLeftRightTopIdx(uint32_t partIdx, uint32_t& ruiPartIdxLT, uint32_t& ruiPartIdxRT)
{
ruiPartIdxLT = m_absIdxInLCU;
- ruiPartIdxRT = g_rasterToZscan[g_zscanToRaster[ruiPartIdxLT] + (1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1];
+ ruiPartIdxRT = g_rasterToZscan[g_zscanToRaster[ruiPartIdxLT] + (1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1];
switch (m_partSizes[0])
{
@@ -1559,7 +1567,7 @@ void TComDataCU::deriveLeftRightTopIdx(u
void TComDataCU::deriveLeftBottomIdx(uint32_t partIdx, uint32_t& outPartIdxLB)
{
- outPartIdxLB = g_rasterToZscan[g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE - 1)) - 1) * m_pic->getNumPartInCUSize()];
+ outPartIdxLB = g_rasterToZscan[g_zscanToRaster[m_absIdxInLCU] + ((1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize() - 1)) - 1) * m_pic->getNumPartInCUSize()];
switch (m_partSizes[0])
{
@@ -1601,8 +1609,8 @@ void TComDataCU::deriveLeftBottomIdx(uin
void TComDataCU::deriveRightBottomIdx(uint32_t partIdx, uint32_t& outPartIdxRB)
{
outPartIdxRB = g_rasterToZscan[g_zscanToRaster[m_absIdxInLCU] +
- ((1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE - 1)) - 1) * m_pic->getNumPartInCUSize() +
- (1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE)) - 1];
+ ((1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize() - 1)) - 1) * m_pic->getNumPartInCUSize() +
+ (1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize())) - 1];
switch (m_partSizes[0])
{
@@ -1638,7 +1646,7 @@ void TComDataCU::deriveRightBottomIdx(ui
void TComDataCU::deriveLeftRightTopIdxAdi(uint32_t& outPartIdxLT, uint32_t& outPartIdxRT, uint32_t partOffset, uint32_t partDepth)
{
- uint32_t numPartInWidth = 1 << (m_log2CUSize[0] - LOG2_UNIT_SIZE - partDepth);
+ uint32_t numPartInWidth = 1 << (m_log2CUSize[0] - m_pic->getLog2UnitSize() - partDepth);
outPartIdxLT = m_absIdxInLCU + partOffset;
outPartIdxRT = g_rasterToZscan[g_zscanToRaster[outPartIdxLT] + numPartInWidth - 1];
@@ -1829,10 +1837,10 @@ void TComDataCU::getInterMergeCandidates
int refIdx;
int lcuIdx = -1;
- if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxTmp] + UNIT_SIZE) >= m_slice->m_sps->picWidthInLumaSamples) // image boundary check
+ if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdxTmp] + m_pic->getUnitSize()) >= m_slice->m_sps->picWidthInLumaSamples) // image boundary check
{
}
- else if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxTmp] + UNIT_SIZE) >= m_slice->m_sps->picHeightInLumaSamples)
+ else if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdxTmp] + m_pic->getUnitSize()) >= m_slice->m_sps->picHeightInLumaSamples)
{
}
else
@@ -2099,10 +2107,10 @@ int TComDataCU::fillMvpCand(uint32_t par
//---- co-located RightBottom Temporal Predictor (H) ---//
absPartIdx = g_zscanToRaster[partIdxRB];
int lcuIdx = -1;
- if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdx] + UNIT_SIZE) >= m_slice->m_sps->picWidthInLumaSamples) // image boundary check
+ if ((m_pic->getCU(m_cuAddr)->getCUPelX() + g_rasterToPelX[absPartIdx] + m_pic->getUnitSize()) >= m_slice->m_sps->picWidthInLumaSamples) // image boundary check
{
}
- else if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdx] + UNIT_SIZE) >= m_slice->m_sps->picHeightInLumaSamples)
+ else if ((m_pic->getCU(m_cuAddr)->getCUPelY() + g_rasterToPelY[absPartIdx] + m_pic->getUnitSize()) >= m_slice->m_sps->picHeightInLumaSamples)
{
}
else
@@ -2334,7 +2342,7 @@ bool TComDataCU::xAddMVPCandOrder(MV& ou
*/
bool TComDataCU::xGetColMVP(int picList, int cuAddr, int partUnitIdx, MV& outMV, int& outRefIdx)
{
- uint32_t absPartAddr = partUnitIdx & TMVP_UNIT_MASK;
+ uint32_t absPartAddr = partUnitIdx & m_unitMask;
int colRefPicList;
int colPOC, colRefPOC, curPOC, curRefPOC, scale;
@@ -2416,8 +2424,8 @@ void TComDataCU::xDeriveCenterIdx(uint32
outPartIdxCenter = m_absIdxInLCU + partAddr; // partition origin.
outPartIdxCenter = g_rasterToZscan[g_zscanToRaster[outPartIdxCenter]
- + (partHeight >> (LOG2_UNIT_SIZE + 1)) * m_pic->getNumPartInCUSize()
- + (partWidth >> (LOG2_UNIT_SIZE + 1))];
+ + (partHeight >> (m_pic->getLog2UnitSize() + 1)) * m_pic->getNumPartInCUSize()
+ + (partWidth >> (m_pic->getLog2UnitSize() + 1))];
}
ScanType TComDataCU::getCoefScanIdx(uint32_t absPartIdx, uint32_t log2TrSize, bool bIsLuma, bool bIsIntra)
@@ -2444,7 +2452,8 @@ ScanType TComDataCU::getCoefScanIdx(uint
dirMode = getChromaIntraDir(absPartIdx);
if (dirMode == DM_CHROMA_IDX)
{
- dirMode = getLumaIntraDir((m_chromaFormat == X265_CSP_I444) ? absPartIdx : absPartIdx & 0xFC);
More information about the x265-commits
mailing list