Home | Info | Community | Development | myReactOS | Contact Us
ReactOS Development > Doxygenddlog.h
Go to the documentation of this file.
00001 /**************************************************************************** 00002 * 00003 * Mesa 3-D graphics library 00004 * Direct3D Driver Interface 00005 * 00006 * ======================================================================== 00007 * 00008 * Copyright (C) 1991-2004 SciTech Software, Inc. All rights reserved. 00009 * 00010 * Permission is hereby granted, free of charge, to any person obtaining a 00011 * copy of this software and associated documentation files (the "Software"), 00012 * to deal in the Software without restriction, including without limitation 00013 * the rights to use, copy, modify, merge, publish, distribute, sublicense, 00014 * and/or sell copies of the Software, and to permit persons to whom the 00015 * Software is furnished to do so, subject to the following conditions: 00016 * 00017 * The above copyright notice and this permission notice shall be included 00018 * in all copies or substantial portions of the Software. 00019 * 00020 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 00021 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 00022 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 00023 * SCITECH SOFTWARE INC BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 00024 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF 00025 * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 00026 * SOFTWARE. 00027 * 00028 * ====================================================================== 00029 * 00030 * Language: ANSI C 00031 * Environment: Windows 9x (Win32) 00032 * 00033 * Description: Logging functions. 00034 * 00035 ****************************************************************************/ 00036 00037 #ifndef __DDLOG_H 00038 #define __DDLOG_H 00039 00040 #include <stdio.h> 00041 00042 #ifndef _USE_GLD3_WGL 00043 #include "dderrstr.h" // ddraw/d3d error string 00044 #endif 00045 00046 /*---------------------- Macros and type definitions ----------------------*/ 00047 00048 typedef enum { 00049 DDLOG_NONE = 0, // No log output 00050 DDLOG_NORMAL = 1, // Log is kept open 00051 DDLOG_CRASHPROOF = 2, // Log is closed and flushed 00052 DDLOG_METHOD_FORCE_DWORD = 0x7fffffff, 00053 } DDLOG_loggingMethodType; 00054 00055 // Denotes type of message sent to the logging functions 00056 typedef enum { 00057 DDLOG_INFO = 0, // Information only 00058 DDLOG_WARN = 1, // Warning only 00059 DDLOG_ERROR = 2, // Notify user of an error 00060 DDLOG_CRITICAL = 3, // Exceptionally severe error 00061 DDLOG_SYSTEM = 4, // System message. Not an error 00062 // but must always be printed. 00063 DDLOG_SEVERITY_FORCE_DWORD = 0x7fffffff, // Make enum dword 00064 } DDLOG_severityType; 00065 00066 #ifdef _USE_GLD3_WGL 00067 // Synomyms 00068 #define GLDLOG_INFO DDLOG_INFO 00069 #define GLDLOG_WARN DDLOG_WARN 00070 #define GLDLOG_ERROR DDLOG_ERROR 00071 #define GLDLOG_CRITICAL DDLOG_CRITICAL 00072 #define GLDLOG_SYSTEM DDLOG_SYSTEM 00073 #endif 00074 00075 // The message that will be output to the log 00076 static const char *ddlogSeverityMessages[] = { 00077 "INFO", 00078 "WARN", 00079 "ERROR", 00080 "*CRITICAL*", 00081 "System", 00082 }; 00083 00084 /*------------------------- Function Prototypes ---------------------------*/ 00085 00086 #ifdef __cplusplus 00087 extern "C" { 00088 #endif 00089 00090 void ddlogOpen(DDLOG_loggingMethodType LoggingMethod, DDLOG_severityType Severity); 00091 void ddlogClose(); 00092 void ddlogMessage(DDLOG_severityType severity, LPSTR message); 00093 void ddlogError(DDLOG_severityType severity, LPSTR message, HRESULT hResult); 00094 void ddlogPrintf(DDLOG_severityType severity, LPSTR message, ...); 00095 void ddlogWarnOption(BOOL bWarnOption); 00096 void ddlogPathOption(LPSTR szPath); 00097 00098 #ifdef _USE_GLD3_WGL 00099 // Synomyms 00100 #define gldLogMessage ddlogMessage 00101 #define gldLogError ddlogError 00102 #define gldLogPrintf ddlogPrintf 00103 #endif 00104 00105 #ifdef __cplusplus 00106 } 00107 #endif 00108 00109 #endif Generated on Sat May 26 2012 04:18:43 for ReactOS by
1.7.6.1
|