History

Rebase of EKR's patches for tracing and frame size

Ethan Hugg committed 12 years ago

Commit 2ca14fe1 parent 3747f569 files · +203 −14Browse files

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

Unified · Split

codec/decoder/plus/src/welsCodecTrace.cpp+13−3
@@ -44,6 +44,7 @@ · 43 unmodified lines
4444
4545 #include "welsCodecTrace.h"
4646 #include "utils.h"
47+#include "logging.h"
4748 #if defined LINUX || defined SOLARIS || defined UNIX || defined MACOS //LINUX/SOLARIS/UNIX
4849 #include <dlfcn.h>
4950 #endif
@@ -210,7 +211,7 @@ int32_t CWelsTraceWinDgb::WriteString(int32_t iLevel, const str_t * pStr) · 160 unmodified lines
210211 CWelsCodecTrace::CWelsCodecTrace()
211212 {
212213 m_hTraceHandle = NULL;
213− m_fpDebugTrace = NULL;
214+ m_fpDebugTrace = NULL;
214215 m_fpInfoTrace = NULL;
215216 m_fpWarnTrace = NULL;
216217 m_fpErrorTrace = NULL;
@@ -224,7 +225,13 @@ CWelsCodecTrace::~CWelsCodecTrace() · 7 unmodified lines
224225 }
225226
226227 int32_t CWelsCodecTrace::LoadWelsTraceModule()
227−{
228+{
229+#ifdef NO_DYNAMIC_VP
230+ m_fpDebugTrace = welsStderrTrace<WELS_LOG_DEBUG>;
231+ m_fpInfoTrace = welsStderrTrace<WELS_LOG_INFO>;
232+ m_fpWarnTrace = welsStderrTrace<WELS_LOG_WARNING>;
233+ m_fpErrorTrace = welsStderrTrace<WELS_LOG_ERROR>;
234+#else
228235 #if defined WIN32
229236 HMODULE hHandle = ::LoadLibrary("welstrace.dll");
230237 // HMODULE handle = ::LoadLibrary("contrace.dll"); // for c7 trace
@@ -307,6 +314,7 @@ int32_t CWelsCodecTrace::LoadWelsTraceModule() · 76 unmodified lines
307314 }
308315 }
309316 #endif
317+#endif // NO_DYNAMIC_VP
310318 return 0;
311319 }
312320
@@ -336,7 +344,9 @@ int32_t CWelsCodecTrace::UnloadWelsTraceModule() · 23 unmodified lines
336344
337345 int32_t CWelsCodecTrace::WriteString(int32_t iLevel, const str_t * pStr)
338346 {
347+#ifndef NO_DYNAMIC_VP
339348 if( m_hTraceHandle )
349+#endif
340350 {
341351 #ifdef WIN32
342352 switch(iLevel)
@@ -416,4 +426,4 @@ IWelsTrace * CreateWelsTrace(EWelsTraceType eType, void_t * pParam) · 73 unmodified lines
416426 return pTrace;
417427 }
418428
419−} // namespace WelsDec
429+} // namespace WelsDec

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