| 500 | } |
| 501 | |
| 502 | int32_t AdjustBaseLayer (sWelsEncCtx* pCtx) { |
| 503 | SDqLayer* pCurDq = pCtx->ppDqLayerList[0]; |
| 504 | int32_t iNeedAdj = 1; |
| 505 | #ifdef MT_DEBUG |
| 506 | int64_t iT0 = WelsTime(); |
| 507 | #endif//MT_DEBUG |
| 508 | |
| 509 | pCtx->pCurDqLayer = pCurDq; |
| 510 | |
| 511 | // do not need adjust due to not different at both slices of consumed time |
| 512 | iNeedAdj = NeedDynamicAdjust (pCtx->ppDqLayerList[0]->ppSliceInLayer |
| 513 | , pCurDq->sSliceEncCtx.iSliceNumInFrame); |
| 514 | if (iNeedAdj) |
| 515 | DynamicAdjustSlicing (pCtx, |
| 516 | pCurDq, |
| 517 | 0); |
| 518 | #ifdef MT_DEBUG |
| 519 | iT0 = WelsTime() - iT0; |
| 520 | if (pCtx->pSliceThreading->pFSliceDiff) { |
| 521 | fprintf (pCtx->pSliceThreading->pFSliceDiff, |
| 522 | "%6" PRId64" us adjust time at base spatial layer, iNeedAdj %d, DynamicAdjustSlicing()\n", |
| 523 | iT0, iNeedAdj); |
| 524 | } |
| 525 | #endif//MT_DEBUG |
| 526 | |
| 527 | return iNeedAdj; |
| 528 | } |
| 529 | |
| 530 | int32_t AdjustEnhanceLayer (sWelsEncCtx* pCtx, int32_t iCurDid) { |
| 531 | #ifdef MT_DEBUG |
no test coverage detected