History

Add the log reduce logic into parse only mode

Haibo Zhu committed 10 years ago

Commit 3ccecfb1 parent c9433ee1 file · +8 −2Browse files

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

Unified · Split

codec/decoder/plus/src/welsDecoderExt.cpp+8−2
@@ -330,7 +330,8 @@ long CWelsDecoder::SetOption (DECODER_OPTION eOptID, void* pOption) { · 329 unmodified lines
330330 if (m_pWelsTrace) {
331331 WelsTraceCallback callback = * ((WelsTraceCallback*)pOption);
332332 m_pWelsTrace->SetTraceCallback (callback);
333− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "CWelsDecoder::SetOption():DECODER_OPTION_TRACE_CALLBACK callback = %p.",
333+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO,
334+ "CWelsDecoder::SetOption():DECODER_OPTION_TRACE_CALLBACK callback = %p.",
334335 callback);
335336 }
336337 return cmResultSuccess;
@@ -510,7 +511,7 @@ DECODING_STATE CWelsDecoder::DecodeFrame2 (const unsigned char* kpSrc, · 173 unmodified lines
510511 eNalType = m_pDecContext->sCurNalHead.eNalUnitType;
511512
512513 if (m_pDecContext->iErrorCode & dsOutOfMemory) {
513− if(ResetDecoder())
514+ if (ResetDecoder())
514515 return dsOutOfMemory;
515516 }
516517 //for AVC bitstream (excluding AVC with temporal scalability, including TP), as long as error occur, SHOULD notify upper layer key frame loss.
@@ -648,6 +649,11 @@ DECODING_STATE CWelsDecoder::DecodeParser (const unsigned char* kpSrc, · 131 unmodified lines
648649
649650 m_pDecContext->bInstantDecFlag = false; //reset no-delay flag
650651
652+ if (m_pDecContext->iErrorCode && m_pDecContext->bPrintFrameErrorTraceFlag) {
653+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "decode failed, failure type:%d \n", m_pDecContext->iErrorCode);
654+ m_pDecContext->bPrintFrameErrorTraceFlag = false;
655+ }
656+
651657 return (DECODING_STATE) m_pDecContext->iErrorCode;
652658 }
653659

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