shithub: openh264

Download patch

ref: 072fe4398c6481b4aae69f2b80dcda571299d930
parent: 61b9ddce8e2e8437babffe6e838b2acc873dc994
parent: 036c8b2aab8ae40feb7263f04cec3ae13ad0e3db
author: huili2 <huili2@cisco.com>
date: Mon Nov 28 08:58:42 EST 2016

Merge pull request #2608 from ruil2/src_error

fix source picture error mapping issue

--- a/codec/encoder/core/src/wels_preprocess.cpp
+++ b/codec/encoder/core/src/wels_preprocess.cpp
@@ -358,7 +358,6 @@
   int32_t iTargetWidth              = 0;
   int32_t iTargetHeight             = 0;
   int32_t iTemporalId = 0;
-  SSpatialPicIndex* pSpatialIndexMap = &pCtx->sSpatialIndexMap[0];
   int32_t iClosestDid =  iDependencyId;
   pDlayerParamInternal = &pSvcParam->sDependencyLayers[iDependencyId];
   pDlayerParam = &pSvcParam->sSpatialLayers[iDependencyId];
@@ -437,8 +436,7 @@
     while (iDependencyId >= 0) {
       pDlayerParamInternal = &pSvcParam->sDependencyLayers[iDependencyId];
       pDlayerParam = &pSvcParam->sSpatialLayers[iDependencyId];
-      SPicture* pSrcPic  = (pSpatialIndexMap + iClosestDid)->pSrc;; // large
-      //SPicture* pSrcPic  = (pSpatialIndexMap + (pSvcParam->iSpatialLayerNum - 1))->pSrc;; // large
+      SPicture* pSrcPic  = m_pLastSpatialPicture[iClosestDid][1]; // large
       iTargetWidth  = pDlayerParam->iVideoWidth;
       iTargetHeight = pDlayerParam->iVideoHeight;
       iTemporalId = pDlayerParamInternal->uiCodingIdx2TemporalId[pDlayerParamInternal->iCodingIndex &