1/*
2 * Copyright (c) 2008-2015, NVIDIA CORPORATION. All rights reserved.
3 *
4 * NVIDIA CORPORATION and its licensors retain all intellectual property
5 * and proprietary rights in and to this software, related documentation
6 * and any modifications thereto. Any use, reproduction, disclosure or
7 * distribution of this software and related documentation without an express
8 * license agreement from NVIDIA CORPORATION is strictly prohibited.
9 */
10
11#ifndef PX_PROFILE_EVENT_NAMES_H
12#define PX_PROFILE_EVENT_NAMES_H
13
14#include "physxprofilesdk/PxProfileBase.h"
15#include "physxprofilesdk/PxProfileEventId.h"
16
17namespace physx {
18
19 //Mapping from event id to name.
20 struct PxProfileEventName
21 {
22 const char* mName;
23 PxProfileEventId mEventId;
24 PxProfileEventName( const char* inName, PxProfileEventId inId ) : mName( inName ), mEventId( inId ) {}
25 };
26
27 //Aggregator of event id -> name mappings
28 struct PxProfileNames
29 {
30 PxU32 mEventCount;
31 const PxProfileEventName* mEvents;
32 //Default constructor that doesn't point to any names.
33 PxProfileNames( PxU32 inEventCount = 0, const PxProfileEventName* inSubsystems = NULL )
34 : mEventCount( inEventCount )
35 , mEvents( inSubsystems )
36 {
37 }
38 };
39
40 /**
41 Provides a mapping from event ID -> name.
42 */
43 class PxProfileNameProvider
44 {
45 public:
46 virtual PxProfileNames getProfileNames() const = 0;
47 protected:
48 virtual ~PxProfileNameProvider(){}
49 PxProfileNameProvider& operator=(const PxProfileNameProvider&) { return *this; }
50 };
51}
52
53#endif // PX_PROFILE_EVENT_NAMES_H
54