egllog.h revision 3464ebd5
13464ebd5Sriastradh/************************************************************************** 23464ebd5Sriastradh * 33464ebd5Sriastradh * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. 43464ebd5Sriastradh * Copyright 2009-2010 Chia-I Wu <olvaffe@gmail.com> 53464ebd5Sriastradh * All Rights Reserved. 63464ebd5Sriastradh * 73464ebd5Sriastradh * Permission is hereby granted, free of charge, to any person obtaining a 83464ebd5Sriastradh * copy of this software and associated documentation files (the 93464ebd5Sriastradh * "Software"), to deal in the Software without restriction, including 103464ebd5Sriastradh * without limitation the rights to use, copy, modify, merge, publish, 113464ebd5Sriastradh * distribute, sub license, and/or sell copies of the Software, and to 123464ebd5Sriastradh * permit persons to whom the Software is furnished to do so, subject to 133464ebd5Sriastradh * the following conditions: 143464ebd5Sriastradh * 153464ebd5Sriastradh * The above copyright notice and this permission notice (including the 163464ebd5Sriastradh * next paragraph) shall be included in all copies or substantial portions 173464ebd5Sriastradh * of the Software. 183464ebd5Sriastradh * 193464ebd5Sriastradh * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 203464ebd5Sriastradh * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 213464ebd5Sriastradh * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 223464ebd5Sriastradh * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 233464ebd5Sriastradh * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 243464ebd5Sriastradh * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 253464ebd5Sriastradh * DEALINGS IN THE SOFTWARE. 263464ebd5Sriastradh * 273464ebd5Sriastradh **************************************************************************/ 283464ebd5Sriastradh 293464ebd5Sriastradh 304a49301eSmrg#ifndef EGLLOG_INCLUDED 314a49301eSmrg#define EGLLOG_INCLUDED 324a49301eSmrg 33cdc920a0Smrg 344a49301eSmrg#include "egltypedefs.h" 354a49301eSmrg 36cdc920a0Smrg 374a49301eSmrg#define _EGL_FATAL 0 /* unrecoverable error */ 384a49301eSmrg#define _EGL_WARNING 1 /* recoverable error/problem */ 394a49301eSmrg#define _EGL_INFO 2 /* just useful info */ 404a49301eSmrg#define _EGL_DEBUG 3 /* useful info for debugging */ 414a49301eSmrg 424a49301eSmrg 434a49301eSmrgtypedef void (*_EGLLogProc)(EGLint level, const char *msg); 444a49301eSmrg 454a49301eSmrg 46cdc920a0SmrgPUBLIC void 474a49301eSmrg_eglSetLogProc(_EGLLogProc logger); 484a49301eSmrg 494a49301eSmrg 50cdc920a0SmrgPUBLIC void 514a49301eSmrg_eglSetLogLevel(EGLint level); 524a49301eSmrg 534a49301eSmrg 54cdc920a0SmrgPUBLIC void 554a49301eSmrg_eglLog(EGLint level, const char *fmtStr, ...); 564a49301eSmrg 574a49301eSmrg 584a49301eSmrg#endif /* EGLLOG_INCLUDED */ 59