Merge pull request #322 from volvet/PreProcessExceptionHandle

init the spatial last spatial picture if excption
This commit is contained in:
Licai Guo 2014-02-21 17:09:17 +08:00
commit e7ed80c428

View File

@ -405,6 +405,7 @@ int32_t CWelsPreProcess::UpdateSpatialPictures(sWelsEncCtx* pCtx, SWelsSvcCoding
const int8_t iCurTid, const int32_t d_idx) {
if (iCurTid < m_uiSpatialLayersInTemporal[d_idx] - 1 || pParam->iDecompStages == 0){
if ((iCurTid >= MAX_TEMPORAL_LEVEL) || (m_uiSpatialLayersInTemporal[d_idx] - 1 > MAX_TEMPORAL_LEVEL)) {
InitLastSpatialPictures(pCtx);
return 1;
}
if (pParam->bEnableLongTermReference && pCtx->bLongTermRefFlag[d_idx][iCurTid]) {