1 // Copyright (c) 2012 The ANGLE Project Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef COMMON_EVENT_TRACER_H_ 6 #define COMMON_EVENT_TRACER_H_ 7 8 extern "C" { 9 10 typedef const unsigned char* (*GetCategoryEnabledFlagFunc)(const char* name); 11 typedef void (*AddTraceEventFunc)(char phase, const unsigned char* categoryGroupEnabled, const char* name, 12 unsigned long long id, int numArgs, const char** argNames, 13 const unsigned char* argTypes, const unsigned long long* argValues, 14 unsigned char flags); 15 16 // extern "C" so that it has a reasonable name for GetProcAddress. 17 void __stdcall SetTraceFunctionPointers(GetCategoryEnabledFlagFunc get_category_enabled_flag, 18 AddTraceEventFunc add_trace_event_func); 19 20 } 21 22 namespace gl 23 { 24 25 const unsigned char* TraceGetTraceCategoryEnabledFlag(const char* name); 26 27 void TraceAddTraceEvent(char phase, const unsigned char* categoryGroupEnabled, const char* name, unsigned long long id, 28 int numArgs, const char** argNames, const unsigned char* argTypes, 29 const unsigned long long* argValues, unsigned char flags); 30 31 } 32 33 #endif // COMMON_EVENT_TRACER_H_ 34