History

Remove tabs where a simple space is just enough

Martin Storsjö committed 11 years ago

Commit ca51ee01 parent 51efa5754 files · +769 −772Browse files

Showing the changes to codec/encoder/core/src/slice_multi_threading.cpp (1 of 54 files). Show all

Unified · Split

codec/encoder/core/src/slice_multi_threading.cpp+52−52
@@ -131,7 +131,7 @@ void CalcSliceComplexRatio (void* pRatio, SSliceCtx* pSliceCtx, uint32_t* pSlice · 130 unmodified lines
131131 WelsEmms();
132132
133133 while (iSliceIdx < kiSliceCount) {
134− iAvI[iSliceIdx] = WELS_DIV_ROUND (INT_MULTIPLY * pCountMbInSlice[iSliceIdx], pSliceTime[iSliceIdx]);
134+ iAvI[iSliceIdx] = WELS_DIV_ROUND (INT_MULTIPLY * pCountMbInSlice[iSliceIdx], pSliceTime[iSliceIdx]);
135135 MT_TRACE_LOG (NULL, WELS_LOG_DEBUG, "[MT] CalcSliceComplexRatio(), pSliceConsumeTime[%d]= %d us, slice_run= %d",
136136 iSliceIdx,
137137 pSliceTime[iSliceIdx], pCountMbInSlice[iSliceIdx]);
@@ -183,7 +183,7 @@ int32_t NeedDynamicAdjust (void* pConsumeTime, const int32_t iSliceNum) { · 45 unmodified lines
183183 } else
184184 fThr = 1.0f;
185185 if (fRmse > fThr)
186− iNeedAdj = true;
186+ iNeedAdj = true;
187187 MT_TRACE_LOG (NULL, WELS_LOG_DEBUG,
188188 "[MT] NeedDynamicAdjust(), herein adjustment decision is made (iNeedAdj= %d) by: fRmse of pSlice complexity ratios %.6f, the corresponding threshold %.6f, iCountSliceNum %d",
189189 iNeedAdj, fRmse, fThr, iSliceNum);
@@ -222,19 +222,19 @@ void DynamicAdjustSlicing (sWelsEncCtx* pCtx, · 32 unmodified lines
222222 if (iNumMbInEachGom * kiCountSliceNum >= kiCountNumMb) {
223223 return;
224224 }
225− iMinimalMbNum = iNumMbInEachGom;
225+ iMinimalMbNum = iNumMbInEachGom;
226226 }
227227
228228 if (kiCountSliceNum < 2 || (kiCountSliceNum & 0x01)) // we need suppose uiSliceNum is even for multiple threading
229229 return;
230230
231− iMaximalMbNum = kiCountNumMb - (kiCountSliceNum - 1) * iMinimalMbNum;
231+ iMaximalMbNum = kiCountNumMb - (kiCountSliceNum - 1) * iMinimalMbNum;
232232
233233 WelsEmms();
234234
235235 MT_TRACE_LOG (pCtx, WELS_LOG_DEBUG, "[MT] DynamicAdjustSlicing(), iDid= %d, iCountNumMb= %d", iCurDid, kiCountNumMb);
236236
237− iSliceIdx = 0;
237+ iSliceIdx = 0;
238238 while (iSliceIdx + 1 < kiCountSliceNum) {
239239 int32_t iNumMbAssigning = WELS_DIV_ROUND (kiCountNumMb * pSliceComplexRatio[iSliceIdx], INT_MULTIPLY);
240240
@@ -245,9 +245,9 @@ void DynamicAdjustSlicing (sWelsEncCtx* pCtx, · 4 unmodified lines
245245
246246 // make sure one GOM at least in each pSlice for safe
247247 if (iNumMbAssigning < iMinimalMbNum)
248− iNumMbAssigning = iMinimalMbNum;
248+ iNumMbAssigning = iMinimalMbNum;
249249 else if (iNumMbAssigning > iMaximalMbNum)
250− iNumMbAssigning = iMaximalMbNum;
250+ iNumMbAssigning = iMaximalMbNum;
251251
252252 assert (iNumMbAssigning > 0);
253253
@@ -256,13 +256,13 @@ void DynamicAdjustSlicing (sWelsEncCtx* pCtx, · 2 unmodified lines
256256 assert (0);
257257 return;
258258 }
259− iRunLen[iSliceIdx] = iNumMbAssigning;
259+ iRunLen[iSliceIdx] = iNumMbAssigning;
260260 MT_TRACE_LOG (pCtx, WELS_LOG_DEBUG,
261261 "[MT] DynamicAdjustSlicing(), uiSliceIdx= %d, pSliceComplexRatio= %.2f, slice_run_org= %d, slice_run_adj= %d",
262262 iSliceIdx, pSliceComplexRatio[iSliceIdx] * 1.0f / INT_MULTIPLY, pSliceCtx->pCountMbNumInSlice[iSliceIdx],
263263 iNumMbAssigning);
264264 ++ iSliceIdx;
265− iMaximalMbNum = iMbNumLeft - (kiCountSliceNum - iSliceIdx - 1) * iMinimalMbNum; // get maximal num_mb in left parts
265+ iMaximalMbNum = iMbNumLeft - (kiCountSliceNum - iSliceIdx - 1) * iMinimalMbNum; // get maximal num_mb in left parts
266266 }
267267 iRunLen[iSliceIdx] = iMbNumLeft;
268268 MT_TRACE_LOG (pCtx, WELS_LOG_DEBUG,
@@ -301,16 +301,16 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 32 unmodified lines
301301 if (NULL == ppCtx || NULL == pCodingParam || NULL == *ppCtx || iCountBsLen <= 0)
302302 return 1;
303303
304− pMa = (*ppCtx)->pMemAlign;
304+ pMa = (*ppCtx)->pMemAlign;
305305 pPara = pCodingParam;
306− iNumSpatialLayers = pPara->iSpatialLayerNum;
307− iThreadNum = pPara->iCountThreadsNum;
306+ iNumSpatialLayers = pPara->iSpatialLayerNum;
307+ iThreadNum = pPara->iCountThreadsNum;
308308 iMaxSliceNum = (*ppCtx)->iMaxSliceCount;
309309
310− pSmt = (SSliceThreading*)pMa->WelsMalloc (sizeof (SSliceThreading), "SSliceThreading");
310+ pSmt = (SSliceThreading*)pMa->WelsMalloc (sizeof (SSliceThreading), "SSliceThreading");
311311 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == pSmt), FreeMemorySvc (ppCtx))
312− (*ppCtx)->pSliceThreading = pSmt;
313− pSmt->pThreadPEncCtx = (SSliceThreadPrivateData*)pMa->WelsMalloc (sizeof (SSliceThreadPrivateData) * iThreadNum,
312+ (*ppCtx)->pSliceThreading = pSmt;
313+ pSmt->pThreadPEncCtx = (SSliceThreadPrivateData*)pMa->WelsMalloc (sizeof (SSliceThreadPrivateData) * iThreadNum,
314314 "pThreadPEncCtx");
315315 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == pSmt->pThreadPEncCtx), FreeMemorySvc (ppCtx))
316316
@@ -323,14 +323,14 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 6 unmodified lines
323323
324324 iIdx = 0;
325325 while (iIdx < iNumSpatialLayers) {
326− SSliceConfig* pMso = &pPara->sSpatialLayers[iIdx].sSliceCfg;
326+ SSliceConfig* pMso = &pPara->sSpatialLayers[iIdx].sSliceCfg;
327327 const int32_t kiSliceNum = pMso->sSliceArgument.uiSliceNum;
328328 if (((pMso->uiSliceMode == SM_FIXEDSLCNUM_SLICE) || (pMso->uiSliceMode == SM_AUTO_SLICE))
329329 && pPara->iMultipleThreadIdc > 1
330330 && pPara->iMultipleThreadIdc >= kiSliceNum) {
331− pSmt->pSliceConsumeTime[iIdx] = (uint32_t*)pMa->WelsMallocz (kiSliceNum * sizeof (uint32_t), "pSliceConsumeTime[]");
331+ pSmt->pSliceConsumeTime[iIdx] = (uint32_t*)pMa->WelsMallocz (kiSliceNum * sizeof (uint32_t), "pSliceConsumeTime[]");
332332 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == pSmt->pSliceConsumeTime[iIdx]), FreeMemorySvc (ppCtx))
333− pSmt->pSliceComplexRatio[iIdx] = (int32_t*)pMa->WelsMalloc (kiSliceNum * sizeof (int32_t), "pSliceComplexRatio[]");
333+ pSmt->pSliceComplexRatio[iIdx] = (int32_t*)pMa->WelsMalloc (kiSliceNum * sizeof (int32_t), "pSliceComplexRatio[]");
334334 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == pSmt->pSliceComplexRatio[iIdx]), FreeMemorySvc (ppCtx))
335335 } else {
336336 pSmt->pSliceConsumeTime[iIdx] = NULL;
@@ -348,7 +348,7 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 11 unmodified lines
348348 fclose (pSmt->pFSliceDiff);
349349 pSmt->pFSliceDiff = NULL;
350350 }
351− pSmt->pFSliceDiff = fopen ("slice_time.txt", "wt+");
351+ pSmt->pFSliceDiff = fopen ("slice_time.txt", "wt+");
352352 #endif//MT_DEBUG
353353
354354 MT_TRACE_LOG (*ppCtx, WELS_LOG_INFO, "encpEncCtx= 0x%p", (void*) *ppCtx);
@@ -392,7 +392,7 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 37 unmodified lines
392392 err = WelsEventOpen (&pSmt->pSliceCodedMasterEvent, name);
393393 MT_TRACE_LOG (*ppCtx, WELS_LOG_INFO, "[MT] Open pSliceCodedMasterEvent named(%s) ret%d err%d", name, err, errno);
394394
395− (*ppCtx)->pSliceBs = (SWelsSliceBs*)pMa->WelsMalloc (sizeof (SWelsSliceBs) * iMaxSliceNum, "pSliceBs");
395+ (*ppCtx)->pSliceBs = (SWelsSliceBs*)pMa->WelsMalloc (sizeof (SWelsSliceBs) * iMaxSliceNum, "pSliceBs");
396396 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == (*ppCtx)->pSliceBs), FreeMemorySvc (ppCtx))
397397
398398 pBsBase = (*ppCtx)->pFrameBs + iCountBsLen;
@@ -403,7 +403,7 @@ int32_t RequestMtResource (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPara · 4 unmodified lines
403403 pSliceB->pBsBuffer = (uint8_t*)pMa->WelsMalloc (iSliceBsBufferSize, "pSliceB->pBsBuffer");
404404
405405 WELS_VERIFY_RETURN_PROC_IF (1, (NULL == pSliceB->pBsBuffer), FreeMemorySvc (ppCtx))
406− pSliceB->uiSize = iSliceBsBufferSize;
406+ pSliceB->uiSize = iSliceBsBufferSize;
407407
408408 if (iIdx > 0) {
409409 pSliceB->pBs = pBsBase;
@@ -537,7 +537,7 @@ int32_t AppendSliceToFrameBs (sWelsEncCtx* pCtx, SLayerBSInfo* pLbi, const int32 · 127 unmodified lines
537537 ++ pSliceBs;
538538 if (pSliceBs != NULL && pSliceBs->uiBsPos > 0) {
539539 int32_t iNalIdx = 0;
540− const int32_t iCountNal = pSliceBs->iNalIndex;
540+ const int32_t iCountNal = pSliceBs->iNalIndex;
541541
542542 #if MT_DEBUG_BS_WR
543543 assert (pSliceBs->bSliceCodedFlag);
@@ -549,7 +549,7 @@ int32_t AppendSliceToFrameBs (sWelsEncCtx* pCtx, SLayerBSInfo* pLbi, const int32 · 5 unmodified lines
549549 iLayerSize += pSliceBs->uiBsPos;
550550
551551 while (iNalIdx < iCountNal) {
552− pLbi->pNalLengthInByte[iNalIdxBase + iNalIdx] = pSliceBs->iNalLen[iNalIdx];
552+ pLbi->pNalLengthInByte[iNalIdxBase + iNalIdx] = pSliceBs->iNalLen[iNalIdx];
553553 ++ iNalIdx;
554554 }
555555 pLbi->iNalCount += iCountNal;
@@ -567,13 +567,13 @@ int32_t AppendSliceToFrameBs (sWelsEncCtx* pCtx, SLayerBSInfo* pLbi, const int32 · 11 unmodified lines
567567 const int32_t kiCountSlicesCoded = pCtx->pCurDqLayer->pNumSliceCodedOfPartition[iPartitionIdx];
568568 int32_t iIdx = 0;
569569
570− iSliceIdx = iPartitionIdx;
570+ iSliceIdx = iPartitionIdx;
571571 while (iIdx < kiCountSlicesCoded) {
572− pSliceBs = &pCtx->pSliceBs[iSliceIdx];
572+ pSliceBs = &pCtx->pSliceBs[iSliceIdx];
573573 if (pSliceBs != NULL && pSliceBs->uiBsPos > 0) {
574574 if (iPartitionIdx > 0) {
575575 int32_t iNalIdx = 0;
576− const int32_t iCountNal = pSliceBs->iNalIndex;
576+ const int32_t iCountNal = pSliceBs->iNalIndex;
577577
578578 memmove (pCtx->pFrameBs + pCtx->iPosBsBuffer, pSliceBs->pBs, pSliceBs->uiBsPos); // confirmed_safe_unsafe_usage
579579 pCtx->iPosBsBuffer += pSliceBs->uiBsPos;
@@ -581,13 +581,13 @@ int32_t AppendSliceToFrameBs (sWelsEncCtx* pCtx, SLayerBSInfo* pLbi, const int32 · 1 unmodified line
581581 iLayerSize += pSliceBs->uiBsPos;
582582
583583 while (iNalIdx < iCountNal) {
584− pLbi->pNalLengthInByte[iNalIdxBase + iNalIdx] = pSliceBs->iNalLen[iNalIdx];
584+ pLbi->pNalLengthInByte[iNalIdxBase + iNalIdx] = pSliceBs->iNalLen[iNalIdx];
585585 ++ iNalIdx;
586586 }
587587 pLbi->iNalCount += iCountNal;
588588 iNalIdxBase += iCountNal;
589589 } else {
590− iLayerSize += pSliceBs->uiBsPos;
590+ iLayerSize += pSliceBs->uiBsPos;
591591 }
592592 }
593593
@@ -622,12 +622,12 @@ int32_t WriteSliceToFrameBs (sWelsEncCtx* pCtx, SLayerBSInfo* pLbi, uint8_t* pFr · 28 unmodified lines
622622 WELS_VERIFY_RETURN_IFNEQ (iReturn, ENC_RETURN_SUCCESS)
623623 iSliceSize += iNalSize;
624624 pDst += iNalSize;
625− pLbi->pNalLengthInByte[iNalBase + iNalIdx] = iNalSize;
625+ pLbi->pNalLengthInByte[iNalBase + iNalIdx] = iNalSize;
626626
627627 ++ iNalIdx;
628628 }
629629
630− pSliceBs->uiBsPos = iSliceSize;
630+ pSliceBs->uiBsPos = iSliceSize;
631631 if (iFirstSlice) {
632632 // pBsBuffer has been updated at coding_slice_0_in_encoder_mother_thread()
633633 pLbi->uiLayerType = VIDEO_CODING_LAYER;
@@ -653,7 +653,7 @@ int32_t WriteSliceBs (sWelsEncCtx* pCtx, uint8_t* pSliceBsBuf, const int32_t iSl · 19 unmodified lines
653653 int32_t iReturn = ENC_RETURN_SUCCESS;
654654 const int32_t kiWrittenLength = (int32_t) (pSliceBs->sBsWrite.pCurBuf - pSliceBs->sBsWrite.pStartBuf);
655655
656− iSliceSize = 0;
656+ iSliceSize = 0;
657657 assert (kiNalCnt <= 2);
658658 if (kiNalCnt > 2)
659659 return 0;
@@ -668,7 +668,7 @@ int32_t WriteSliceBs (sWelsEncCtx* pCtx, uint8_t* pSliceBsBuf, const int32_t iSl · 8 unmodified lines
668668 pDst += iNalSize;
669669 ++ iNalIdx;
670670 }
671− pSliceBs->uiBsPos = iSliceSize;
671+ pSliceBs->uiBsPos = iSliceSize;
672672
673673 return iReturn;
674674 }
@@ -727,7 +727,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 52 unmodified lines
727727 bNeedPrefix = pEncPEncCtx->bNeedPrefixNalFlag;
728728
729729 if (pParamD->sSliceCfg.uiSliceMode != SM_DYN_SLICE) {
730− int64_t iSliceStart = 0;
730+ int64_t iSliceStart = 0;
731731 bool bDsaFlag = false;
732732 iSliceIdx = pPrivateData->iSliceIndex;
733733 pSlice = &pCurDq->sLayerInfo.pSliceInLayer[iSliceIdx];
@@ -746,7 +746,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 12 unmodified lines
746746 InitBits (&pSliceBs->sBsWrite, pSliceBs->pBsBuffer, pSliceBs->uiSize);
747747
748748 #if MT_DEBUG_BS_WR
749− pSliceBs->bSliceCodedFlag = false;
749+ pSliceBs->bSliceCodedFlag = false;
750750 #endif//MT_DEBUG_BS_WR
751751
752752 if (bNeedPrefix) {
@@ -772,7 +772,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 19 unmodified lines
772772 WelsUnloadNalForSlice (pSliceBs);
773773
774774 if (0 == iSliceIdx) {
775− pLbi->pBsBuf = pEncPEncCtx->pFrameBs + pEncPEncCtx->iPosBsBuffer;
775+ pLbi->pBsBuf = pEncPEncCtx->pFrameBs + pEncPEncCtx->iPosBsBuffer;
776776 iReturn = WriteSliceToFrameBs (pEncPEncCtx, pLbi, pLbi->pBsBuf, iSliceIdx, iSliceSize);
777777 if (ENC_RETURN_SUCCESS != iReturn) {
778778 uiThrdRet = iReturn;
@@ -818,7 +818,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 39 unmodified lines
818818 #endif//SLICE_INFO_OUTPUT
819819
820820 #if MT_DEBUG_BS_WR
821− pSliceBs->bSliceCodedFlag = true;
821+ pSliceBs->bSliceCodedFlag = true;
822822 #endif//MT_DEBUG_BS_WR
823823
824824 WelsEventSignal (
@@ -833,7 +833,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 8 unmodified lines
833833 const int32_t kiEndMbInPartition = pPrivateData->iEndMbIndex; // exclusive
834834 int32_t iAnyMbLeftInPartition = kiEndMbInPartition - kiFirstMbInPartition;
835835
836− iSliceIdx = pPrivateData->iSliceIndex;
836+ iSliceIdx = pPrivateData->iSliceIndex;
837837
838838 pSliceCtx->pFirstMbInSlice[iSliceIdx] = kiFirstMbInPartition;
839839 pCurDq->pNumSliceCodedOfPartition[kiPartitionId] = 1; // one pSlice per partition intialized, dynamic slicing inside
@@ -845,7 +845,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 5 unmodified lines
845845 if (iSliceIdx >= pSliceCtx->iMaxSliceNumConstraint) {
846846 // TODO: need exception handler for not large enough of MAX_SLICES_NUM related memory usage
847847 // No idea about its solution due MAX_SLICES_NUM is fixed lenght in relevent pData structure
848− uiThrdRet = 1;
848+ uiThrdRet = 1;
849849 break;
850850 }
851851
@@ -880,7 +880,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 28 unmodified lines
880880
881881 if (0 == kiPartitionId) {
882882 if (0 == iSliceIdx)
883− pLbi->pBsBuf = pEncPEncCtx->pFrameBs + pEncPEncCtx->iPosBsBuffer;
883+ pLbi->pBsBuf = pEncPEncCtx->pFrameBs + pEncPEncCtx->iPosBsBuffer;
884884 iReturn = WriteSliceToFrameBs (pEncPEncCtx, pLbi, pEncPEncCtx->pFrameBs + pEncPEncCtx->iPosBsBuffer, iSliceIdx,
885885 iSliceSize);
886886 if (ENC_RETURN_SUCCESS != iReturn) {
@@ -931,13 +931,13 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 44 unmodified lines
931931 WelsEventSignal (&pEncPEncCtx->pSliceThreading->pSliceCodedEvent[iEventIdx]); // mean finished coding current pSlice
932932 WelsEventSignal (&pEncPEncCtx->pSliceThreading->pSliceCodedMasterEvent);
933933 }
934− } else if (WELS_THREAD_ERROR_WAIT_OBJECT_0 + 1 == iWaitRet) { // exit thread signal
935− uiThrdRet = 0;
934+ } else if (WELS_THREAD_ERROR_WAIT_OBJECT_0 + 1 == iWaitRet) { // exit thread signal
935+ uiThrdRet = 0;
936936 break;
937− } else if (WELS_THREAD_ERROR_WAIT_OBJECT_0 + 2 == iWaitRet) { // update pMb list singal
938− iSliceIdx =
939− iEventIdx; // pPrivateData->iSliceIndex; old threads can not be terminated, pPrivateData is not correct for applicable
940− pCurDq = pEncPEncCtx->pCurDqLayer;
937+ } else if (WELS_THREAD_ERROR_WAIT_OBJECT_0 + 2 == iWaitRet) { // update pMb list singal
938+ iSliceIdx =
939+ iEventIdx; // pPrivateData->iSliceIndex; old threads can not be terminated, pPrivateData is not correct for applicable
940+ pCurDq = pEncPEncCtx->pCurDqLayer;
941941 UpdateMbListNeighborParallel (pCurDq->pSliceEncCtx, pCurDq->sMbDataP, iSliceIdx);
942942 WelsEventSignal (
943943 &pEncPEncCtx->pSliceThreading->pFinUpdateMbListEvent[iEventIdx]); // mean finished update pMb list for this pSlice
@@ -945,7 +945,7 @@ WELS_THREAD_ROUTINE_TYPE CodingSliceThreadProc (void* arg) { · 1 unmodified line
945945 WelsLog (& (pEncPEncCtx->sLogCtx), WELS_LOG_WARNING,
946946 "[MT] CodingSliceThreadProc(), waiting pReadySliceCodingEvent[%d] failed(%d) and thread%d terminated!", iEventIdx,
947947 iWaitRet, iThreadIdx);
948− uiThrdRet = 1;
948+ uiThrdRet = 1;
949949 break;
950950 }
951951 } while (1);
@@ -991,7 +991,7 @@ int32_t FiredSliceThreads (sWelsEncCtx* pCtx, SSliceThreadPrivateData* pPriData, · 39 unmodified lines
991991
992992 ////////////////////////////////////////
993993 if (bIsDynamicSlicingMode) {
994− iEndMbIdx = pSliceCtx->iMbNumInFrame;
994+ iEndMbIdx = pSliceCtx->iMbNumInFrame;
995995 for (iIdx = kiEventCnt - 1; iIdx >= 0; --iIdx) {
996996 const int32_t iFirstMbIdx = pSliceCtx->pFirstMbInSlice[iIdx];
997997 pPriData[iIdx].iStartMbIndex = iFirstMbIdx;
@@ -1003,7 +1003,7 @@ int32_t FiredSliceThreads (sWelsEncCtx* pCtx, SSliceThreadPrivateData* pPriData, · 5 unmodified lines
10031003 iIdx = 0;
10041004 while (iIdx < kiEventCnt) {
10051005 pPriData[iIdx].pLayerBs = pLbi;
1006− pPriData[iIdx].iSliceIndex = iIdx;
1006+ pPriData[iIdx].iSliceIndex = iIdx;
10071007 if (pEventsList[iIdx])
10081008 WelsEventSignal (&pEventsList[iIdx]);
10091009 if (pMasterEventsList[iIdx])
@@ -1027,10 +1027,10 @@ int32_t AdjustBaseLayer (sWelsEncCtx* pCtx) { · 17 unmodified lines
10271027 int64_t iT0 = WelsTime();
10281028 #endif//MT_DEBUG
10291029
1030− pCtx->pCurDqLayer = pCurDq;
1030+ pCtx->pCurDqLayer = pCurDq;
10311031
10321032 // do not need adjust due to not different at both slices of consumed time
1033− iNeedAdj = NeedDynamicAdjust (pCtx->pSliceThreading->pSliceConsumeTime[0], pCurDq->pSliceEncCtx->iSliceNumInFrame);
1033+ iNeedAdj = NeedDynamicAdjust (pCtx->pSliceThreading->pSliceConsumeTime[0], pCurDq->pSliceEncCtx->iSliceNumInFrame);
10341034 if (iNeedAdj)
10351035 DynamicAdjustSlicing (pCtx,
10361036 pCurDq,
@@ -1056,7 +1056,7 @@ int32_t AdjustEnhanceLayer (sWelsEncCtx* pCtx, int32_t iCurDid) { · 19 unmodified lines
10561056 // uiSliceMode of referencing spatial should be SM_FIXEDSLCNUM_SLICE
10571057 // if using spatial base layer for complexity estimation
10581058
1059− const bool kbModelingFromSpatial = (pCtx->pCurDqLayer->pRefLayer != NULL && iCurDid > 0)
1059+ const bool kbModelingFromSpatial = (pCtx->pCurDqLayer->pRefLayer != NULL && iCurDid > 0)
10601060 && (pCtx->pSvcParam->sSpatialLayers[iCurDid - 1].sSliceCfg.uiSliceMode == SM_FIXEDSLCNUM_SLICE
10611061 && pCtx->pSvcParam->iMultipleThreadIdc >= pCtx->pSvcParam->sSpatialLayers[iCurDid -
10621062 1].sSliceCfg.sSliceArgument.uiSliceNum);
@@ -1119,7 +1119,7 @@ void TrackSliceConsumeTime (sWelsEncCtx* pCtx, int32_t* pDidList, const int32_t · 56 unmodified lines
11191119 if (iSpatialNum > MAX_DEPENDENCY_LAYER)
11201120 return;
11211121
1122− pPara = pCtx->pSvcParam;
1122+ pPara = pCtx->pSvcParam;
11231123 while (iSpatialIdx < iSpatialNum) {
11241124 const int32_t kiDid = pDidList[iSpatialIdx];
11251125 SSpatialLayerInternal* pDlp = &pPara->sDependencyLayers[kiDid];

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t