[313] | 1 | /* The copyright in this software is being made available under the BSD |
---|
| 2 | * License, included below. This software may be subject to other third party |
---|
| 3 | * and contributor rights, including patent rights, and no such rights are |
---|
| 4 | * granted under this license. |
---|
| 5 | * |
---|
[595] | 6 | * Copyright (c) 2010-2014, ITU/ISO/IEC |
---|
[313] | 7 | * All rights reserved. |
---|
| 8 | * |
---|
| 9 | * Redistribution and use in source and binary forms, with or without |
---|
| 10 | * modification, are permitted provided that the following conditions are met: |
---|
| 11 | * |
---|
| 12 | * * Redistributions of source code must retain the above copyright notice, |
---|
| 13 | * this list of conditions and the following disclaimer. |
---|
| 14 | * * Redistributions in binary form must reproduce the above copyright notice, |
---|
| 15 | * this list of conditions and the following disclaimer in the documentation |
---|
| 16 | * and/or other materials provided with the distribution. |
---|
| 17 | * * Neither the name of the ITU/ISO/IEC nor the names of its contributors may |
---|
| 18 | * be used to endorse or promote products derived from this software without |
---|
| 19 | * specific prior written permission. |
---|
| 20 | * |
---|
| 21 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
---|
| 22 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
---|
| 23 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE |
---|
| 24 | * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS |
---|
| 25 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR |
---|
| 26 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF |
---|
| 27 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS |
---|
| 28 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN |
---|
| 29 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) |
---|
| 30 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF |
---|
| 31 | * THE POSSIBILITY OF SUCH DAMAGE. |
---|
| 32 | */ |
---|
| 33 | |
---|
| 34 | /** \file TDecCu.cpp |
---|
| 35 | \brief CU decoder class |
---|
| 36 | */ |
---|
| 37 | |
---|
| 38 | #include "TDecCu.h" |
---|
| 39 | #if SVC_EXTENSION |
---|
| 40 | #include "TDecTop.h" |
---|
| 41 | #endif |
---|
| 42 | |
---|
| 43 | |
---|
| 44 | //! \ingroup TLibDecoder |
---|
| 45 | //! \{ |
---|
| 46 | |
---|
| 47 | // ==================================================================================================================== |
---|
| 48 | // Constructor / destructor / create / destroy |
---|
| 49 | // ==================================================================================================================== |
---|
| 50 | |
---|
| 51 | TDecCu::TDecCu() |
---|
| 52 | { |
---|
| 53 | m_ppcYuvResi = NULL; |
---|
| 54 | m_ppcYuvReco = NULL; |
---|
| 55 | m_ppcCU = NULL; |
---|
| 56 | } |
---|
| 57 | |
---|
| 58 | TDecCu::~TDecCu() |
---|
| 59 | { |
---|
| 60 | } |
---|
| 61 | |
---|
| 62 | #if SVC_EXTENSION |
---|
| 63 | Void TDecCu::init(TDecTop** ppcDecTop, TDecEntropy* pcEntropyDecoder, TComTrQuant* pcTrQuant, TComPrediction* pcPrediction, UInt layerId) |
---|
| 64 | { |
---|
| 65 | m_pcEntropyDecoder = pcEntropyDecoder; |
---|
| 66 | m_pcTrQuant = pcTrQuant; |
---|
| 67 | m_pcPrediction = pcPrediction; |
---|
| 68 | m_ppcTDecTop = ppcDecTop; |
---|
| 69 | m_layerId = layerId; |
---|
| 70 | |
---|
| 71 | for ( UInt ui = 0; ui < m_uiMaxDepth-1; ui++ ) |
---|
| 72 | { |
---|
| 73 | m_ppcCU [ui]->setLayerId(layerId); |
---|
| 74 | } |
---|
[658] | 75 | |
---|
| 76 | #if LAYER_CTB |
---|
| 77 | memcpy(g_auiLayerZscanToRaster[m_layerId], g_auiZscanToRaster, sizeof( g_auiZscanToRaster ) ); |
---|
| 78 | memcpy(g_auiLayerRasterToZscan[m_layerId], g_auiRasterToZscan, sizeof( g_auiRasterToZscan ) ); |
---|
| 79 | memcpy(g_auiLayerRasterToPelX[m_layerId], g_auiRasterToPelX, sizeof( g_auiRasterToPelX ) ); |
---|
| 80 | memcpy(g_auiLayerRasterToPelY[m_layerId], g_auiRasterToPelY, sizeof( g_auiRasterToPelY ) ); |
---|
| 81 | #endif |
---|
[313] | 82 | } |
---|
| 83 | #else |
---|
| 84 | Void TDecCu::init( TDecEntropy* pcEntropyDecoder, TComTrQuant* pcTrQuant, TComPrediction* pcPrediction) |
---|
| 85 | { |
---|
| 86 | m_pcEntropyDecoder = pcEntropyDecoder; |
---|
| 87 | m_pcTrQuant = pcTrQuant; |
---|
| 88 | m_pcPrediction = pcPrediction; |
---|
| 89 | } |
---|
| 90 | #endif |
---|
| 91 | |
---|
| 92 | /** |
---|
| 93 | \param uiMaxDepth total number of allowable depth |
---|
| 94 | \param uiMaxWidth largest CU width |
---|
| 95 | \param uiMaxHeight largest CU height |
---|
| 96 | */ |
---|
| 97 | Void TDecCu::create( UInt uiMaxDepth, UInt uiMaxWidth, UInt uiMaxHeight ) |
---|
| 98 | { |
---|
| 99 | m_uiMaxDepth = uiMaxDepth+1; |
---|
| 100 | |
---|
| 101 | m_ppcYuvResi = new TComYuv*[m_uiMaxDepth-1]; |
---|
| 102 | m_ppcYuvReco = new TComYuv*[m_uiMaxDepth-1]; |
---|
| 103 | m_ppcCU = new TComDataCU*[m_uiMaxDepth-1]; |
---|
| 104 | |
---|
| 105 | UInt uiNumPartitions; |
---|
| 106 | for ( UInt ui = 0; ui < m_uiMaxDepth-1; ui++ ) |
---|
| 107 | { |
---|
| 108 | uiNumPartitions = 1<<( ( m_uiMaxDepth - ui - 1 )<<1 ); |
---|
| 109 | UInt uiWidth = uiMaxWidth >> ui; |
---|
| 110 | UInt uiHeight = uiMaxHeight >> ui; |
---|
| 111 | |
---|
| 112 | m_ppcYuvResi[ui] = new TComYuv; m_ppcYuvResi[ui]->create( uiWidth, uiHeight ); |
---|
| 113 | m_ppcYuvReco[ui] = new TComYuv; m_ppcYuvReco[ui]->create( uiWidth, uiHeight ); |
---|
| 114 | m_ppcCU [ui] = new TComDataCU; m_ppcCU [ui]->create( uiNumPartitions, uiWidth, uiHeight, true, uiMaxWidth >> (m_uiMaxDepth - 1) ); |
---|
| 115 | } |
---|
| 116 | |
---|
| 117 | m_bDecodeDQP = false; |
---|
| 118 | |
---|
| 119 | // initialize partition order. |
---|
| 120 | UInt* piTmp = &g_auiZscanToRaster[0]; |
---|
| 121 | initZscanToRaster(m_uiMaxDepth, 1, 0, piTmp); |
---|
| 122 | initRasterToZscan( uiMaxWidth, uiMaxHeight, m_uiMaxDepth ); |
---|
| 123 | |
---|
| 124 | // initialize conversion matrix from partition index to pel |
---|
| 125 | initRasterToPelXY( uiMaxWidth, uiMaxHeight, m_uiMaxDepth ); |
---|
| 126 | } |
---|
| 127 | |
---|
| 128 | Void TDecCu::destroy() |
---|
| 129 | { |
---|
| 130 | for ( UInt ui = 0; ui < m_uiMaxDepth-1; ui++ ) |
---|
| 131 | { |
---|
| 132 | m_ppcYuvResi[ui]->destroy(); delete m_ppcYuvResi[ui]; m_ppcYuvResi[ui] = NULL; |
---|
| 133 | m_ppcYuvReco[ui]->destroy(); delete m_ppcYuvReco[ui]; m_ppcYuvReco[ui] = NULL; |
---|
| 134 | m_ppcCU [ui]->destroy(); delete m_ppcCU [ui]; m_ppcCU [ui] = NULL; |
---|
| 135 | } |
---|
| 136 | |
---|
| 137 | delete [] m_ppcYuvResi; m_ppcYuvResi = NULL; |
---|
| 138 | delete [] m_ppcYuvReco; m_ppcYuvReco = NULL; |
---|
| 139 | delete [] m_ppcCU ; m_ppcCU = NULL; |
---|
| 140 | } |
---|
| 141 | |
---|
| 142 | // ==================================================================================================================== |
---|
| 143 | // Public member functions |
---|
| 144 | // ==================================================================================================================== |
---|
| 145 | |
---|
| 146 | /** \param pcCU pointer of CU data |
---|
| 147 | \param ruiIsLast last data? |
---|
| 148 | */ |
---|
| 149 | Void TDecCu::decodeCU( TComDataCU* pcCU, UInt& ruiIsLast ) |
---|
| 150 | { |
---|
| 151 | if ( pcCU->getSlice()->getPPS()->getUseDQP() ) |
---|
| 152 | { |
---|
| 153 | setdQPFlag(true); |
---|
| 154 | } |
---|
| 155 | |
---|
| 156 | // start from the top level CU |
---|
| 157 | #if SVC_EXTENSION |
---|
| 158 | pcCU->setLayerId(m_layerId); |
---|
| 159 | #endif |
---|
| 160 | xDecodeCU( pcCU, 0, 0, ruiIsLast); |
---|
| 161 | } |
---|
| 162 | |
---|
| 163 | /** \param pcCU pointer of CU data |
---|
| 164 | */ |
---|
| 165 | Void TDecCu::decompressCU( TComDataCU* pcCU ) |
---|
| 166 | { |
---|
| 167 | xDecompressCU( pcCU, 0, 0 ); |
---|
| 168 | } |
---|
| 169 | |
---|
| 170 | // ==================================================================================================================== |
---|
| 171 | // Protected member functions |
---|
| 172 | // ==================================================================================================================== |
---|
| 173 | |
---|
| 174 | /**decode end-of-slice flag |
---|
| 175 | * \param pcCU |
---|
| 176 | * \param uiAbsPartIdx |
---|
| 177 | * \param uiDepth |
---|
| 178 | * \returns Bool |
---|
| 179 | */ |
---|
| 180 | Bool TDecCu::xDecodeSliceEnd( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth) |
---|
| 181 | { |
---|
| 182 | UInt uiIsLast; |
---|
| 183 | TComPic* pcPic = pcCU->getPic(); |
---|
| 184 | TComSlice * pcSlice = pcPic->getSlice(pcPic->getCurrSliceIdx()); |
---|
| 185 | UInt uiCurNumParts = pcPic->getNumPartInCU() >> (uiDepth<<1); |
---|
[442] | 186 | #if REPN_FORMAT_IN_VPS |
---|
| 187 | UInt uiWidth = pcSlice->getPicWidthInLumaSamples(); |
---|
| 188 | UInt uiHeight = pcSlice->getPicHeightInLumaSamples(); |
---|
| 189 | #else |
---|
[313] | 190 | UInt uiWidth = pcSlice->getSPS()->getPicWidthInLumaSamples(); |
---|
| 191 | UInt uiHeight = pcSlice->getSPS()->getPicHeightInLumaSamples(); |
---|
[442] | 192 | #endif |
---|
[313] | 193 | UInt uiGranularityWidth = g_uiMaxCUWidth; |
---|
| 194 | UInt uiPosX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 195 | UInt uiPosY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 196 | |
---|
| 197 | if(((uiPosX+pcCU->getWidth(uiAbsPartIdx))%uiGranularityWidth==0||(uiPosX+pcCU->getWidth(uiAbsPartIdx)==uiWidth)) |
---|
| 198 | &&((uiPosY+pcCU->getHeight(uiAbsPartIdx))%uiGranularityWidth==0||(uiPosY+pcCU->getHeight(uiAbsPartIdx)==uiHeight))) |
---|
| 199 | { |
---|
| 200 | m_pcEntropyDecoder->decodeTerminatingBit( uiIsLast ); |
---|
| 201 | } |
---|
| 202 | else |
---|
| 203 | { |
---|
| 204 | uiIsLast=0; |
---|
| 205 | } |
---|
| 206 | |
---|
| 207 | if(uiIsLast) |
---|
| 208 | { |
---|
| 209 | if(pcSlice->isNextSliceSegment()&&!pcSlice->isNextSlice()) |
---|
| 210 | { |
---|
| 211 | pcSlice->setSliceSegmentCurEndCUAddr(pcCU->getSCUAddr()+uiAbsPartIdx+uiCurNumParts); |
---|
| 212 | } |
---|
| 213 | else |
---|
| 214 | { |
---|
| 215 | pcSlice->setSliceCurEndCUAddr(pcCU->getSCUAddr()+uiAbsPartIdx+uiCurNumParts); |
---|
| 216 | pcSlice->setSliceSegmentCurEndCUAddr(pcCU->getSCUAddr()+uiAbsPartIdx+uiCurNumParts); |
---|
| 217 | } |
---|
| 218 | } |
---|
| 219 | |
---|
| 220 | return uiIsLast>0; |
---|
| 221 | } |
---|
| 222 | |
---|
| 223 | /** decode CU block recursively |
---|
| 224 | * \param pcCU |
---|
| 225 | * \param uiAbsPartIdx |
---|
| 226 | * \param uiDepth |
---|
| 227 | * \returns Void |
---|
| 228 | */ |
---|
| 229 | |
---|
| 230 | Void TDecCu::xDecodeCU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt& ruiIsLast) |
---|
| 231 | { |
---|
| 232 | TComPic* pcPic = pcCU->getPic(); |
---|
| 233 | UInt uiCurNumParts = pcPic->getNumPartInCU() >> (uiDepth<<1); |
---|
| 234 | UInt uiQNumParts = uiCurNumParts>>2; |
---|
| 235 | |
---|
| 236 | Bool bBoundary = false; |
---|
| 237 | UInt uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 238 | UInt uiRPelX = uiLPelX + (g_uiMaxCUWidth>>uiDepth) - 1; |
---|
| 239 | UInt uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 240 | UInt uiBPelY = uiTPelY + (g_uiMaxCUHeight>>uiDepth) - 1; |
---|
| 241 | |
---|
| 242 | TComSlice * pcSlice = pcCU->getPic()->getSlice(pcCU->getPic()->getCurrSliceIdx()); |
---|
| 243 | Bool bStartInCU = pcCU->getSCUAddr()+uiAbsPartIdx+uiCurNumParts>pcSlice->getSliceSegmentCurStartCUAddr()&&pcCU->getSCUAddr()+uiAbsPartIdx<pcSlice->getSliceSegmentCurStartCUAddr(); |
---|
[442] | 244 | #if REPN_FORMAT_IN_VPS |
---|
| 245 | if((!bStartInCU) && ( uiRPelX < pcSlice->getPicWidthInLumaSamples() ) && ( uiBPelY < pcSlice->getPicHeightInLumaSamples() ) ) |
---|
| 246 | #else |
---|
[313] | 247 | if((!bStartInCU) && ( uiRPelX < pcSlice->getSPS()->getPicWidthInLumaSamples() ) && ( uiBPelY < pcSlice->getSPS()->getPicHeightInLumaSamples() ) ) |
---|
[442] | 248 | #endif |
---|
[313] | 249 | { |
---|
| 250 | m_pcEntropyDecoder->decodeSplitFlag( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 251 | } |
---|
| 252 | else |
---|
| 253 | { |
---|
| 254 | bBoundary = true; |
---|
| 255 | } |
---|
| 256 | |
---|
| 257 | if( ( ( uiDepth < pcCU->getDepth( uiAbsPartIdx ) ) && ( uiDepth < g_uiMaxCUDepth - g_uiAddCUDepth ) ) || bBoundary ) |
---|
| 258 | { |
---|
| 259 | UInt uiIdx = uiAbsPartIdx; |
---|
| 260 | if( (g_uiMaxCUWidth>>uiDepth) == pcCU->getSlice()->getPPS()->getMinCuDQPSize() && pcCU->getSlice()->getPPS()->getUseDQP()) |
---|
| 261 | { |
---|
| 262 | setdQPFlag(true); |
---|
| 263 | pcCU->setQPSubParts( pcCU->getRefQP(uiAbsPartIdx), uiAbsPartIdx, uiDepth ); // set QP to default QP |
---|
| 264 | } |
---|
| 265 | |
---|
| 266 | for ( UInt uiPartUnitIdx = 0; uiPartUnitIdx < 4; uiPartUnitIdx++ ) |
---|
| 267 | { |
---|
| 268 | uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiIdx] ]; |
---|
| 269 | uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiIdx] ]; |
---|
| 270 | |
---|
| 271 | Bool bSubInSlice = pcCU->getSCUAddr()+uiIdx+uiQNumParts>pcSlice->getSliceSegmentCurStartCUAddr(); |
---|
| 272 | if ( bSubInSlice ) |
---|
| 273 | { |
---|
[442] | 274 | #if REPN_FORMAT_IN_VPS |
---|
| 275 | if ( !ruiIsLast && ( uiLPelX < pcCU->getSlice()->getPicWidthInLumaSamples() ) && ( uiTPelY < pcCU->getSlice()->getPicHeightInLumaSamples() ) ) |
---|
| 276 | #else |
---|
[313] | 277 | if ( !ruiIsLast && ( uiLPelX < pcCU->getSlice()->getSPS()->getPicWidthInLumaSamples() ) && ( uiTPelY < pcCU->getSlice()->getSPS()->getPicHeightInLumaSamples() ) ) |
---|
[442] | 278 | #endif |
---|
[313] | 279 | { |
---|
| 280 | xDecodeCU( pcCU, uiIdx, uiDepth+1, ruiIsLast ); |
---|
| 281 | } |
---|
| 282 | else |
---|
| 283 | { |
---|
| 284 | pcCU->setOutsideCUPart( uiIdx, uiDepth+1 ); |
---|
| 285 | } |
---|
| 286 | } |
---|
| 287 | |
---|
| 288 | uiIdx += uiQNumParts; |
---|
| 289 | } |
---|
| 290 | if( (g_uiMaxCUWidth>>uiDepth) == pcCU->getSlice()->getPPS()->getMinCuDQPSize() && pcCU->getSlice()->getPPS()->getUseDQP()) |
---|
| 291 | { |
---|
| 292 | if ( getdQPFlag() ) |
---|
| 293 | { |
---|
| 294 | UInt uiQPSrcPartIdx; |
---|
| 295 | if ( pcPic->getCU( pcCU->getAddr() )->getSliceSegmentStartCU(uiAbsPartIdx) != pcSlice->getSliceSegmentCurStartCUAddr() ) |
---|
| 296 | { |
---|
| 297 | uiQPSrcPartIdx = pcSlice->getSliceSegmentCurStartCUAddr() % pcPic->getNumPartInCU(); |
---|
| 298 | } |
---|
| 299 | else |
---|
| 300 | { |
---|
| 301 | uiQPSrcPartIdx = uiAbsPartIdx; |
---|
| 302 | } |
---|
| 303 | pcCU->setQPSubParts( pcCU->getRefQP( uiQPSrcPartIdx ), uiAbsPartIdx, uiDepth ); // set QP to default QP |
---|
| 304 | } |
---|
| 305 | } |
---|
| 306 | return; |
---|
| 307 | } |
---|
| 308 | |
---|
| 309 | if( (g_uiMaxCUWidth>>uiDepth) >= pcCU->getSlice()->getPPS()->getMinCuDQPSize() && pcCU->getSlice()->getPPS()->getUseDQP()) |
---|
| 310 | { |
---|
| 311 | setdQPFlag(true); |
---|
| 312 | pcCU->setQPSubParts( pcCU->getRefQP(uiAbsPartIdx), uiAbsPartIdx, uiDepth ); // set QP to default QP |
---|
| 313 | } |
---|
| 314 | |
---|
| 315 | if (pcCU->getSlice()->getPPS()->getTransquantBypassEnableFlag()) |
---|
| 316 | { |
---|
| 317 | m_pcEntropyDecoder->decodeCUTransquantBypassFlag( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 318 | } |
---|
| 319 | |
---|
| 320 | // decode CU mode and the partition size |
---|
| 321 | if( !pcCU->getSlice()->isIntra()) |
---|
| 322 | { |
---|
| 323 | m_pcEntropyDecoder->decodeSkipFlag( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 324 | } |
---|
| 325 | |
---|
[540] | 326 | #if HIGHER_LAYER_IRAP_SKIP_FLAG |
---|
| 327 | if (pcCU->getSlice()->getVPS()->getHigherLayerIrapSkipFlag() && pcCU->getSlice()->getVPS()->getSingleLayerForNonIrapFlag() && pcCU->getLayerId() > 0) |
---|
| 328 | { |
---|
| 329 | Bool lowerLayerExist = false; |
---|
| 330 | for(int i=0;i<pcCU->getLayerId();i++) |
---|
| 331 | { |
---|
| 332 | if(pcCU->getSlice()->getBaseColPic(pcCU->getSlice()->getInterLayerPredLayerIdc(i))) |
---|
| 333 | { |
---|
| 334 | lowerLayerExist = true; |
---|
| 335 | } |
---|
| 336 | } |
---|
| 337 | if(lowerLayerExist) |
---|
| 338 | { |
---|
| 339 | assert(pcCU->isSkipped(uiAbsPartIdx)); |
---|
| 340 | } |
---|
| 341 | } |
---|
| 342 | #endif |
---|
| 343 | |
---|
[313] | 344 | if( pcCU->isSkipped(uiAbsPartIdx) ) |
---|
| 345 | { |
---|
| 346 | m_ppcCU[uiDepth]->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_0 ); |
---|
| 347 | m_ppcCU[uiDepth]->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_1 ); |
---|
| 348 | TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS << 1]; // double length for mv of both lists |
---|
| 349 | UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS]; |
---|
| 350 | Int numValidMergeCand = 0; |
---|
| 351 | for( UInt ui = 0; ui < m_ppcCU[uiDepth]->getSlice()->getMaxNumMergeCand(); ++ui ) |
---|
| 352 | { |
---|
| 353 | uhInterDirNeighbours[ui] = 0; |
---|
| 354 | } |
---|
| 355 | m_pcEntropyDecoder->decodeMergeIndex( pcCU, 0, uiAbsPartIdx, uiDepth ); |
---|
| 356 | UInt uiMergeIndex = pcCU->getMergeIndex(uiAbsPartIdx); |
---|
| 357 | m_ppcCU[uiDepth]->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex ); |
---|
| 358 | pcCU->setInterDirSubParts( uhInterDirNeighbours[uiMergeIndex], uiAbsPartIdx, 0, uiDepth ); |
---|
| 359 | |
---|
| 360 | TComMv cTmpMv( 0, 0 ); |
---|
| 361 | for ( UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx++ ) |
---|
| 362 | { |
---|
| 363 | if ( pcCU->getSlice()->getNumRefIdx( RefPicList( uiRefListIdx ) ) > 0 ) |
---|
| 364 | { |
---|
| 365 | pcCU->setMVPIdxSubParts( 0, RefPicList( uiRefListIdx ), uiAbsPartIdx, 0, uiDepth); |
---|
| 366 | pcCU->setMVPNumSubParts( 0, RefPicList( uiRefListIdx ), uiAbsPartIdx, 0, uiDepth); |
---|
| 367 | pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvd( cTmpMv, SIZE_2Nx2N, uiAbsPartIdx, uiDepth ); |
---|
| 368 | pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvField( cMvFieldNeighbours[ 2*uiMergeIndex + uiRefListIdx ], SIZE_2Nx2N, uiAbsPartIdx, uiDepth ); |
---|
| 369 | } |
---|
| 370 | } |
---|
| 371 | xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast ); |
---|
| 372 | return; |
---|
| 373 | } |
---|
| 374 | |
---|
| 375 | m_pcEntropyDecoder->decodePredMode( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 376 | m_pcEntropyDecoder->decodePartSize( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 377 | |
---|
| 378 | if (pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N ) |
---|
| 379 | { |
---|
| 380 | m_pcEntropyDecoder->decodeIPCMInfo( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 381 | |
---|
| 382 | if(pcCU->getIPCMFlag(uiAbsPartIdx)) |
---|
| 383 | { |
---|
| 384 | xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast ); |
---|
| 385 | return; |
---|
| 386 | } |
---|
| 387 | } |
---|
| 388 | |
---|
| 389 | UInt uiCurrWidth = pcCU->getWidth ( uiAbsPartIdx ); |
---|
| 390 | UInt uiCurrHeight = pcCU->getHeight( uiAbsPartIdx ); |
---|
| 391 | |
---|
| 392 | // prediction mode ( Intra : direction mode, Inter : Mv, reference idx ) |
---|
| 393 | m_pcEntropyDecoder->decodePredInfo( pcCU, uiAbsPartIdx, uiDepth, m_ppcCU[uiDepth]); |
---|
| 394 | |
---|
| 395 | // Coefficient decoding |
---|
| 396 | Bool bCodeDQP = getdQPFlag(); |
---|
| 397 | m_pcEntropyDecoder->decodeCoeff( pcCU, uiAbsPartIdx, uiDepth, uiCurrWidth, uiCurrHeight, bCodeDQP ); |
---|
| 398 | setdQPFlag( bCodeDQP ); |
---|
| 399 | xFinishDecodeCU( pcCU, uiAbsPartIdx, uiDepth, ruiIsLast ); |
---|
| 400 | } |
---|
| 401 | |
---|
| 402 | Void TDecCu::xFinishDecodeCU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt& ruiIsLast) |
---|
| 403 | { |
---|
| 404 | if( pcCU->getSlice()->getPPS()->getUseDQP()) |
---|
| 405 | { |
---|
| 406 | pcCU->setQPSubParts( getdQPFlag()?pcCU->getRefQP(uiAbsPartIdx):pcCU->getCodedQP(), uiAbsPartIdx, uiDepth ); // set QP |
---|
| 407 | } |
---|
| 408 | |
---|
| 409 | ruiIsLast = xDecodeSliceEnd( pcCU, uiAbsPartIdx, uiDepth); |
---|
| 410 | } |
---|
| 411 | |
---|
| 412 | Void TDecCu::xDecompressCU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) |
---|
| 413 | { |
---|
| 414 | TComPic* pcPic = pcCU->getPic(); |
---|
| 415 | |
---|
| 416 | Bool bBoundary = false; |
---|
| 417 | UInt uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 418 | UInt uiRPelX = uiLPelX + (g_uiMaxCUWidth>>uiDepth) - 1; |
---|
| 419 | UInt uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiAbsPartIdx] ]; |
---|
| 420 | UInt uiBPelY = uiTPelY + (g_uiMaxCUHeight>>uiDepth) - 1; |
---|
| 421 | |
---|
| 422 | UInt uiCurNumParts = pcPic->getNumPartInCU() >> (uiDepth<<1); |
---|
| 423 | TComSlice * pcSlice = pcCU->getPic()->getSlice(pcCU->getPic()->getCurrSliceIdx()); |
---|
| 424 | Bool bStartInCU = pcCU->getSCUAddr()+uiAbsPartIdx+uiCurNumParts>pcSlice->getSliceSegmentCurStartCUAddr()&&pcCU->getSCUAddr()+uiAbsPartIdx<pcSlice->getSliceSegmentCurStartCUAddr(); |
---|
[442] | 425 | #if REPN_FORMAT_IN_VPS |
---|
| 426 | if(bStartInCU||( uiRPelX >= pcSlice->getPicWidthInLumaSamples() ) || ( uiBPelY >= pcSlice->getPicHeightInLumaSamples() ) ) |
---|
| 427 | #else |
---|
[313] | 428 | if(bStartInCU||( uiRPelX >= pcSlice->getSPS()->getPicWidthInLumaSamples() ) || ( uiBPelY >= pcSlice->getSPS()->getPicHeightInLumaSamples() ) ) |
---|
[442] | 429 | #endif |
---|
[313] | 430 | { |
---|
| 431 | bBoundary = true; |
---|
| 432 | } |
---|
| 433 | |
---|
| 434 | if( ( ( uiDepth < pcCU->getDepth( uiAbsPartIdx ) ) && ( uiDepth < g_uiMaxCUDepth - g_uiAddCUDepth ) ) || bBoundary ) |
---|
| 435 | { |
---|
| 436 | UInt uiNextDepth = uiDepth + 1; |
---|
| 437 | UInt uiQNumParts = pcCU->getTotalNumPart() >> (uiNextDepth<<1); |
---|
| 438 | UInt uiIdx = uiAbsPartIdx; |
---|
| 439 | for ( UInt uiPartIdx = 0; uiPartIdx < 4; uiPartIdx++ ) |
---|
| 440 | { |
---|
| 441 | uiLPelX = pcCU->getCUPelX() + g_auiRasterToPelX[ g_auiZscanToRaster[uiIdx] ]; |
---|
| 442 | uiTPelY = pcCU->getCUPelY() + g_auiRasterToPelY[ g_auiZscanToRaster[uiIdx] ]; |
---|
| 443 | |
---|
| 444 | Bool binSlice = (pcCU->getSCUAddr()+uiIdx+uiQNumParts>pcSlice->getSliceSegmentCurStartCUAddr())&&(pcCU->getSCUAddr()+uiIdx<pcSlice->getSliceSegmentCurEndCUAddr()); |
---|
[442] | 445 | #if REPN_FORMAT_IN_VPS |
---|
| 446 | if(binSlice&&( uiLPelX < pcSlice->getPicWidthInLumaSamples() ) && ( uiTPelY < pcSlice->getPicHeightInLumaSamples() ) ) |
---|
| 447 | #else |
---|
[313] | 448 | if(binSlice&&( uiLPelX < pcSlice->getSPS()->getPicWidthInLumaSamples() ) && ( uiTPelY < pcSlice->getSPS()->getPicHeightInLumaSamples() ) ) |
---|
[442] | 449 | #endif |
---|
[313] | 450 | { |
---|
| 451 | xDecompressCU(pcCU, uiIdx, uiNextDepth ); |
---|
| 452 | } |
---|
| 453 | |
---|
| 454 | uiIdx += uiQNumParts; |
---|
| 455 | } |
---|
| 456 | return; |
---|
| 457 | } |
---|
| 458 | |
---|
| 459 | // Residual reconstruction |
---|
| 460 | m_ppcYuvResi[uiDepth]->clear(); |
---|
| 461 | |
---|
| 462 | m_ppcCU[uiDepth]->copySubCU( pcCU, uiAbsPartIdx, uiDepth ); |
---|
| 463 | |
---|
| 464 | switch( m_ppcCU[uiDepth]->getPredictionMode(0) ) |
---|
| 465 | { |
---|
| 466 | case MODE_INTER: |
---|
| 467 | xReconInter( m_ppcCU[uiDepth], uiDepth ); |
---|
| 468 | break; |
---|
| 469 | case MODE_INTRA: |
---|
| 470 | xReconIntraQT( m_ppcCU[uiDepth], uiDepth ); |
---|
| 471 | break; |
---|
| 472 | default: |
---|
| 473 | assert(0); |
---|
| 474 | break; |
---|
| 475 | } |
---|
| 476 | if ( m_ppcCU[uiDepth]->isLosslessCoded(0) && (m_ppcCU[uiDepth]->getIPCMFlag(0) == false)) |
---|
| 477 | { |
---|
| 478 | xFillPCMBuffer(m_ppcCU[uiDepth], uiDepth); |
---|
| 479 | } |
---|
| 480 | |
---|
| 481 | xCopyToPic( m_ppcCU[uiDepth], pcPic, uiAbsPartIdx, uiDepth ); |
---|
| 482 | } |
---|
| 483 | |
---|
| 484 | Void TDecCu::xReconInter( TComDataCU* pcCU, UInt uiDepth ) |
---|
| 485 | { |
---|
| 486 | |
---|
| 487 | // inter prediction |
---|
| 488 | m_pcPrediction->motionCompensation( pcCU, m_ppcYuvReco[uiDepth] ); |
---|
| 489 | |
---|
| 490 | // inter recon |
---|
| 491 | xDecodeInterTexture( pcCU, 0, uiDepth ); |
---|
| 492 | |
---|
| 493 | // clip for only non-zero cbp case |
---|
| 494 | if ( ( pcCU->getCbf( 0, TEXT_LUMA ) ) || ( pcCU->getCbf( 0, TEXT_CHROMA_U ) ) || ( pcCU->getCbf(0, TEXT_CHROMA_V ) ) ) |
---|
| 495 | { |
---|
| 496 | m_ppcYuvReco[uiDepth]->addClip( m_ppcYuvReco[uiDepth], m_ppcYuvResi[uiDepth], 0, pcCU->getWidth( 0 ) ); |
---|
| 497 | } |
---|
| 498 | else |
---|
| 499 | { |
---|
| 500 | m_ppcYuvReco[uiDepth]->copyPartToPartYuv( m_ppcYuvReco[uiDepth],0, pcCU->getWidth( 0 ),pcCU->getHeight( 0 )); |
---|
| 501 | } |
---|
| 502 | } |
---|
| 503 | |
---|
| 504 | Void |
---|
| 505 | TDecCu::xIntraRecLumaBlk( TComDataCU* pcCU, |
---|
| 506 | UInt uiTrDepth, |
---|
| 507 | UInt uiAbsPartIdx, |
---|
| 508 | TComYuv* pcRecoYuv, |
---|
| 509 | TComYuv* pcPredYuv, |
---|
| 510 | TComYuv* pcResiYuv ) |
---|
| 511 | { |
---|
| 512 | UInt uiWidth = pcCU ->getWidth ( 0 ) >> uiTrDepth; |
---|
| 513 | UInt uiHeight = pcCU ->getHeight ( 0 ) >> uiTrDepth; |
---|
| 514 | UInt uiStride = pcRecoYuv->getStride (); |
---|
| 515 | Pel* piReco = pcRecoYuv->getLumaAddr( uiAbsPartIdx ); |
---|
| 516 | Pel* piPred = pcPredYuv->getLumaAddr( uiAbsPartIdx ); |
---|
| 517 | Pel* piResi = pcResiYuv->getLumaAddr( uiAbsPartIdx ); |
---|
| 518 | |
---|
| 519 | UInt uiNumCoeffInc = ( pcCU->getSlice()->getSPS()->getMaxCUWidth() * pcCU->getSlice()->getSPS()->getMaxCUHeight() ) >> ( pcCU->getSlice()->getSPS()->getMaxCUDepth() << 1 ); |
---|
| 520 | TCoeff* pcCoeff = pcCU->getCoeffY() + ( uiNumCoeffInc * uiAbsPartIdx ); |
---|
| 521 | |
---|
| 522 | UInt uiLumaPredMode = pcCU->getLumaIntraDir ( uiAbsPartIdx ); |
---|
| 523 | |
---|
| 524 | UInt uiZOrder = pcCU->getZorderIdxInCU() + uiAbsPartIdx; |
---|
| 525 | Pel* piRecIPred = pcCU->getPic()->getPicYuvRec()->getLumaAddr( pcCU->getAddr(), uiZOrder ); |
---|
| 526 | UInt uiRecIPredStride = pcCU->getPic()->getPicYuvRec()->getStride (); |
---|
| 527 | Bool useTransformSkip = pcCU->getTransformSkip(uiAbsPartIdx, TEXT_LUMA); |
---|
| 528 | //===== init availability pattern ===== |
---|
| 529 | Bool bAboveAvail = false; |
---|
| 530 | Bool bLeftAvail = false; |
---|
| 531 | pcCU->getPattern()->initPattern ( pcCU, uiTrDepth, uiAbsPartIdx ); |
---|
| 532 | pcCU->getPattern()->initAdiPattern( pcCU, uiAbsPartIdx, uiTrDepth, |
---|
| 533 | m_pcPrediction->getPredicBuf (), |
---|
| 534 | m_pcPrediction->getPredicBufWidth (), |
---|
| 535 | m_pcPrediction->getPredicBufHeight (), |
---|
| 536 | bAboveAvail, bLeftAvail ); |
---|
| 537 | |
---|
| 538 | //===== get prediction signal ===== |
---|
| 539 | m_pcPrediction->predIntraLumaAng( pcCU->getPattern(), uiLumaPredMode, piPred, uiStride, uiWidth, uiHeight, bAboveAvail, bLeftAvail ); |
---|
| 540 | |
---|
[595] | 541 | if ( pcCU->getCbf( uiAbsPartIdx, TEXT_LUMA, uiTrDepth ) ) |
---|
| 542 | { |
---|
[313] | 543 | //===== inverse transform ===== |
---|
[442] | 544 | #if REPN_FORMAT_IN_VPS |
---|
| 545 | m_pcTrQuant->setQPforQuant ( pcCU->getQP(0), TEXT_LUMA, pcCU->getSlice()->getQpBDOffsetY(), 0 ); |
---|
| 546 | #else |
---|
[313] | 547 | m_pcTrQuant->setQPforQuant ( pcCU->getQP(0), TEXT_LUMA, pcCU->getSlice()->getSPS()->getQpBDOffsetY(), 0 ); |
---|
[442] | 548 | #endif |
---|
[313] | 549 | |
---|
| 550 | Int scalingListType = (pcCU->isIntra(uiAbsPartIdx) ? 0 : 3) + g_eTTable[(Int)TEXT_LUMA]; |
---|
[595] | 551 | assert(scalingListType < SCALING_LIST_NUM); |
---|
[313] | 552 | m_pcTrQuant->invtransformNxN( pcCU->getCUTransquantBypass(uiAbsPartIdx), TEXT_LUMA, pcCU->getLumaIntraDir( uiAbsPartIdx ), piResi, uiStride, pcCoeff, uiWidth, uiHeight, scalingListType, useTransformSkip ); |
---|
| 553 | |
---|
| 554 | |
---|
| 555 | //===== reconstruction ===== |
---|
| 556 | Pel* pPred = piPred; |
---|
| 557 | Pel* pResi = piResi; |
---|
| 558 | Pel* pReco = piReco; |
---|
| 559 | Pel* pRecIPred = piRecIPred; |
---|
| 560 | for( UInt uiY = 0; uiY < uiHeight; uiY++ ) |
---|
| 561 | { |
---|
| 562 | for( UInt uiX = 0; uiX < uiWidth; uiX++ ) |
---|
| 563 | { |
---|
| 564 | pReco [ uiX ] = ClipY( pPred[ uiX ] + pResi[ uiX ] ); |
---|
| 565 | pRecIPred[ uiX ] = pReco[ uiX ]; |
---|
| 566 | } |
---|
| 567 | pPred += uiStride; |
---|
| 568 | pResi += uiStride; |
---|
| 569 | pReco += uiStride; |
---|
| 570 | pRecIPred += uiRecIPredStride; |
---|
| 571 | } |
---|
[595] | 572 | } |
---|
| 573 | else |
---|
| 574 | { |
---|
| 575 | //===== reconstruction ===== |
---|
| 576 | Pel* pPred = piPred; |
---|
| 577 | Pel* pReco = piReco; |
---|
| 578 | Pel* pRecIPred = piRecIPred; |
---|
| 579 | for ( Int y = 0; y < uiHeight; y++ ) |
---|
| 580 | { |
---|
| 581 | for ( Int x = 0; x < uiWidth; x++ ) |
---|
| 582 | { |
---|
| 583 | pReco [ x ] = pPred[ x ]; |
---|
| 584 | pRecIPred[ x ] = pReco[ x ]; |
---|
| 585 | } |
---|
| 586 | pPred += uiStride; |
---|
| 587 | pReco += uiStride; |
---|
| 588 | pRecIPred += uiRecIPredStride; |
---|
| 589 | } |
---|
| 590 | } |
---|
[313] | 591 | } |
---|
| 592 | |
---|
| 593 | |
---|
| 594 | Void |
---|
| 595 | TDecCu::xIntraRecChromaBlk( TComDataCU* pcCU, |
---|
| 596 | UInt uiTrDepth, |
---|
| 597 | UInt uiAbsPartIdx, |
---|
| 598 | TComYuv* pcRecoYuv, |
---|
| 599 | TComYuv* pcPredYuv, |
---|
| 600 | TComYuv* pcResiYuv, |
---|
| 601 | UInt uiChromaId ) |
---|
| 602 | { |
---|
| 603 | UInt uiFullDepth = pcCU->getDepth( 0 ) + uiTrDepth; |
---|
| 604 | UInt uiLog2TrSize = g_aucConvertToBit[ pcCU->getSlice()->getSPS()->getMaxCUWidth() >> uiFullDepth ] + 2; |
---|
| 605 | |
---|
| 606 | if( uiLog2TrSize == 2 ) |
---|
| 607 | { |
---|
| 608 | assert( uiTrDepth > 0 ); |
---|
| 609 | uiTrDepth--; |
---|
| 610 | UInt uiQPDiv = pcCU->getPic()->getNumPartInCU() >> ( ( pcCU->getDepth( 0 ) + uiTrDepth ) << 1 ); |
---|
| 611 | Bool bFirstQ = ( ( uiAbsPartIdx % uiQPDiv ) == 0 ); |
---|
| 612 | if( !bFirstQ ) |
---|
| 613 | { |
---|
| 614 | return; |
---|
| 615 | } |
---|
| 616 | } |
---|
| 617 | |
---|
| 618 | TextType eText = ( uiChromaId > 0 ? TEXT_CHROMA_V : TEXT_CHROMA_U ); |
---|
| 619 | UInt uiWidth = pcCU ->getWidth ( 0 ) >> ( uiTrDepth + 1 ); |
---|
| 620 | UInt uiHeight = pcCU ->getHeight ( 0 ) >> ( uiTrDepth + 1 ); |
---|
| 621 | UInt uiStride = pcRecoYuv->getCStride (); |
---|
| 622 | Pel* piReco = ( uiChromaId > 0 ? pcRecoYuv->getCrAddr( uiAbsPartIdx ) : pcRecoYuv->getCbAddr( uiAbsPartIdx ) ); |
---|
| 623 | Pel* piPred = ( uiChromaId > 0 ? pcPredYuv->getCrAddr( uiAbsPartIdx ) : pcPredYuv->getCbAddr( uiAbsPartIdx ) ); |
---|
| 624 | Pel* piResi = ( uiChromaId > 0 ? pcResiYuv->getCrAddr( uiAbsPartIdx ) : pcResiYuv->getCbAddr( uiAbsPartIdx ) ); |
---|
| 625 | |
---|
| 626 | UInt uiNumCoeffInc = ( ( pcCU->getSlice()->getSPS()->getMaxCUWidth() * pcCU->getSlice()->getSPS()->getMaxCUHeight() ) >> ( pcCU->getSlice()->getSPS()->getMaxCUDepth() << 1 ) ) >> 2; |
---|
| 627 | TCoeff* pcCoeff = ( uiChromaId > 0 ? pcCU->getCoeffCr() : pcCU->getCoeffCb() ) + ( uiNumCoeffInc * uiAbsPartIdx ); |
---|
| 628 | |
---|
| 629 | UInt uiChromaPredMode = pcCU->getChromaIntraDir( 0 ); |
---|
| 630 | |
---|
| 631 | UInt uiZOrder = pcCU->getZorderIdxInCU() + uiAbsPartIdx; |
---|
| 632 | Pel* piRecIPred = ( uiChromaId > 0 ? pcCU->getPic()->getPicYuvRec()->getCrAddr( pcCU->getAddr(), uiZOrder ) : pcCU->getPic()->getPicYuvRec()->getCbAddr( pcCU->getAddr(), uiZOrder ) ); |
---|
| 633 | UInt uiRecIPredStride = pcCU->getPic()->getPicYuvRec()->getCStride(); |
---|
| 634 | Bool useTransformSkipChroma = pcCU->getTransformSkip(uiAbsPartIdx,eText); |
---|
| 635 | //===== init availability pattern ===== |
---|
| 636 | Bool bAboveAvail = false; |
---|
| 637 | Bool bLeftAvail = false; |
---|
| 638 | pcCU->getPattern()->initPattern ( pcCU, uiTrDepth, uiAbsPartIdx ); |
---|
| 639 | |
---|
| 640 | pcCU->getPattern()->initAdiPatternChroma( pcCU, uiAbsPartIdx, uiTrDepth, |
---|
| 641 | m_pcPrediction->getPredicBuf (), |
---|
| 642 | m_pcPrediction->getPredicBufWidth (), |
---|
| 643 | m_pcPrediction->getPredicBufHeight (), |
---|
| 644 | bAboveAvail, bLeftAvail ); |
---|
| 645 | Int* pPatChroma = ( uiChromaId > 0 ? pcCU->getPattern()->getAdiCrBuf( uiWidth, uiHeight, m_pcPrediction->getPredicBuf() ) : pcCU->getPattern()->getAdiCbBuf( uiWidth, uiHeight, m_pcPrediction->getPredicBuf() ) ); |
---|
| 646 | |
---|
| 647 | //===== get prediction signal ===== |
---|
[345] | 648 | if( uiChromaPredMode == DM_CHROMA_IDX ) |
---|
[313] | 649 | { |
---|
[345] | 650 | uiChromaPredMode = pcCU->getLumaIntraDir( 0 ); |
---|
[313] | 651 | } |
---|
[345] | 652 | m_pcPrediction->predIntraChromaAng( pPatChroma, uiChromaPredMode, piPred, uiStride, uiWidth, uiHeight, bAboveAvail, bLeftAvail ); |
---|
[313] | 653 | |
---|
[595] | 654 | if ( pcCU->getCbf( uiAbsPartIdx, eText, uiTrDepth ) ) |
---|
| 655 | { |
---|
[313] | 656 | //===== inverse transform ===== |
---|
| 657 | Int curChromaQpOffset; |
---|
| 658 | if(eText == TEXT_CHROMA_U) |
---|
| 659 | { |
---|
| 660 | curChromaQpOffset = pcCU->getSlice()->getPPS()->getChromaCbQpOffset() + pcCU->getSlice()->getSliceQpDeltaCb(); |
---|
| 661 | } |
---|
| 662 | else |
---|
| 663 | { |
---|
| 664 | curChromaQpOffset = pcCU->getSlice()->getPPS()->getChromaCrQpOffset() + pcCU->getSlice()->getSliceQpDeltaCr(); |
---|
| 665 | } |
---|
[494] | 666 | #if O0194_DIFFERENT_BITDEPTH_EL_BL |
---|
| 667 | // Bug-fix |
---|
| 668 | #if REPN_FORMAT_IN_VPS |
---|
| 669 | m_pcTrQuant->setQPforQuant ( pcCU->getQP(0), eText, pcCU->getSlice()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 670 | #else |
---|
[313] | 671 | m_pcTrQuant->setQPforQuant ( pcCU->getQP(0), eText, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
[494] | 672 | #endif |
---|
| 673 | #else |
---|
| 674 | m_pcTrQuant->setQPforQuant ( pcCU->getQP(0), eText, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 675 | #endif |
---|
[313] | 676 | |
---|
| 677 | Int scalingListType = (pcCU->isIntra(uiAbsPartIdx) ? 0 : 3) + g_eTTable[(Int)eText]; |
---|
[595] | 678 | assert(scalingListType < SCALING_LIST_NUM); |
---|
[313] | 679 | m_pcTrQuant->invtransformNxN( pcCU->getCUTransquantBypass(uiAbsPartIdx), eText, REG_DCT, piResi, uiStride, pcCoeff, uiWidth, uiHeight, scalingListType, useTransformSkipChroma ); |
---|
| 680 | |
---|
| 681 | //===== reconstruction ===== |
---|
| 682 | Pel* pPred = piPred; |
---|
| 683 | Pel* pResi = piResi; |
---|
| 684 | Pel* pReco = piReco; |
---|
| 685 | Pel* pRecIPred = piRecIPred; |
---|
| 686 | for( UInt uiY = 0; uiY < uiHeight; uiY++ ) |
---|
| 687 | { |
---|
| 688 | for( UInt uiX = 0; uiX < uiWidth; uiX++ ) |
---|
| 689 | { |
---|
| 690 | pReco [ uiX ] = ClipC( pPred[ uiX ] + pResi[ uiX ] ); |
---|
| 691 | pRecIPred[ uiX ] = pReco[ uiX ]; |
---|
| 692 | } |
---|
| 693 | pPred += uiStride; |
---|
| 694 | pResi += uiStride; |
---|
| 695 | pReco += uiStride; |
---|
| 696 | pRecIPred += uiRecIPredStride; |
---|
| 697 | } |
---|
[595] | 698 | } |
---|
| 699 | else |
---|
| 700 | { |
---|
| 701 | //===== reconstruction ===== |
---|
| 702 | Pel* pPred = piPred; |
---|
| 703 | Pel* pReco = piReco; |
---|
| 704 | Pel* pRecIPred = piRecIPred; |
---|
| 705 | for ( Int y = 0; y < uiHeight; y++ ) |
---|
| 706 | { |
---|
| 707 | for ( Int x = 0; x < uiWidth; x++ ) |
---|
| 708 | { |
---|
| 709 | pReco [ x ] = pPred[ x ]; |
---|
| 710 | pRecIPred[ x ] = pReco[ x ]; |
---|
| 711 | } |
---|
| 712 | pPred += uiStride; |
---|
| 713 | pReco += uiStride; |
---|
| 714 | pRecIPred += uiRecIPredStride; |
---|
| 715 | } |
---|
| 716 | } |
---|
[313] | 717 | } |
---|
| 718 | |
---|
| 719 | |
---|
| 720 | Void |
---|
| 721 | TDecCu::xReconIntraQT( TComDataCU* pcCU, UInt uiDepth ) |
---|
| 722 | { |
---|
| 723 | UInt uiInitTrDepth = ( pcCU->getPartitionSize(0) == SIZE_2Nx2N ? 0 : 1 ); |
---|
[652] | 724 | UInt uiNumPart = pcCU->getNumPartitions(); |
---|
[313] | 725 | UInt uiNumQParts = pcCU->getTotalNumPart() >> 2; |
---|
| 726 | |
---|
| 727 | if (pcCU->getIPCMFlag(0)) |
---|
| 728 | { |
---|
| 729 | xReconPCM( pcCU, uiDepth ); |
---|
| 730 | return; |
---|
| 731 | } |
---|
| 732 | |
---|
| 733 | for( UInt uiPU = 0; uiPU < uiNumPart; uiPU++ ) |
---|
| 734 | { |
---|
| 735 | xIntraLumaRecQT( pcCU, uiInitTrDepth, uiPU * uiNumQParts, m_ppcYuvReco[uiDepth], m_ppcYuvReco[uiDepth], m_ppcYuvResi[uiDepth] ); |
---|
| 736 | } |
---|
| 737 | |
---|
| 738 | for( UInt uiPU = 0; uiPU < uiNumPart; uiPU++ ) |
---|
| 739 | { |
---|
| 740 | xIntraChromaRecQT( pcCU, uiInitTrDepth, uiPU * uiNumQParts, m_ppcYuvReco[uiDepth], m_ppcYuvReco[uiDepth], m_ppcYuvResi[uiDepth] ); |
---|
| 741 | } |
---|
| 742 | |
---|
| 743 | } |
---|
| 744 | |
---|
| 745 | /** Function for deriving recontructed PU/CU Luma sample with QTree structure |
---|
| 746 | * \param pcCU pointer of current CU |
---|
| 747 | * \param uiTrDepth current tranform split depth |
---|
| 748 | * \param uiAbsPartIdx part index |
---|
| 749 | * \param pcRecoYuv pointer to reconstructed sample arrays |
---|
| 750 | * \param pcPredYuv pointer to prediction sample arrays |
---|
| 751 | * \param pcResiYuv pointer to residue sample arrays |
---|
| 752 | * |
---|
| 753 | \ This function dervies recontructed PU/CU Luma sample with recursive QTree structure |
---|
| 754 | */ |
---|
| 755 | Void |
---|
| 756 | TDecCu::xIntraLumaRecQT( TComDataCU* pcCU, |
---|
| 757 | UInt uiTrDepth, |
---|
| 758 | UInt uiAbsPartIdx, |
---|
| 759 | TComYuv* pcRecoYuv, |
---|
| 760 | TComYuv* pcPredYuv, |
---|
| 761 | TComYuv* pcResiYuv ) |
---|
| 762 | { |
---|
| 763 | UInt uiFullDepth = pcCU->getDepth(0) + uiTrDepth; |
---|
| 764 | UInt uiTrMode = pcCU->getTransformIdx( uiAbsPartIdx ); |
---|
| 765 | if( uiTrMode == uiTrDepth ) |
---|
| 766 | { |
---|
| 767 | xIntraRecLumaBlk ( pcCU, uiTrDepth, uiAbsPartIdx, pcRecoYuv, pcPredYuv, pcResiYuv ); |
---|
| 768 | } |
---|
| 769 | else |
---|
| 770 | { |
---|
| 771 | UInt uiNumQPart = pcCU->getPic()->getNumPartInCU() >> ( ( uiFullDepth + 1 ) << 1 ); |
---|
| 772 | for( UInt uiPart = 0; uiPart < 4; uiPart++ ) |
---|
| 773 | { |
---|
| 774 | xIntraLumaRecQT( pcCU, uiTrDepth + 1, uiAbsPartIdx + uiPart * uiNumQPart, pcRecoYuv, pcPredYuv, pcResiYuv ); |
---|
| 775 | } |
---|
| 776 | } |
---|
| 777 | } |
---|
| 778 | |
---|
| 779 | /** Function for deriving recontructed PU/CU chroma samples with QTree structure |
---|
| 780 | * \param pcCU pointer of current CU |
---|
| 781 | * \param uiTrDepth current tranform split depth |
---|
| 782 | * \param uiAbsPartIdx part index |
---|
| 783 | * \param pcRecoYuv pointer to reconstructed sample arrays |
---|
| 784 | * \param pcPredYuv pointer to prediction sample arrays |
---|
| 785 | * \param pcResiYuv pointer to residue sample arrays |
---|
| 786 | * |
---|
| 787 | \ This function dervies recontructed PU/CU chroma samples with QTree recursive structure |
---|
| 788 | */ |
---|
| 789 | Void |
---|
| 790 | TDecCu::xIntraChromaRecQT( TComDataCU* pcCU, |
---|
| 791 | UInt uiTrDepth, |
---|
| 792 | UInt uiAbsPartIdx, |
---|
| 793 | TComYuv* pcRecoYuv, |
---|
| 794 | TComYuv* pcPredYuv, |
---|
| 795 | TComYuv* pcResiYuv ) |
---|
| 796 | { |
---|
| 797 | UInt uiFullDepth = pcCU->getDepth(0) + uiTrDepth; |
---|
| 798 | UInt uiTrMode = pcCU->getTransformIdx( uiAbsPartIdx ); |
---|
| 799 | if( uiTrMode == uiTrDepth ) |
---|
| 800 | { |
---|
| 801 | xIntraRecChromaBlk( pcCU, uiTrDepth, uiAbsPartIdx, pcRecoYuv, pcPredYuv, pcResiYuv, 0 ); |
---|
| 802 | xIntraRecChromaBlk( pcCU, uiTrDepth, uiAbsPartIdx, pcRecoYuv, pcPredYuv, pcResiYuv, 1 ); |
---|
| 803 | } |
---|
| 804 | else |
---|
| 805 | { |
---|
| 806 | UInt uiNumQPart = pcCU->getPic()->getNumPartInCU() >> ( ( uiFullDepth + 1 ) << 1 ); |
---|
| 807 | for( UInt uiPart = 0; uiPart < 4; uiPart++ ) |
---|
| 808 | { |
---|
| 809 | xIntraChromaRecQT( pcCU, uiTrDepth + 1, uiAbsPartIdx + uiPart * uiNumQPart, pcRecoYuv, pcPredYuv, pcResiYuv ); |
---|
| 810 | } |
---|
| 811 | } |
---|
| 812 | } |
---|
| 813 | |
---|
| 814 | Void TDecCu::xCopyToPic( TComDataCU* pcCU, TComPic* pcPic, UInt uiZorderIdx, UInt uiDepth ) |
---|
| 815 | { |
---|
| 816 | UInt uiCUAddr = pcCU->getAddr(); |
---|
| 817 | |
---|
| 818 | m_ppcYuvReco[uiDepth]->copyToPicYuv ( pcPic->getPicYuvRec (), uiCUAddr, uiZorderIdx ); |
---|
| 819 | |
---|
| 820 | return; |
---|
| 821 | } |
---|
| 822 | |
---|
| 823 | Void TDecCu::xDecodeInterTexture ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth ) |
---|
| 824 | { |
---|
| 825 | UInt uiWidth = pcCU->getWidth ( uiAbsPartIdx ); |
---|
| 826 | UInt uiHeight = pcCU->getHeight( uiAbsPartIdx ); |
---|
| 827 | TCoeff* piCoeff; |
---|
| 828 | |
---|
| 829 | Pel* pResi; |
---|
| 830 | UInt trMode = pcCU->getTransformIdx( uiAbsPartIdx ); |
---|
| 831 | |
---|
| 832 | // Y |
---|
| 833 | piCoeff = pcCU->getCoeffY(); |
---|
| 834 | pResi = m_ppcYuvResi[uiDepth]->getLumaAddr(); |
---|
| 835 | |
---|
[442] | 836 | #if REPN_FORMAT_IN_VPS |
---|
| 837 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_LUMA, pcCU->getSlice()->getQpBDOffsetY(), 0 ); |
---|
| 838 | #else |
---|
[313] | 839 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_LUMA, pcCU->getSlice()->getSPS()->getQpBDOffsetY(), 0 ); |
---|
[442] | 840 | #endif |
---|
[313] | 841 | |
---|
| 842 | m_pcTrQuant->invRecurTransformNxN ( pcCU, 0, TEXT_LUMA, pResi, 0, m_ppcYuvResi[uiDepth]->getStride(), uiWidth, uiHeight, trMode, 0, piCoeff ); |
---|
| 843 | |
---|
| 844 | // Cb and Cr |
---|
| 845 | Int curChromaQpOffset = pcCU->getSlice()->getPPS()->getChromaCbQpOffset() + pcCU->getSlice()->getSliceQpDeltaCb(); |
---|
[494] | 846 | #if O0194_DIFFERENT_BITDEPTH_EL_BL |
---|
| 847 | // Bug-fix |
---|
| 848 | #if REPN_FORMAT_IN_VPS |
---|
| 849 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 850 | #else |
---|
[313] | 851 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
[494] | 852 | #endif |
---|
| 853 | #else |
---|
| 854 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 855 | #endif |
---|
[313] | 856 | |
---|
| 857 | uiWidth >>= 1; |
---|
| 858 | uiHeight >>= 1; |
---|
| 859 | piCoeff = pcCU->getCoeffCb(); pResi = m_ppcYuvResi[uiDepth]->getCbAddr(); |
---|
| 860 | m_pcTrQuant->invRecurTransformNxN ( pcCU, 0, TEXT_CHROMA_U, pResi, 0, m_ppcYuvResi[uiDepth]->getCStride(), uiWidth, uiHeight, trMode, 0, piCoeff ); |
---|
| 861 | |
---|
| 862 | curChromaQpOffset = pcCU->getSlice()->getPPS()->getChromaCrQpOffset() + pcCU->getSlice()->getSliceQpDeltaCr(); |
---|
[494] | 863 | #if O0194_DIFFERENT_BITDEPTH_EL_BL |
---|
| 864 | // Bug-fix |
---|
| 865 | #if REPN_FORMAT_IN_VPS |
---|
| 866 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 867 | #else |
---|
[313] | 868 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
[494] | 869 | #endif |
---|
| 870 | #else |
---|
| 871 | m_pcTrQuant->setQPforQuant( pcCU->getQP( uiAbsPartIdx ), TEXT_CHROMA, pcCU->getSlice()->getSPS()->getQpBDOffsetC(), curChromaQpOffset ); |
---|
| 872 | #endif |
---|
[313] | 873 | |
---|
| 874 | piCoeff = pcCU->getCoeffCr(); pResi = m_ppcYuvResi[uiDepth]->getCrAddr(); |
---|
| 875 | m_pcTrQuant->invRecurTransformNxN ( pcCU, 0, TEXT_CHROMA_V, pResi, 0, m_ppcYuvResi[uiDepth]->getCStride(), uiWidth, uiHeight, trMode, 0, piCoeff ); |
---|
| 876 | } |
---|
| 877 | |
---|
| 878 | /** Function for deriving reconstructed luma/chroma samples of a PCM mode CU. |
---|
| 879 | * \param pcCU pointer to current CU |
---|
| 880 | * \param uiPartIdx part index |
---|
| 881 | * \param piPCM pointer to PCM code arrays |
---|
| 882 | * \param piReco pointer to reconstructed sample arrays |
---|
| 883 | * \param uiStride stride of reconstructed sample arrays |
---|
| 884 | * \param uiWidth CU width |
---|
| 885 | * \param uiHeight CU height |
---|
| 886 | * \param ttText texture component type |
---|
| 887 | * \returns Void |
---|
| 888 | */ |
---|
| 889 | Void TDecCu::xDecodePCMTexture( TComDataCU* pcCU, UInt uiPartIdx, Pel *piPCM, Pel* piReco, UInt uiStride, UInt uiWidth, UInt uiHeight, TextType ttText) |
---|
| 890 | { |
---|
| 891 | UInt uiX, uiY; |
---|
| 892 | Pel* piPicReco; |
---|
| 893 | UInt uiPicStride; |
---|
| 894 | UInt uiPcmLeftShiftBit; |
---|
| 895 | |
---|
| 896 | if( ttText == TEXT_LUMA ) |
---|
| 897 | { |
---|
| 898 | uiPicStride = pcCU->getPic()->getPicYuvRec()->getStride(); |
---|
| 899 | piPicReco = pcCU->getPic()->getPicYuvRec()->getLumaAddr(pcCU->getAddr(), pcCU->getZorderIdxInCU()+uiPartIdx); |
---|
| 900 | uiPcmLeftShiftBit = g_bitDepthY - pcCU->getSlice()->getSPS()->getPCMBitDepthLuma(); |
---|
| 901 | } |
---|
| 902 | else |
---|
| 903 | { |
---|
| 904 | uiPicStride = pcCU->getPic()->getPicYuvRec()->getCStride(); |
---|
| 905 | |
---|
| 906 | if( ttText == TEXT_CHROMA_U ) |
---|
| 907 | { |
---|
| 908 | piPicReco = pcCU->getPic()->getPicYuvRec()->getCbAddr(pcCU->getAddr(), pcCU->getZorderIdxInCU()+uiPartIdx); |
---|
| 909 | } |
---|
| 910 | else |
---|
| 911 | { |
---|
| 912 | piPicReco = pcCU->getPic()->getPicYuvRec()->getCrAddr(pcCU->getAddr(), pcCU->getZorderIdxInCU()+uiPartIdx); |
---|
| 913 | } |
---|
| 914 | uiPcmLeftShiftBit = g_bitDepthC - pcCU->getSlice()->getSPS()->getPCMBitDepthChroma(); |
---|
| 915 | } |
---|
| 916 | |
---|
| 917 | for( uiY = 0; uiY < uiHeight; uiY++ ) |
---|
| 918 | { |
---|
| 919 | for( uiX = 0; uiX < uiWidth; uiX++ ) |
---|
| 920 | { |
---|
| 921 | piReco[uiX] = (piPCM[uiX] << uiPcmLeftShiftBit); |
---|
| 922 | piPicReco[uiX] = piReco[uiX]; |
---|
| 923 | } |
---|
| 924 | piPCM += uiWidth; |
---|
| 925 | piReco += uiStride; |
---|
| 926 | piPicReco += uiPicStride; |
---|
| 927 | } |
---|
| 928 | } |
---|
| 929 | |
---|
| 930 | /** Function for reconstructing a PCM mode CU. |
---|
| 931 | * \param pcCU pointer to current CU |
---|
| 932 | * \param uiDepth CU Depth |
---|
| 933 | * \returns Void |
---|
| 934 | */ |
---|
| 935 | Void TDecCu::xReconPCM( TComDataCU* pcCU, UInt uiDepth ) |
---|
| 936 | { |
---|
| 937 | // Luma |
---|
| 938 | UInt uiWidth = (g_uiMaxCUWidth >> uiDepth); |
---|
| 939 | UInt uiHeight = (g_uiMaxCUHeight >> uiDepth); |
---|
| 940 | |
---|
| 941 | Pel* piPcmY = pcCU->getPCMSampleY(); |
---|
| 942 | Pel* piRecoY = m_ppcYuvReco[uiDepth]->getLumaAddr(0, uiWidth); |
---|
| 943 | |
---|
| 944 | UInt uiStride = m_ppcYuvResi[uiDepth]->getStride(); |
---|
| 945 | |
---|
| 946 | xDecodePCMTexture( pcCU, 0, piPcmY, piRecoY, uiStride, uiWidth, uiHeight, TEXT_LUMA); |
---|
| 947 | |
---|
| 948 | // Cb and Cr |
---|
| 949 | UInt uiCWidth = (uiWidth>>1); |
---|
| 950 | UInt uiCHeight = (uiHeight>>1); |
---|
| 951 | |
---|
| 952 | Pel* piPcmCb = pcCU->getPCMSampleCb(); |
---|
| 953 | Pel* piPcmCr = pcCU->getPCMSampleCr(); |
---|
| 954 | Pel* pRecoCb = m_ppcYuvReco[uiDepth]->getCbAddr(); |
---|
| 955 | Pel* pRecoCr = m_ppcYuvReco[uiDepth]->getCrAddr(); |
---|
| 956 | |
---|
| 957 | UInt uiCStride = m_ppcYuvReco[uiDepth]->getCStride(); |
---|
| 958 | |
---|
| 959 | xDecodePCMTexture( pcCU, 0, piPcmCb, pRecoCb, uiCStride, uiCWidth, uiCHeight, TEXT_CHROMA_U); |
---|
| 960 | xDecodePCMTexture( pcCU, 0, piPcmCr, pRecoCr, uiCStride, uiCWidth, uiCHeight, TEXT_CHROMA_V); |
---|
| 961 | } |
---|
| 962 | |
---|
| 963 | /** Function for filling the PCM buffer of a CU using its reconstructed sample array |
---|
| 964 | * \param pcCU pointer to current CU |
---|
| 965 | * \param uiDepth CU Depth |
---|
| 966 | * \returns Void |
---|
| 967 | */ |
---|
| 968 | Void TDecCu::xFillPCMBuffer(TComDataCU* pCU, UInt depth) |
---|
| 969 | { |
---|
| 970 | // Luma |
---|
| 971 | UInt width = (g_uiMaxCUWidth >> depth); |
---|
| 972 | UInt height = (g_uiMaxCUHeight >> depth); |
---|
| 973 | |
---|
| 974 | Pel* pPcmY = pCU->getPCMSampleY(); |
---|
| 975 | Pel* pRecoY = m_ppcYuvReco[depth]->getLumaAddr(0, width); |
---|
| 976 | |
---|
| 977 | UInt stride = m_ppcYuvReco[depth]->getStride(); |
---|
| 978 | |
---|
| 979 | for(Int y = 0; y < height; y++ ) |
---|
| 980 | { |
---|
| 981 | for(Int x = 0; x < width; x++ ) |
---|
| 982 | { |
---|
| 983 | pPcmY[x] = pRecoY[x]; |
---|
| 984 | } |
---|
| 985 | pPcmY += width; |
---|
| 986 | pRecoY += stride; |
---|
| 987 | } |
---|
| 988 | |
---|
| 989 | // Cb and Cr |
---|
| 990 | UInt widthC = (width>>1); |
---|
| 991 | UInt heightC = (height>>1); |
---|
| 992 | |
---|
| 993 | Pel* pPcmCb = pCU->getPCMSampleCb(); |
---|
| 994 | Pel* pPcmCr = pCU->getPCMSampleCr(); |
---|
| 995 | Pel* pRecoCb = m_ppcYuvReco[depth]->getCbAddr(); |
---|
| 996 | Pel* pRecoCr = m_ppcYuvReco[depth]->getCrAddr(); |
---|
| 997 | |
---|
| 998 | UInt strideC = m_ppcYuvReco[depth]->getCStride(); |
---|
| 999 | |
---|
| 1000 | for(Int y = 0; y < heightC; y++ ) |
---|
| 1001 | { |
---|
| 1002 | for(Int x = 0; x < widthC; x++ ) |
---|
| 1003 | { |
---|
| 1004 | pPcmCb[x] = pRecoCb[x]; |
---|
| 1005 | pPcmCr[x] = pRecoCr[x]; |
---|
| 1006 | } |
---|
| 1007 | pPcmCr += widthC; |
---|
| 1008 | pPcmCb += widthC; |
---|
| 1009 | pRecoCb += strideC; |
---|
| 1010 | pRecoCr += strideC; |
---|
| 1011 | } |
---|
| 1012 | |
---|
| 1013 | } |
---|
[540] | 1014 | |
---|
[313] | 1015 | //! \} |
---|