source: 3DVCSoftware/branches/HTM-10.2-dev0/source/Lib/TLibDecoder/TDecEntropy.cpp @ 936

Last change on this file since 936 was 936, checked in by tech, 10 years ago

Merged 10.2-dev2-MediaTek@930.

  • Property svn:eol-style set to native
File size: 31.9 KB
Line 
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 *
6* Copyright (c) 2010-2014, ITU/ISO/IEC
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     TDecEntropy.cpp
35    \brief    entropy decoder class
36*/
37
38#include "TDecEntropy.h"
39
40//! \ingroup TLibDecoder
41//! \{
42
43Void TDecEntropy::setEntropyDecoder         ( TDecEntropyIf* p )
44{
45  m_pcEntropyDecoderIf = p;
46}
47
48#include "TLibCommon/TComSampleAdaptiveOffset.h"
49
50Void TDecEntropy::decodeSkipFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
51{
52  m_pcEntropyDecoderIf->parseSkipFlag( pcCU, uiAbsPartIdx, uiDepth );
53}
54
55Void TDecEntropy::decodeCUTransquantBypassFlag(TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
56{
57  m_pcEntropyDecoderIf->parseCUTransquantBypassFlag( pcCU, uiAbsPartIdx, uiDepth );
58}
59
60/** decode merge flag
61 * \param pcSubCU
62 * \param uiAbsPartIdx
63 * \param uiDepth
64 * \param uiPUIdx
65 * \returns Void
66 */
67Void TDecEntropy::decodeMergeFlag( TComDataCU* pcSubCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPUIdx )
68{ 
69  // at least one merge candidate exists
70  m_pcEntropyDecoderIf->parseMergeFlag( pcSubCU, uiAbsPartIdx, uiDepth, uiPUIdx );
71}
72
73/** decode merge index
74 * \param pcCU
75 * \param uiPartIdx
76 * \param uiAbsPartIdx
77 * \param puhInterDirNeighbours pointer to list of inter direction from the casual neighbours
78 * \param pcMvFieldNeighbours pointer to list of motion vector field from the casual neighbours
79 * \param uiDepth
80 * \returns Void
81 */
82Void TDecEntropy::decodeMergeIndex( TComDataCU* pcCU, UInt uiPartIdx, UInt uiAbsPartIdx, UInt uiDepth )
83{
84  UInt uiMergeIndex = 0;
85  m_pcEntropyDecoderIf->parseMergeIndex( pcCU, uiMergeIndex );
86  pcCU->setMergeIndexSubParts( uiMergeIndex, uiAbsPartIdx, uiPartIdx, uiDepth );
87}
88
89#if H_3D_ARP
90Void TDecEntropy::decodeARPW( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
91{
92  if( !pcCU->getSlice()->getARPStepNum() || pcCU->isIntra( uiAbsPartIdx ) )
93  {
94    return;
95  }
96
97  if( pcCU->getPartitionSize(uiAbsPartIdx) != SIZE_2Nx2N )
98  {
99    pcCU->setARPWSubParts( 0 , uiAbsPartIdx, uiDepth );
100  }
101  else
102  {
103    m_pcEntropyDecoderIf->parseARPW( pcCU , uiAbsPartIdx , uiDepth );
104  }
105}
106#endif
107
108#if H_3D_IC
109Void TDecEntropy::decodeICFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
110{
111  pcCU->setICFlagSubParts( false , uiAbsPartIdx, 0, uiDepth );
112
113  if ( pcCU->isIntra( uiAbsPartIdx ) || ( pcCU->getSlice()->getViewIndex() == 0 ) || pcCU->getSlice()->getIsDepth() || pcCU->getARPW( uiAbsPartIdx ) > 0 )
114  {
115    return;
116  }
117
118  if( !pcCU->getSlice()->getApplyIC() )
119    return;
120
121  if( pcCU->isICFlagRequired( uiAbsPartIdx ) )
122    m_pcEntropyDecoderIf->parseICFlag( pcCU, uiAbsPartIdx, uiDepth );
123}
124#endif
125
126Void TDecEntropy::decodeSplitFlag   ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
127{
128  m_pcEntropyDecoderIf->parseSplitFlag( pcCU, uiAbsPartIdx, uiDepth );
129}
130
131Void TDecEntropy::decodePredMode( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
132{
133  m_pcEntropyDecoderIf->parsePredMode( pcCU, uiAbsPartIdx, uiDepth );
134}
135
136Void TDecEntropy::decodePartSize( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
137{
138  m_pcEntropyDecoderIf->parsePartSize( pcCU, uiAbsPartIdx, uiDepth );
139 
140#if H_3D_DBBP
141
142#if MTK_DBBP_SIGNALING_H0094
143  if( pcCU->getSlice()->getVPS()->getUseDBBP(pcCU->getSlice()->getLayerIdInVps()) )
144#else
145  if( pcCU->getSlice()->getVPS()->getUseDBBP(pcCU->getSlice()->getLayerIdInVps()) && pcCU->getPartitionSize(uiAbsPartIdx) == RWTH_DBBP_PACK_MODE )
146#endif
147  {
148    decodeDBBPFlag(pcCU, uiAbsPartIdx, uiDepth);
149   
150    if( pcCU->getDBBPFlag(uiAbsPartIdx) )
151    {
152#if !MTK_DBBP_SIGNALING_H0094
153      AOF( pcCU->getPartitionSize(uiAbsPartIdx) == RWTH_DBBP_PACK_MODE );
154#endif
155     
156      // get collocated depth block
157      UInt uiDepthStride = 0;
158      Pel* pDepthPels = NULL;
159      pDepthPels = pcCU->getVirtualDepthBlock(uiAbsPartIdx, pcCU->getWidth(uiAbsPartIdx), pcCU->getHeight(uiAbsPartIdx), uiDepthStride);
160     
161      AOF( pDepthPels != NULL );
162      AOF( uiDepthStride != 0 );
163     
164      // derive true partitioning for this CU based on depth
165      // (needs to be done in parsing process as motion vector predictors are also derived during parsing)
166      PartSize eVirtualPartSize = m_pcPrediction->getPartitionSizeFromDepth(pDepthPels, uiDepthStride, pcCU->getWidth(uiAbsPartIdx));
167      AOF( eVirtualPartSize != SIZE_NONE );
168     
169      pcCU->setPartSizeSubParts(eVirtualPartSize, uiAbsPartIdx, uiDepth);
170     
171#if RWTH_DBBP_NO_SPU_H0057
172      // make sure that DBBP flag is set for both segments
173      UInt uiPUOffset = ( g_auiPUOffset[UInt( eVirtualPartSize )] << ( ( pcCU->getSlice()->getSPS()->getMaxCUDepth() - uiDepth ) << 1 ) ) >> 4;
174      pcCU->setDBBPFlagSubParts(true, uiAbsPartIdx, 0, uiDepth);
175      pcCU->setDBBPFlagSubParts(true, uiAbsPartIdx+uiPUOffset, 1, uiDepth);
176#endif
177    }
178  }
179#endif
180}
181
182Void TDecEntropy::decodePredInfo    ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU )
183{
184  if( pcCU->isIntra( uiAbsPartIdx ) )                                 // If it is Intra mode, encode intra prediction mode.
185  {
186    decodeIntraDirModeLuma  ( pcCU, uiAbsPartIdx, uiDepth );
187#if H_3D_DIM_SDC
188    if(!pcCU->getSDCFlag(uiAbsPartIdx))
189#endif
190    decodeIntraDirModeChroma( pcCU, uiAbsPartIdx, uiDepth );
191  }
192  else                                                                // if it is Inter mode, encode motion vector and reference index
193  {
194    decodePUWise( pcCU, uiAbsPartIdx, uiDepth, pcSubCU );
195  }
196}
197
198/** Parse I_PCM information.
199 * \param pcCU  pointer to CUpointer to CU
200 * \param uiAbsPartIdx CU index
201 * \param uiDepth CU depth
202 * \returns Void
203 */
204Void TDecEntropy::decodeIPCMInfo( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
205{
206  if(!pcCU->getSlice()->getSPS()->getUsePCM()
207    || pcCU->getWidth(uiAbsPartIdx) > (1<<pcCU->getSlice()->getSPS()->getPCMLog2MaxSize())
208    || pcCU->getWidth(uiAbsPartIdx) < (1<<pcCU->getSlice()->getSPS()->getPCMLog2MinSize()) )
209  {
210    return;
211  }
212#if H_3D_DIM_SDC
213  if( pcCU->getSDCFlag(uiAbsPartIdx) )
214  {
215    return;
216  }
217#endif
218 
219  m_pcEntropyDecoderIf->parseIPCMInfo( pcCU, uiAbsPartIdx, uiDepth );
220}
221
222Void TDecEntropy::decodeIntraDirModeLuma  ( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
223{
224  m_pcEntropyDecoderIf->parseIntraDirLumaAng( pcCU, uiAbsPartIdx, uiDepth );
225}
226
227Void TDecEntropy::decodeIntraDirModeChroma( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
228{
229  m_pcEntropyDecoderIf->parseIntraDirChroma( pcCU, uiAbsPartIdx, uiDepth );
230}
231
232/** decode motion information for every PU block.
233 * \param pcCU
234 * \param uiAbsPartIdx
235 * \param uiDepth
236 * \param pcSubCU
237 * \returns Void
238 */
239Void TDecEntropy::decodePUWise( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, TComDataCU* pcSubCU )
240{
241  PartSize ePartSize = pcCU->getPartitionSize( uiAbsPartIdx );
242  UInt uiNumPU = ( ePartSize == SIZE_2Nx2N ? 1 : ( ePartSize == SIZE_NxN ? 4 : 2 ) );
243  UInt uiPUOffset = ( g_auiPUOffset[UInt( ePartSize )] << ( ( pcCU->getSlice()->getSPS()->getMaxCUDepth() - uiDepth ) << 1 ) ) >> 4;
244
245#if H_3D_IV_MERGE
246  TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS_MEM << 1]; // double length for mv of both lists
247  UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS_MEM];
248#else
249  TComMvField cMvFieldNeighbours[MRG_MAX_NUM_CANDS << 1]; // double length for mv of both lists
250  UChar uhInterDirNeighbours[MRG_MAX_NUM_CANDS];
251#endif
252#if H_3D_SPIVMP
253  Bool bSPIVMPFlag[MRG_MAX_NUM_CANDS_MEM];
254  TComMvField*  pcMvFieldSP;
255  UChar* puhInterDirSP;
256  pcMvFieldSP = new TComMvField[pcCU->getPic()->getPicSym()->getNumPartition()*2]; 
257  puhInterDirSP = new UChar[pcCU->getPic()->getPicSym()->getNumPartition()]; 
258#endif
259  for ( UInt ui = 0; ui < pcCU->getSlice()->getMaxNumMergeCand(); ui++ )
260  {
261    uhInterDirNeighbours[ui] = 0;
262  }
263  Int numValidMergeCand = 0;
264  Bool isMerged = false;
265
266  pcSubCU->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_0 );
267  pcSubCU->copyInterPredInfoFrom( pcCU, uiAbsPartIdx, REF_PIC_LIST_1 );
268#if H_3D_IV_MERGE
269  pcSubCU->copyDVInfoFrom( pcCU, uiAbsPartIdx);
270#endif
271  for ( UInt uiPartIdx = 0, uiSubPartIdx = uiAbsPartIdx; uiPartIdx < uiNumPU; uiPartIdx++, uiSubPartIdx += uiPUOffset )
272  {
273#if H_MV_ENC_DEC_TRAC
274    DTRACE_PU_S("=========== prediction_unit ===========\n")
275    // ToDo:
276    //DTRACE_PU("x0", uiLPelX)
277    //DTRACE_PU("x1", uiTPelY)
278#endif
279    decodeMergeFlag( pcCU, uiSubPartIdx, uiDepth, uiPartIdx );
280    if ( pcCU->getMergeFlag( uiSubPartIdx ) )
281    {
282      decodeMergeIndex( pcCU, uiPartIdx, uiSubPartIdx, uiDepth );
283      UInt uiMergeIndex = pcCU->getMergeIndex(uiSubPartIdx);
284#if H_3D_ARP
285      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
286#endif
287#if H_3D_IC
288      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
289#endif
290#if H_3D_DBBP
291      if ( pcCU->getSlice()->getPPS()->getLog2ParallelMergeLevelMinus2() && ePartSize != SIZE_2Nx2N && pcSubCU->getWidth( 0 ) <= 8 && pcCU->getDBBPFlag(uiAbsPartIdx) == false )
292#else
293      if ( pcCU->getSlice()->getPPS()->getLog2ParallelMergeLevelMinus2() && ePartSize != SIZE_2Nx2N && pcSubCU->getWidth( 0 ) <= 8 ) 
294#endif
295      {
296        pcSubCU->setPartSizeSubParts( SIZE_2Nx2N, 0, uiDepth );
297        if ( !isMerged )
298        {
299#if H_3D_VSP
300          Int vspFlag[MRG_MAX_NUM_CANDS_MEM];
301          memset(vspFlag, 0, sizeof(Int)*MRG_MAX_NUM_CANDS_MEM);
302          InheritedVSPDisInfo inheritedVSPDisInfo[MRG_MAX_NUM_CANDS_MEM];
303#if H_3D_SPIVMP
304          memset(bSPIVMPFlag, false, sizeof(Bool)*MRG_MAX_NUM_CANDS_MEM);
305#endif
306          pcSubCU->initAvailableFlags();
307          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand);
308          pcSubCU->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours
309#if !ETRIKHU_CLEANUP_H0083
310            ,vspFlag
311#endif
312            , inheritedVSPDisInfo
313#if H_3D_SPIVMP
314            , pcMvFieldSP, puhInterDirSP
315#endif
316            , numValidMergeCand );
317
318#if ETRIKHU_CLEANUP_H0083
319          pcSubCU->buildMCL( cMvFieldNeighbours, uhInterDirNeighbours, vspFlag
320#if H_3D_SPIVMP
321            , bSPIVMPFlag
322#endif
323            , numValidMergeCand );
324#endif
325          pcCU->setVSPFlagSubParts( vspFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth );
326
327          if(vspFlag[uiMergeIndex])
328          {
329            pcCU->setDvInfoSubParts(inheritedVSPDisInfo[uiMergeIndex].m_acDvInfo, uiSubPartIdx, uiPartIdx, uiDepth);
330          }
331#else
332#if H_3D
333          pcSubCU->initAvailableFlags();
334          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand);
335          pcSubCU->xGetInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand );
336
337#else
338          pcSubCU->getInterMergeCandidates( 0, 0, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand );
339#endif
340#endif
341          isMerged = true;
342        }
343        pcSubCU->setPartSizeSubParts( ePartSize, 0, uiDepth );
344      }
345      else
346      {
347        uiMergeIndex = pcCU->getMergeIndex(uiSubPartIdx);
348#if H_3D_VSP
349        Int vspFlag[MRG_MAX_NUM_CANDS_MEM];
350        memset(vspFlag, 0, sizeof(Int)*MRG_MAX_NUM_CANDS_MEM);
351        InheritedVSPDisInfo inheritedVSPDisInfo[MRG_MAX_NUM_CANDS_MEM];
352#if H_3D_SPIVMP
353        memset(bSPIVMPFlag, false, sizeof(Bool)*MRG_MAX_NUM_CANDS_MEM);
354#endif
355        pcSubCU->initAvailableFlags();
356        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
357        pcSubCU->xGetInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours
358#if !ETRIKHU_CLEANUP_H0083
359          , vspFlag
360#endif
361          , inheritedVSPDisInfo
362#if H_3D_SPIVMP
363          , pcMvFieldSP, puhInterDirSP
364#endif
365          ,numValidMergeCand, uiMergeIndex );
366
367#if ETRIKHU_CLEANUP_H0083
368        pcSubCU->buildMCL( cMvFieldNeighbours, uhInterDirNeighbours, vspFlag
369#if H_3D_SPIVMP
370          , bSPIVMPFlag
371#endif
372          ,numValidMergeCand );
373#endif
374        pcCU->setVSPFlagSubParts( vspFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth );
375        if(vspFlag[uiMergeIndex])
376        {
377          pcCU->setDvInfoSubParts(inheritedVSPDisInfo[uiMergeIndex].m_acDvInfo, uiSubPartIdx, uiPartIdx, uiDepth);
378        }
379#else
380#if H_3D
381        pcSubCU->initAvailableFlags();
382        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
383        pcSubCU->xGetInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
384#else
385        pcSubCU->getInterMergeCandidates( uiSubPartIdx-uiAbsPartIdx, uiPartIdx, cMvFieldNeighbours, uhInterDirNeighbours, numValidMergeCand, uiMergeIndex );
386#endif
387#endif
388      }
389      pcCU->setInterDirSubParts( uhInterDirNeighbours[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth );
390
391#if H_3D_DDD
392      if( uiMergeIndex == pcSubCU->getUseDDDCandIdx() )
393      {
394          assert( pcCU->getSlice()->getViewIndex() != 0 );
395          pcCU->setUseDDD( true, uiSubPartIdx, uiPartIdx, uiDepth );
396          pcCU->setDDDepthSubParts( pcSubCU->getDDTmpDepth(),uiSubPartIdx, uiPartIdx, uiDepth );
397      }
398      else
399      {
400          pcCU->setUseDDD( false, uiSubPartIdx, uiPartIdx, uiDepth );
401      }
402#endif
403
404      TComMv cTmpMv( 0, 0 );
405      for ( UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx++ )
406      {       
407        if ( pcCU->getSlice()->getNumRefIdx( RefPicList( uiRefListIdx ) ) > 0 )
408        {
409          pcCU->setMVPIdxSubParts( 0, RefPicList( uiRefListIdx ), uiSubPartIdx, uiPartIdx, uiDepth);
410          pcCU->setMVPNumSubParts( 0, RefPicList( uiRefListIdx ), uiSubPartIdx, uiPartIdx, uiDepth);
411          pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvd( cTmpMv, ePartSize, uiSubPartIdx, uiDepth, uiPartIdx );
412          pcCU->getCUMvField( RefPicList( uiRefListIdx ) )->setAllMvField( cMvFieldNeighbours[ 2*uiMergeIndex + uiRefListIdx ], ePartSize, uiSubPartIdx, uiDepth, uiPartIdx );
413#if H_3D_VSP
414#if H_3D_DBBP
415          if( pcCU->getVSPFlag( uiSubPartIdx ) != 0 && !pcCU->getDBBPFlag( uiAbsPartIdx ) )
416#else
417          if( pcCU->getVSPFlag( uiSubPartIdx ) != 0 )
418#endif
419          {
420            if ( uhInterDirNeighbours[ uiMergeIndex ] & (1<<uiRefListIdx) )
421            {
422              UInt dummy;
423              Int vspSize;
424              Int width, height;
425              pcCU->getPartIndexAndSize( uiPartIdx, dummy, width, height, uiSubPartIdx, pcCU->getTotalNumPart()==256 );
426              pcCU->setMvFieldPUForVSP( pcCU, uiSubPartIdx, width, height, RefPicList( uiRefListIdx ), cMvFieldNeighbours[ 2*uiMergeIndex + uiRefListIdx ].getRefIdx(), vspSize );
427              pcCU->setVSPFlag( uiSubPartIdx, vspSize );
428            }
429          }
430#endif
431        }
432      }
433#if H_3D_SPIVMP
434      pcCU->setSPIVMPFlagSubParts(bSPIVMPFlag[uiMergeIndex], uiSubPartIdx, uiPartIdx, uiDepth ); 
435      if (bSPIVMPFlag[uiMergeIndex] != 0)
436      {
437        Int iWidth, iHeight;
438        UInt uiIdx;
439        pcCU->getPartIndexAndSize( uiPartIdx, uiIdx, iWidth, iHeight, uiSubPartIdx, true );
440
441        UInt uiSPAddr;
442
443        Int iNumSPInOneLine, iNumSP, iSPWidth, iSPHeight;
444
445        pcCU->getSPPara(iWidth, iHeight, iNumSP, iNumSPInOneLine, iSPWidth, iSPHeight);
446
447        for (Int iPartitionIdx = 0; iPartitionIdx < iNumSP; iPartitionIdx++)
448        {
449          pcCU->getSPAbsPartIdx(uiSubPartIdx, iSPWidth, iSPHeight, iPartitionIdx, iNumSPInOneLine, uiSPAddr);
450          pcCU->setInterDirSP(puhInterDirSP[iPartitionIdx], uiSPAddr, iSPWidth, iSPHeight);
451          pcCU->getCUMvField( REF_PIC_LIST_0 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx], iSPWidth, iSPHeight);
452          pcCU->getCUMvField( REF_PIC_LIST_1 )->setMvFieldSP(pcCU, uiSPAddr, pcMvFieldSP[2*iPartitionIdx + 1], iSPWidth, iSPHeight);
453        }
454      }
455#endif
456    }
457    else
458    {
459      decodeInterDirPU( pcCU, uiSubPartIdx, uiDepth, uiPartIdx );
460      for ( UInt uiRefListIdx = 0; uiRefListIdx < 2; uiRefListIdx++ )
461      {       
462        if ( pcCU->getSlice()->getNumRefIdx( RefPicList( uiRefListIdx ) ) > 0 )
463        {
464          decodeRefFrmIdxPU( pcCU,    uiSubPartIdx,              uiDepth, uiPartIdx, RefPicList( uiRefListIdx ) );
465          decodeMvdPU      ( pcCU,    uiSubPartIdx,              uiDepth, uiPartIdx, RefPicList( uiRefListIdx ) );
466          decodeMVPIdxPU   ( pcSubCU, uiSubPartIdx-uiAbsPartIdx, uiDepth, uiPartIdx, RefPicList( uiRefListIdx ) );
467        }
468      }
469#if H_3D_ARP
470      decodeARPW  ( pcCU, uiAbsPartIdx, uiDepth );
471#endif
472#if H_3D_IC
473      decodeICFlag( pcCU, uiAbsPartIdx, uiDepth );
474#endif
475    }
476#if H_3D_VSP
477    if ( (pcCU->getInterDir(uiSubPartIdx) == 3) && pcSubCU->isBipredRestriction(uiPartIdx) && (pcCU->getVSPFlag(uiSubPartIdx) == 0))
478#else
479    if ( (pcCU->getInterDir(uiSubPartIdx) == 3) && pcSubCU->isBipredRestriction(uiPartIdx) )
480#endif
481    {
482      pcCU->getCUMvField( REF_PIC_LIST_1 )->setAllMv( TComMv(0,0), ePartSize, uiSubPartIdx, uiDepth, uiPartIdx);
483      pcCU->getCUMvField( REF_PIC_LIST_1 )->setAllRefIdx( -1, ePartSize, uiSubPartIdx, uiDepth, uiPartIdx);
484      pcCU->setInterDirSubParts( 1, uiSubPartIdx, uiPartIdx, uiDepth);
485    }
486  }
487#if H_3D_SPIVMP
488  delete[] pcMvFieldSP;
489  delete[] puhInterDirSP;
490#endif
491  return;
492}
493
494/** decode inter direction for a PU block
495 * \param pcCU
496 * \param uiAbsPartIdx
497 * \param uiDepth
498 * \param uiPartIdx
499 * \returns Void
500 */
501Void TDecEntropy::decodeInterDirPU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPartIdx )
502{
503  UInt uiInterDir;
504
505  if ( pcCU->getSlice()->isInterP() )
506  {
507    uiInterDir = 1;
508  }
509  else
510  {
511    m_pcEntropyDecoderIf->parseInterDir( pcCU, uiInterDir, uiAbsPartIdx );
512  }
513
514  pcCU->setInterDirSubParts( uiInterDir, uiAbsPartIdx, uiPartIdx, uiDepth );
515}
516
517Void TDecEntropy::decodeRefFrmIdxPU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPartIdx, RefPicList eRefList )
518{
519  Int iRefFrmIdx = 0;
520  Int iParseRefFrmIdx = pcCU->getInterDir( uiAbsPartIdx ) & ( 1 << eRefList );
521
522  if ( pcCU->getSlice()->getNumRefIdx( eRefList ) > 1 && iParseRefFrmIdx )
523  {
524    m_pcEntropyDecoderIf->parseRefFrmIdx( pcCU, iRefFrmIdx, eRefList );
525  }
526  else if ( !iParseRefFrmIdx )
527  {
528    iRefFrmIdx = NOT_VALID;
529  }
530  else
531  {
532    iRefFrmIdx = 0;
533  }
534
535  PartSize ePartSize = pcCU->getPartitionSize( uiAbsPartIdx );
536  pcCU->getCUMvField( eRefList )->setAllRefIdx( iRefFrmIdx, ePartSize, uiAbsPartIdx, uiDepth, uiPartIdx );
537}
538
539/** decode motion vector difference for a PU block
540 * \param pcCU
541 * \param uiAbsPartIdx
542 * \param uiDepth
543 * \param uiPartIdx
544 * \param eRefList
545 * \returns Void
546 */
547Void TDecEntropy::decodeMvdPU( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiPartIdx, RefPicList eRefList )
548{
549  if ( pcCU->getInterDir( uiAbsPartIdx ) & ( 1 << eRefList ) )
550  {
551    m_pcEntropyDecoderIf->parseMvd( pcCU, uiAbsPartIdx, uiPartIdx, uiDepth, eRefList );
552  }
553}
554
555Void TDecEntropy::decodeMVPIdxPU( TComDataCU* pcSubCU, UInt uiPartAddr, UInt uiDepth, UInt uiPartIdx, RefPicList eRefList )
556{
557  Int iMVPIdx = -1;
558
559  TComMv cZeroMv( 0, 0 );
560  TComMv cMv     = cZeroMv;
561  Int    iRefIdx = -1;
562
563  TComCUMvField* pcSubCUMvField = pcSubCU->getCUMvField( eRefList );
564  AMVPInfo* pAMVPInfo = pcSubCUMvField->getAMVPInfo();
565
566  iRefIdx = pcSubCUMvField->getRefIdx(uiPartAddr);
567  cMv = cZeroMv;
568
569  if ( (pcSubCU->getInterDir(uiPartAddr) & ( 1 << eRefList )) )
570  {
571    m_pcEntropyDecoderIf->parseMVPIdx( iMVPIdx );
572#if H_MV_ENC_DEC_TRAC
573#if ENC_DEC_TRACE
574    if ( eRefList == REF_PIC_LIST_0 )
575    {
576      DTRACE_PU("mvp_l0_flag", iMVPIdx)
577    }
578    else
579    {
580      DTRACE_PU("mvp_l1_flag", iMVPIdx)
581    }
582#endif
583#endif
584  }
585  pcSubCU->fillMvpCand(uiPartIdx, uiPartAddr, eRefList, iRefIdx, pAMVPInfo);
586  pcSubCU->setMVPNumSubParts(pAMVPInfo->iN, eRefList, uiPartAddr, uiPartIdx, uiDepth);
587  pcSubCU->setMVPIdxSubParts( iMVPIdx, eRefList, uiPartAddr, uiPartIdx, uiDepth );
588  if ( iRefIdx >= 0 )
589  {
590    m_pcPrediction->getMvPredAMVP( pcSubCU, uiPartIdx, uiPartAddr, eRefList, cMv);
591    cMv += pcSubCUMvField->getMvd( uiPartAddr );
592  }
593
594  PartSize ePartSize = pcSubCU->getPartitionSize( uiPartAddr );
595  pcSubCU->getCUMvField( eRefList )->setAllMv(cMv, ePartSize, uiPartAddr, 0, uiPartIdx);
596}
597
598Void TDecEntropy::xDecodeTransform( TComDataCU* pcCU, UInt offsetLuma, UInt offsetChroma, UInt uiAbsPartIdx, UInt uiDepth, UInt width, UInt height, UInt uiTrIdx, Bool& bCodeDQP, Int quadtreeTULog2MinSizeInCU)
599{
600  UInt uiSubdiv;
601  const UInt uiLog2TrafoSize = g_aucConvertToBit[pcCU->getSlice()->getSPS()->getMaxCUWidth()]+2 - uiDepth;
602
603  if(uiTrIdx==0)
604  {
605    m_bakAbsPartIdxCU = uiAbsPartIdx;
606  }
607  if( uiLog2TrafoSize == 2 )
608  {
609    UInt partNum = pcCU->getPic()->getNumPartInCU() >> ( ( uiDepth - 1 ) << 1 );
610    if( ( uiAbsPartIdx % partNum ) == 0 )
611    {
612      m_uiBakAbsPartIdx   = uiAbsPartIdx;
613      m_uiBakChromaOffset = offsetChroma;
614    }
615  }
616  if( pcCU->getPredictionMode(uiAbsPartIdx) == MODE_INTRA && pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_NxN && uiDepth == pcCU->getDepth(uiAbsPartIdx) )
617  {
618    uiSubdiv = 1;
619  }
620  else if( (pcCU->getSlice()->getSPS()->getQuadtreeTUMaxDepthInter() == 1) && (pcCU->getPredictionMode(uiAbsPartIdx) == MODE_INTER) && ( pcCU->getPartitionSize(uiAbsPartIdx) != SIZE_2Nx2N ) && (uiDepth == pcCU->getDepth(uiAbsPartIdx)) )
621  {
622    uiSubdiv = (uiLog2TrafoSize > quadtreeTULog2MinSizeInCU);
623  }
624  else if( uiLog2TrafoSize > pcCU->getSlice()->getSPS()->getQuadtreeTULog2MaxSize() )
625  {
626    uiSubdiv = 1;
627  }
628  else if( uiLog2TrafoSize == pcCU->getSlice()->getSPS()->getQuadtreeTULog2MinSize() )
629  {
630    uiSubdiv = 0;
631  }
632  else if( uiLog2TrafoSize == quadtreeTULog2MinSizeInCU )
633  {
634    uiSubdiv = 0;
635  }
636  else
637  {
638    assert( uiLog2TrafoSize > quadtreeTULog2MinSizeInCU );
639    m_pcEntropyDecoderIf->parseTransformSubdivFlag( uiSubdiv, 5 - uiLog2TrafoSize );
640  }
641 
642  const UInt uiTrDepth = uiDepth - pcCU->getDepth( uiAbsPartIdx );
643  {
644    const Bool bFirstCbfOfCU = uiTrDepth == 0;
645    if( bFirstCbfOfCU )
646    {
647      pcCU->setCbfSubParts( 0, TEXT_CHROMA_U, uiAbsPartIdx, uiDepth );
648      pcCU->setCbfSubParts( 0, TEXT_CHROMA_V, uiAbsPartIdx, uiDepth );
649    }
650    if( bFirstCbfOfCU || uiLog2TrafoSize > 2 )
651    {
652      if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth - 1 ) )
653      {
654        m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth, uiDepth );
655      }
656      if( bFirstCbfOfCU || pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth - 1 ) )
657      {
658        m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth, uiDepth );
659      }
660    }
661    else
662    {
663      pcCU->setCbfSubParts( pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth - 1 ) << uiTrDepth, TEXT_CHROMA_U, uiAbsPartIdx, uiDepth );
664      pcCU->setCbfSubParts( pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth - 1 ) << uiTrDepth, TEXT_CHROMA_V, uiAbsPartIdx, uiDepth );
665    }
666  }
667 
668  if( uiSubdiv )
669  {
670    UInt size;
671    width  >>= 1;
672    height >>= 1;
673    size = width*height;
674    uiTrIdx++;
675    ++uiDepth;
676    const UInt uiQPartNum = pcCU->getPic()->getNumPartInCU() >> (uiDepth << 1);
677    const UInt uiStartAbsPartIdx = uiAbsPartIdx;
678    UInt uiYCbf = 0;
679    UInt uiUCbf = 0;
680    UInt uiVCbf = 0;
681   
682    for( Int i = 0; i < 4; i++ )
683    {
684      xDecodeTransform( pcCU, offsetLuma, offsetChroma, uiAbsPartIdx, uiDepth, width, height, uiTrIdx, bCodeDQP, quadtreeTULog2MinSizeInCU );
685      uiYCbf |= pcCU->getCbf( uiAbsPartIdx, TEXT_LUMA, uiTrDepth+1 );
686      uiUCbf |= pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrDepth+1 );
687      uiVCbf |= pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrDepth+1 );
688      uiAbsPartIdx += uiQPartNum;
689      offsetLuma += size;  offsetChroma += (size>>2);
690    }
691   
692    for( UInt ui = 0; ui < 4 * uiQPartNum; ++ui )
693    {
694      pcCU->getCbf( TEXT_LUMA     )[uiStartAbsPartIdx + ui] |= uiYCbf << uiTrDepth;
695      pcCU->getCbf( TEXT_CHROMA_U )[uiStartAbsPartIdx + ui] |= uiUCbf << uiTrDepth;
696      pcCU->getCbf( TEXT_CHROMA_V )[uiStartAbsPartIdx + ui] |= uiVCbf << uiTrDepth;
697    }
698  }
699  else
700  {
701    assert( uiDepth >= pcCU->getDepth( uiAbsPartIdx ) );
702    pcCU->setTrIdxSubParts( uiTrDepth, uiAbsPartIdx, uiDepth );
703   
704#if !H_MV_ENC_DEC_TRAC
705    {
706      DTRACE_CABAC_VL( g_nSymbolCounter++ );
707      DTRACE_CABAC_T( "\tTrIdx: abspart=" );
708      DTRACE_CABAC_V( uiAbsPartIdx );
709      DTRACE_CABAC_T( "\tdepth=" );
710      DTRACE_CABAC_V( uiDepth );
711      DTRACE_CABAC_T( "\ttrdepth=" );
712      DTRACE_CABAC_V( uiTrDepth );
713      DTRACE_CABAC_T( "\n" );
714    }
715#endif
716   
717    pcCU->setCbfSubParts ( 0, TEXT_LUMA, uiAbsPartIdx, uiDepth );
718    if( pcCU->getPredictionMode(uiAbsPartIdx) != MODE_INTRA && uiDepth == pcCU->getDepth( uiAbsPartIdx ) && !pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, 0 ) && !pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, 0 ) )
719    {
720      pcCU->setCbfSubParts( 1 << uiTrDepth, TEXT_LUMA, uiAbsPartIdx, uiDepth );
721    }
722    else
723    {
724      m_pcEntropyDecoderIf->parseQtCbf( pcCU, uiAbsPartIdx, TEXT_LUMA, uiTrDepth, uiDepth );
725    }
726
727
728    // transform_unit begin
729    UInt cbfY = pcCU->getCbf( uiAbsPartIdx, TEXT_LUMA    , uiTrIdx );
730    UInt cbfU = pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_U, uiTrIdx );
731    UInt cbfV = pcCU->getCbf( uiAbsPartIdx, TEXT_CHROMA_V, uiTrIdx );
732    if( uiLog2TrafoSize == 2 )
733    {
734      UInt partNum = pcCU->getPic()->getNumPartInCU() >> ( ( uiDepth - 1 ) << 1 );
735      if( ( uiAbsPartIdx % partNum ) == (partNum - 1) )
736      {
737        cbfU = pcCU->getCbf( m_uiBakAbsPartIdx, TEXT_CHROMA_U, uiTrIdx );
738        cbfV = pcCU->getCbf( m_uiBakAbsPartIdx, TEXT_CHROMA_V, uiTrIdx );
739      }
740    }
741    if ( cbfY || cbfU || cbfV )
742    {
743      // dQP: only for LCU
744      if ( pcCU->getSlice()->getPPS()->getUseDQP() )
745      {
746        if ( bCodeDQP )
747        {
748          decodeQP( pcCU, m_bakAbsPartIdxCU);
749          bCodeDQP = false;
750        }
751      }
752    }
753    if( cbfY )
754    {
755      Int trWidth = width;
756      Int trHeight = height;
757      m_pcEntropyDecoderIf->parseCoeffNxN( pcCU, (pcCU->getCoeffY()+offsetLuma), uiAbsPartIdx, trWidth, trHeight, uiDepth, TEXT_LUMA );
758    }
759    if( uiLog2TrafoSize > 2 )
760    {
761      Int trWidth = width >> 1;
762      Int trHeight = height >> 1;
763      if( cbfU )
764      {
765        m_pcEntropyDecoderIf->parseCoeffNxN( pcCU, (pcCU->getCoeffCb()+offsetChroma), uiAbsPartIdx, trWidth, trHeight, uiDepth, TEXT_CHROMA_U );
766      }
767      if( cbfV )
768      {
769        m_pcEntropyDecoderIf->parseCoeffNxN( pcCU, (pcCU->getCoeffCr()+offsetChroma), uiAbsPartIdx, trWidth, trHeight, uiDepth, TEXT_CHROMA_V );
770      }
771    }
772    else
773    {
774      UInt partNum = pcCU->getPic()->getNumPartInCU() >> ( ( uiDepth - 1 ) << 1 );
775      if( ( uiAbsPartIdx % partNum ) == (partNum - 1) )
776      {
777        Int trWidth = width;
778        Int trHeight = height;
779        if( cbfU )
780        {
781          m_pcEntropyDecoderIf->parseCoeffNxN( pcCU, (pcCU->getCoeffCb()+m_uiBakChromaOffset), m_uiBakAbsPartIdx, trWidth, trHeight, uiDepth, TEXT_CHROMA_U );
782        }
783        if( cbfV )
784        {
785          m_pcEntropyDecoderIf->parseCoeffNxN( pcCU, (pcCU->getCoeffCr()+m_uiBakChromaOffset), m_uiBakAbsPartIdx, trWidth, trHeight, uiDepth, TEXT_CHROMA_V );
786        }
787      }
788    }
789    // transform_unit end
790  }
791}
792
793Void TDecEntropy::decodeQP          ( TComDataCU* pcCU, UInt uiAbsPartIdx )
794{
795  if ( pcCU->getSlice()->getPPS()->getUseDQP() )
796  {
797    m_pcEntropyDecoderIf->parseDeltaQP( pcCU, uiAbsPartIdx, pcCU->getDepth( uiAbsPartIdx ) );
798  }
799}
800
801
802/** decode coefficients
803 * \param pcCU
804 * \param uiAbsPartIdx
805 * \param uiDepth
806 * \param uiWidth
807 * \param uiHeight
808 * \returns Void
809 */
810Void TDecEntropy::decodeCoeff( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth, UInt uiWidth, UInt uiHeight, Bool& bCodeDQP )
811{
812  UInt uiMinCoeffSize = pcCU->getPic()->getMinCUWidth()*pcCU->getPic()->getMinCUHeight();
813  UInt uiLumaOffset   = uiMinCoeffSize*uiAbsPartIdx;
814  UInt uiChromaOffset = uiLumaOffset>>2;
815#if H_3D_DIM_SDC
816  if( pcCU->getSDCFlag( uiAbsPartIdx ) && pcCU->isIntra( uiAbsPartIdx) )
817  {
818    assert( pcCU->getPartitionSize(uiAbsPartIdx) == SIZE_2Nx2N );
819    assert( pcCU->getTransformIdx(uiAbsPartIdx) == 0 );
820    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_LUMA) == 1 );
821    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_U) == 1 );
822    assert( pcCU->getCbf(uiAbsPartIdx, TEXT_CHROMA_V) == 1 );
823  }
824
825#if H_3D_INTER_SDC
826  if( pcCU->getSDCFlag( uiAbsPartIdx ) && !pcCU->isIntra( uiAbsPartIdx) )
827  {
828    assert( !pcCU->isSkipped( uiAbsPartIdx ) );
829    assert( !pcCU->isIntra( uiAbsPartIdx) );
830    assert( pcCU->getSlice()->getIsDepth() );
831  }
832#endif
833  if( pcCU->getSlice()->getIsDepth() && ( pcCU->getSDCFlag( uiAbsPartIdx ) || pcCU->isIntra( uiAbsPartIdx ) ) )
834  {
835    Int iPartNum = ( pcCU->isIntra( uiAbsPartIdx ) && pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_NxN ) ? 4 : 1;
836    UInt uiPartOffset = ( pcCU->getPic()->getNumPartInCU() >> ( pcCU->getDepth( uiAbsPartIdx ) << 1 ) ) >> 2;
837 
838    if( !pcCU->getSDCFlag( uiAbsPartIdx ) )
839    {
840      for( Int iPart = 0; iPart < iPartNum; iPart++ )
841      {
842        if( getDimType( pcCU->getLumaIntraDir( uiAbsPartIdx + uiPartOffset*iPart ) ) < DIM_NUM_TYPE ) 
843        {
844          m_pcEntropyDecoderIf->parseDeltaDC( pcCU, uiAbsPartIdx + uiPartOffset*iPart, uiDepth + ( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_NxN ) );
845        }
846      }
847    }
848    else
849    {
850      m_pcEntropyDecoderIf->parseDeltaDC( pcCU, uiAbsPartIdx, uiDepth );
851      return;
852    }
853  }
854#endif
855
856  if( pcCU->isIntra(uiAbsPartIdx) )
857  {
858  }
859  else
860  {
861    UInt uiQtRootCbf = 1;
862    if( !( pcCU->getPartitionSize( uiAbsPartIdx) == SIZE_2Nx2N && pcCU->getMergeFlag( uiAbsPartIdx ) ) )
863    {
864      m_pcEntropyDecoderIf->parseQtRootCbf( uiAbsPartIdx, uiQtRootCbf );
865    }
866    if ( !uiQtRootCbf )
867    {
868      pcCU->setCbfSubParts( 0, 0, 0, uiAbsPartIdx, uiDepth );
869      pcCU->setTrIdxSubParts( 0 , uiAbsPartIdx, uiDepth );
870      return;
871    }
872   
873  }
874
875  Int getQuadtreeTULog2MinSizeInCU = pcCU->getQuadtreeTULog2MinSizeInCU(uiAbsPartIdx);
876
877  xDecodeTransform( pcCU, uiLumaOffset, uiChromaOffset, uiAbsPartIdx, uiDepth, uiWidth, uiHeight, 0, bCodeDQP, getQuadtreeTULog2MinSizeInCU );
878}
879
880#if H_3D_INTER_SDC
881Void TDecEntropy::decodeSDCFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
882{
883  pcCU->setSDCFlagSubParts( false, uiAbsPartIdx, uiDepth );
884
885  if( ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->getSlice()->getVPS()->getInterSDCFlag( pcCU->getSlice()->getLayerIdInVps() ) ) || 
886    ( pcCU->isIntra( uiAbsPartIdx ) && !pcCU->getSlice()->getVPS()->getVpsDepthModesFlag( pcCU->getSlice()->getLayerIdInVps() ) ) )
887  {
888    return;
889  }
890
891  if( !pcCU->getSlice()->getIsDepth() || pcCU->getPartitionSize( uiAbsPartIdx ) != SIZE_2Nx2N || pcCU->isSkipped( uiAbsPartIdx ) )
892  {
893    return;
894  }
895
896  assert( pcCU->getPartitionSize( uiAbsPartIdx ) == SIZE_2Nx2N || ( !pcCU->isIntra( uiAbsPartIdx ) && !pcCU->isSkipped( uiAbsPartIdx ) ) );
897  m_pcEntropyDecoderIf->parseSDCFlag( pcCU, uiAbsPartIdx, uiDepth );
898}
899#endif
900#if H_3D_DBBP
901Void TDecEntropy::decodeDBBPFlag( TComDataCU* pcCU, UInt uiAbsPartIdx, UInt uiDepth )
902{
903  m_pcEntropyDecoderIf->parseDBBPFlag( pcCU, uiAbsPartIdx, uiDepth );
904}
905#endif
906
907//! \}
Note: See TracBrowser for help on using the repository browser.