Showing the changes to codec/decoder/core/src/decode_slice.cpp (1 of 57 files). Show all
Unified · Split
| @@ -120,7 +120,7 @@ int32_t WelsTargetSliceConstruction (PWelsDecoderContext pCtx) { · 119 unmodified lines | ||
| 120 | 120 | } else { |
| 121 | 121 | ++iNextMbXyIndex; |
| 122 | 122 | } |
| 123 | − if (-1 == iNextMbXyIndex || iNextMbXyIndex >= iTotalMbTargetLayer) { // slice group boundary or end of a frame | |
| 123 | + if (-1 == iNextMbXyIndex || iNextMbXyIndex >= iTotalMbTargetLayer) { // slice group boundary or end of a frame | |
| 124 | 124 | break; |
| 125 | 125 | } |
| 126 | 126 | pCurLayer->iMbX = iNextMbXyIndex % pCurLayer->iMbWidth; |
| @@ -155,8 +155,8 @@ int32_t WelsMbInterSampleConstruction (PWelsDecoderContext pCtx, PDqLayer pCurLa · 28 unmodified lines | ||
| 155 | 155 | int32_t iMbXy = pCurLayer->iMbXyIndex; |
| 156 | 156 | int32_t i, iIndex, iOffset; |
| 157 | 157 | |
| 158 | − WelsChromaDcIdct (pCurLayer->pScaledTCoeff[iMbXy] + 256); // 256 = 16*16 | |
| 159 | − WelsChromaDcIdct (pCurLayer->pScaledTCoeff[iMbXy] + 320); // 320 = 16*16 + 16*4 | |
| 158 | + WelsChromaDcIdct (pCurLayer->pScaledTCoeff[iMbXy] + 256); // 256 = 16*16 | |
| 159 | + WelsChromaDcIdct (pCurLayer->pScaledTCoeff[iMbXy] + 320); // 320 = 16*16 + 16*4 | |
| 160 | 160 | |
| 161 | 161 | if (pCurLayer->pTransformSize8x8Flag[iMbXy]) { |
| 162 | 162 | for (i = 0; i < 4; i++) { |
| @@ -227,7 +227,7 @@ void WelsLumaDcDequantIdct (int16_t* pBlock, int32_t iQp, PWelsDecoderContext pC · 64 unmodified lines | ||
| 227 | 227 | const int32_t kiX1 = kiOffset + kiXOffset[2]; |
| 228 | 228 | const int32_t kiX2 = STRIDE + kiOffset; |
| 229 | 229 | const int32_t kiX3 = kiOffset + kiXOffset[3]; |
| 230 | − const int32_t kiI4 = i << 2; // 4*i | |
| 230 | + const int32_t kiI4 = i << 2; // 4*i | |
| 231 | 231 | const int32_t kiZ0 = pBlk[kiOffset] + pBlk[kiX1]; |
| 232 | 232 | const int32_t kiZ1 = pBlk[kiOffset] - pBlk[kiX1]; |
| 233 | 233 | const int32_t kiZ2 = pBlk[kiX2] - pBlk[kiX3]; |
| @@ -1227,7 +1227,7 @@ int32_t WelsDecodeSlice (PWelsDecoderContext pCtx, bool bFirstSliceInLayer, PNal · 993 unmodified lines | ||
| 1227 | 1227 | pCurLayer->iMbXyIndex = iNextMbXyIndex; |
| 1228 | 1228 | |
| 1229 | 1229 | do { |
| 1230 | − if ((-1 == iNextMbXyIndex) || (iNextMbXyIndex >= kiCountNumMb)) { // slice group boundary or end of a frame | |
| 1230 | + if ((-1 == iNextMbXyIndex) || (iNextMbXyIndex >= kiCountNumMb)) { // slice group boundary or end of a frame | |
| 1231 | 1231 | break; |
| 1232 | 1232 | } |
| 1233 | 1233 | |
| @@ -1564,7 +1564,7 @@ int32_t WelsDecodeMbCavlcISlice (PWelsDecoderContext pCtx, PNalUnit pNalCur, uin · 330 unmodified lines | ||
| 1564 | 1564 | // check whether there is left bits to read next time in case multiple slices |
| 1565 | 1565 | iUsedBits = ((pBs->pCurBuf - pBs->pStartBuf) << 3) - (16 - pBs->iLeftBits); |
| 1566 | 1566 | // sub 1, for stop bit |
| 1567 | − if ((iUsedBits == (pBs->iBits - 1)) && (0 >= pCurLayer->sLayerInfo.sSliceInLayer.iMbSkipRun)) { // slice boundary | |
| 1567 | + if ((iUsedBits == (pBs->iBits - 1)) && (0 >= pCurLayer->sLayerInfo.sSliceInLayer.iMbSkipRun)) { // slice boundary | |
| 1568 | 1568 | uiEosFlag = 1; |
| 1569 | 1569 | } |
| 1570 | 1570 | if (iUsedBits > (pBs->iBits - |
| @@ -1987,7 +1987,7 @@ int32_t WelsDecodeMbCavlcPSlice (PWelsDecoderContext pCtx, PNalUnit pNalCur, uin · 416 unmodified lines | ||
| 1987 | 1987 | // check whether there is left bits to read next time in case multiple slices |
| 1988 | 1988 | iUsedBits = ((pBs->pCurBuf - pBs->pStartBuf) << 3) - (16 - pBs->iLeftBits); |
| 1989 | 1989 | // sub 1, for stop bit |
| 1990 | − if ((iUsedBits == (pBs->iBits - 1)) && (0 >= pCurLayer->sLayerInfo.sSliceInLayer.iMbSkipRun)) { // slice boundary | |
| 1990 | + if ((iUsedBits == (pBs->iBits - 1)) && (0 >= pCurLayer->sLayerInfo.sSliceInLayer.iMbSkipRun)) { // slice boundary | |
| 1991 | 1991 | uiEosFlag = 1; |
| 1992 | 1992 | } |
| 1993 | 1993 | if (iUsedBits > (pBs->iBits - |