Ignore:
Timestamp:
Apr 2, 2013, 4:31:30 PM (7 years ago)
Author:
ldelgass
Message:

Add writer thread to nanovis (set USE_THREADS in Makefile), more refactoring.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/Trace.h

    r3597 r3605  
    1818#define AT __FILE__ ":" NEWSTRING(__LINE__)
    1919
     20namespace nv {
     21
     22extern void logUserMessage(const char* format, ...);
     23
     24extern const char *getUserMessages();
     25
     26extern void clearUserMessages();
     27
     28extern void initLog();
     29
     30extern void closeLog();
     31
    2032extern void LogMessage(int priority, const char *funcname, const char *fileName,
    2133                       int lineNum, const char* format, ...);
    2234
    23 #define ERROR(...)      LogMessage(LOG_ERR, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
     35#define ERROR(...)      nv::LogMessage(LOG_ERR, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
    2436#ifdef WANT_TRACE
    25 #define TRACE(...)      LogMessage(LOG_DEBUG, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
     37#define TRACE(...)      nv::LogMessage(LOG_DEBUG, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
    2638#else
    2739#define TRACE(...)
    2840#endif
    29 #define WARN(...)       LogMessage(LOG_WARNING, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
    30 #define INFO(...)       LogMessage(LOG_INFO, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
     41#define WARN(...)       nv::LogMessage(LOG_WARNING, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
     42#define INFO(...)       nv::LogMessage(LOG_INFO, __FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
     43
     44#define USER_ERROR(...) nv::logUserMessage(__VA_ARGS__)
     45
     46}
    3147
    3248extern bool CheckFBO(GLenum *status);
    3349extern void PrintFBOStatus(GLenum status, const char *prefix);
    3450extern bool CheckGL(const char *prefix);
     51
    3552#endif
Note: See TracChangeset for help on using the changeset viewer.