History

decrease dec log size

huili2 committed 12 years ago

Commit 581f8fd1 parent 68973985 files · +36 −23Browse files

Showing the changes to codec/decoder/plus/src (1 of 5 files). Show all

Unified · Split

codec/decoder/plus/src/welsDecoderExt.cpp+12−5
@@ -189,7 +189,7 @@ long CWelsDecoder::Initialize (const SDecodingParam* pParam) { · 188 unmodified lines
189189 }
190190
191191 if (pParam == NULL) {
192− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "CWelsDecoder::Initialize(), invalid input argument.");
192+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_ERROR, "CWelsDecoder::Initialize(), invalid input argument.");
193193 return cmInitParaError;
194194 }
195195
@@ -211,7 +211,7 @@ void CWelsDecoder::UninitDecoder (void) { · 15 unmodified lines
211211 if (NULL == m_pDecContext)
212212 return;
213213
214− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "into CWelsDecoder::uninit_decoder()..");
214+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "CWelsDecoder::uninit_decoder()..");
215215
216216 WelsEndDecoder (m_pDecContext);
217217
@@ -221,7 +221,6 @@ void CWelsDecoder::UninitDecoder (void) { · 3 unmodified lines
221221 m_pDecContext = NULL;
222222 }
223223
224− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "left CWelsDecoder::uninit_decoder()..");
225224 }
226225
227226 // the return value of this function is not suitable, it need report failure info to upper layer.
@@ -233,7 +232,6 @@ void CWelsDecoder::InitDecoder (void) { · 5 unmodified lines
233232
234233 WelsInitDecoder (m_pDecContext, &m_pWelsTrace->m_sLogCtx);
235234
236− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "CWelsDecoder::init_decoder().. left");
237235 }
238236
239237 /*
@@ -411,8 +409,17 @@ DECODING_STATE CWelsDecoder::DecodeFrame2 (const unsigned char* kpSrc, · 171 unmodified lines
411409 }
412410 }
413411
414− WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "decode failed, failure type:%d \n",
412+ if (m_pDecContext->bPrintFrameErrorTraceFlag) {
413+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, "decode failed, failure type:%d \n",
415414 m_pDecContext->iErrorCode);
415+ m_pDecContext->bPrintFrameErrorTraceFlag = false;
416+ } else {
417+ m_pDecContext->iIgnoredErrorInfoPacketCount ++;
418+ if (m_pDecContext->iIgnoredErrorInfoPacketCount == INT_MAX) {
419+ WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_WARNING, "continuous error reached INT_MAX! Restart as 0.");
420+ m_pDecContext->iIgnoredErrorInfoPacketCount = 0;
421+ }
422+ }
416423 return (DECODING_STATE)m_pDecContext->iErrorCode;
417424 } else { //decoding correct, but may have ECed status
418425 if (m_pDecContext->bDecErrorConedFlag) {

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