ref: c8299d7d8fa77ac14727e0e58747abd2d6a0806d
parent: db11ba7a34d1e7e984596325a63d74191259e003
author: ruil2 <[email protected]>
date: Tue May 27 10:51:09 EDT 2014
simplify stash pop bs
--- a/codec/encoder/core/src/svc_encode_slice.cpp
+++ b/codec/encoder/core/src/svc_encode_slice.cpp
@@ -593,11 +593,7 @@
sDss.iCurrentPos = BsGetBitsPos (pBs);
if (DynSlcJudgeSliceBoundaryStepBack (pEncCtx, pSlice, pSliceCtx, pCurMb, &sDss)) { //islice
- //stack pBs pointer
- pBs->pBufPtr = sDss.pBsStackBufPtr;
- pBs->uiCurBits = sDss.uiBsStackCurBits;
- pBs->iLeftBits = sDss.iBsStackLeftBits;
-
+ StashPopMBStatus (&sDss, pBs, pSlice);
pCurLayer->pLastCodedMbIdxOfPartition[kiPartitionId] = iCurMbIdx -
1; // update pLastCodedMbIdxOfPartition, need to -1 due to stepping back
++ pCurLayer->pNumSliceCodedOfPartition[kiPartitionId];
@@ -1116,13 +1112,7 @@
//DYNAMIC_SLICING_ONE_THREAD - MultiD
sDss.iCurrentPos = BsGetBitsPos (pBs);
if (DynSlcJudgeSliceBoundaryStepBack (pEncCtx, pSlice, pSliceCtx, pCurMb, &sDss)) {
- //stack pBs pointer
- pBs->pBufPtr = sDss.pBsStackBufPtr;
- pBs->uiCurBits = sDss.uiBsStackCurBits;
- pBs->iLeftBits = sDss.iBsStackLeftBits;
-
- iMbSkipRun = sDss.iMbSkipRunStack;
-
+ StashPopMBStatus (&sDss, pBs, pSlice, &iMbSkipRun);
pCurLayer->pLastCodedMbIdxOfPartition[kiPartitionId] = iCurMbIdx -
1; // update pLastCodedMbIdxOfPartition, need to -1 due to stepping back
++ pCurLayer->pNumSliceCodedOfPartition[kiPartitionId];