Ticket #1060: wpp_contexts_r2.patch
File wpp_contexts_r2.patch, 1.9 KB (added by ksuehring, 11 years ago) |
---|
-
source/Lib/TLibDecoder/TDecSlice.h
83 83 Void decompressSlice ( TComInputBitstream** ppcSubstreams, TComPic*& rpcPic, TDecSbac* pcSbacDecoder, TDecSbac* pcSbacDecoders ); 84 84 Void initCtxMem( UInt i ); 85 85 Void setCtxMem( TDecSbac* sb, Int b ) { CTXMem[b] = sb; } 86 Int getCtxMemSize( ) { return (Int)CTXMem.size(); } 86 87 }; 87 88 88 89 -
source/Lib/TLibDecoder/TDecTop.cpp
265 265 assert (0); 266 266 } 267 267 268 if( pps->getDependentSliceSegmentsEnabledFlag() ) 269 { 270 Int NumCtx = pps->getEntropyCodingSyncEnabledFlag()?2:1; 271 272 if (m_cSliceDecoder.getCtxMemSize() != NumCtx) 273 { 274 m_cSliceDecoder.initCtxMem(NumCtx); 275 for ( UInt st = 0; st < NumCtx; st++ ) 276 { 277 TDecSbac* ctx = NULL; 278 ctx = new TDecSbac; 279 ctx->init( &m_cBinCABAC ); 280 m_cSliceDecoder.setCtxMem( ctx, st ); 281 } 282 } 283 } 284 268 285 m_apcSlicePilot->setPPS(pps); 269 286 m_apcSlicePilot->setSPS(sps); 270 287 pps->setSPS(sps); … … 612 629 TComPPS* pps = new TComPPS(); 613 630 m_cEntropyDecoder.decodePPS( pps ); 614 631 m_parameterSetManagerDecoder.storePrefetchedPPS( pps ); 615 616 if( pps->getDependentSliceSegmentsEnabledFlag() )617 {618 Int NumCtx = pps->getEntropyCodingSyncEnabledFlag()?2:1;619 m_cSliceDecoder.initCtxMem(NumCtx);620 for ( UInt st = 0; st < NumCtx; st++ )621 {622 TDecSbac* ctx = NULL;623 ctx = new TDecSbac;624 ctx->init( &m_cBinCABAC );625 m_cSliceDecoder.setCtxMem( ctx, st );626 }627 }628 632 } 629 633 630 634 Void TDecTop::xDecodeSEI( TComInputBitstream* bs, const NalUnitType nalUnitType )