Ocean
SceneDescription.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) Meta Platforms, Inc. and affiliates.
3  *
4  * This source code is licensed under the MIT license found in the
5  * LICENSE file in the root directory of this source tree.
6  */
7 
8 #ifndef META_OCEAN_SCENEDESCRIPTION_SCENE_DESCRIPTION_H
9 #define META_OCEAN_SCENEDESCRIPTION_SCENE_DESCRIPTION_H
10 
11 #include "ocean/base/Base.h"
12 #include "ocean/base/Messenger.h"
13 
14 namespace Ocean
15 {
16 
17 namespace SceneDescription
18 {
19 
20 /**
21  * @defgroup scenedescription Ocean SceneDescription Abstraction Library
22  * @{
23  * The Ocean SceneDescription Library is the base library and organizer of all scene description libraries.<br>
24  * Several different scene description libraries can be registered and managed at the same time.<br>
25  * Each library may support a different types of scene description files / specifications.<br>
26  * The Manager object manages all registered libraries and hides the internal complexity.<br>
27  * The library is platform independent.<br>
28  * @see Manager, Scene
29  * @}
30  */
31 
32 /**
33  * @namespace Ocean::SceneDescription Namespace of the SceneDescription library.<p>
34  * The Namespace Ocean::SceneDescription is used in the entire Ocean SceneDescription Library.
35  */
36 
37 /**
38  * Definition of a object id.
39  * @ingroup scenedescription
40  */
41 typedef size_t NodeId;
42 
43 /**
44  * Definition of an invalid object id.
45  * @ingroup scenedescription
46  */
47 constexpr NodeId invalidNodeId = NodeId(-1);
48 
49 /**
50  * Definition of a unique scene id.
51  */
52 typedef size_t SceneId;
53 
54 /**
55  * Definition of an invalid scene id.
56  */
57 constexpr SceneId invalidSceneId = SceneId(-1);
58 
59 /**
60  * Definition of different scene description types.
61  * @ingroup scenedescription
62  */
63 enum DescriptionType : uint32_t
64 {
65  /// A scene description holding a transient scene hierarchy only.
67  /// A scene description holding a permanent scene hierarchy allowing permanent access.
68  TYPE_PERMANENT = 2u
69 };
70 
71 /**
72  * Definition of different button types.
73  * @ingroup scenedescription
74  */
76 {
77  // Invalid button.
79  /// Left button.
81  /// Middle button.
83  /// Right button.
85 };
86 
87 /**
88  * Definition of different device events.
89  * @ingroup scenedescription
90  */
92 {
93  /// Press event.
95  /// Hold event.
97  /// Release event.
99 };
100 
101 // Defines OCEAN_SCENEDESCRIPTION_EXPORT for dll export and import.
102 #if defined(_WINDOWS) && defined(OCEAN_RUNTIME_SHARED)
103  #ifdef USE_OCEAN_SCENEDESCRIPTION_EXPORT
104  #define OCEAN_SCENEDESCRIPTION_EXPORT __declspec(dllexport)
105  #else
106  #define OCEAN_SCENEDESCRIPTION_EXPORT __declspec(dllimport)
107  #endif
108 #else
109  #define OCEAN_SCENEDESCRIPTION_EXPORT
110 #endif
111 
112 }
113 
114 }
115 
116 #endif // META_OCEAN_SCENEDESCRIPTION_SCENE_DESCRIPTION_H
ButtonEvent
Definition of different device events.
Definition: SceneDescription.h:92
DescriptionType
Definition of different scene description types.
Definition: SceneDescription.h:64
ButtonType
Definition of different button types.
Definition: SceneDescription.h:76
constexpr NodeId invalidNodeId
Definition of an invalid object id.
Definition: SceneDescription.h:47
size_t NodeId
Definition of a object id.
Definition: SceneDescription.h:41
@ EVENT_PRESS
Press event.
Definition: SceneDescription.h:94
@ EVENT_HOLD
Hold event.
Definition: SceneDescription.h:96
@ EVENT_RELEASE
Release event.
Definition: SceneDescription.h:98
@ TYPE_TRANSIENT
A scene description holding a transient scene hierarchy only.
Definition: SceneDescription.h:66
@ TYPE_PERMANENT
A scene description holding a permanent scene hierarchy allowing permanent access.
Definition: SceneDescription.h:68
@ BUTTON_MIDDLE
Middle button.
Definition: SceneDescription.h:82
@ BUTTON_NONE
Definition: SceneDescription.h:78
@ BUTTON_RIGHT
Right button.
Definition: SceneDescription.h:84
@ BUTTON_LEFT
Left button.
Definition: SceneDescription.h:80
constexpr SceneId invalidSceneId
Definition of an invalid scene id.
Definition: SceneDescription.h:57
size_t SceneId
Definition of a unique scene id.
Definition: SceneDescription.h:52
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15