History

add slice_type check for num_ref_frame

huili2 committed 11 years ago

Commit 04007921 parent 87c73071 file · +7 −0Browse files

Showing the changes to codec/decoder/core/src/decoder_core.cpp (1 of 1 file). Show all

Unified · Split

codec/decoder/core/src/decoder_core.cpp+7−0
@@ -791,6 +791,13 @@ int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, co · 790 unmodified lines
791 791
792 pSliceHeadExt->pSubsetSps = pSubsetSps;792 pSliceHeadExt->pSubsetSps = pSubsetSps;
793 793
794 if (pSps->iNumRefFrames == 0) {
795 if ((uiSliceType != I_SLICE) && (uiSliceType != SI_SLICE)) {
796 WelsLog (pLogCtx, WELS_LOG_WARNING, "slice_type (%d) not supported for num_ref_frames = 0.", uiSliceType);
797 return GENERATE_ERROR_NO (ERR_LEVEL_SLICE_HEADER, ERR_INFO_INVALID_SLICE_TYPE);
798 }
799 }
800
794 bIdrFlag = (!kbExtensionFlag && eNalType == NAL_UNIT_CODED_SLICE_IDR) || (kbExtensionFlag && pNalHeaderExt->bIdrFlag);801 bIdrFlag = (!kbExtensionFlag && eNalType == NAL_UNIT_CODED_SLICE_IDR) || (kbExtensionFlag && pNalHeaderExt->bIdrFlag);
795 pSliceHead->bIdrFlag = bIdrFlag;802 pSliceHead->bIdrFlag = bIdrFlag;
796 803

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