Ocean
GLESEngineAndroid.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_RENDERING_GLES_ANDROID_GLES_ENGINE_ANDROID_H
9 #define META_OCEAN_RENDERING_GLES_ANDROID_GLES_ENGINE_ANDROID_H
10 
13 
14 namespace Ocean
15 {
16 
17 namespace Rendering
18 {
19 
20 namespace GLESceneGraph
21 {
22 
23 namespace Android
24 {
25 
26 /**
27  * This class implements the engine for Android platforms.
28  * @ingroup renderinggles
29  */
30 class OCEAN_RENDERING_GLES_EXPORT GLESEngineAndroid : public GLESEngine
31 {
32  public:
33 
34  /**
35  * Creates this engine and registeres it at the global engine manager.<br>
36  * Do not register this engine if using it as plugin, because it's done by the plugin itself.<br>
37  * However, if your not using the plugin mechanism you have to initialize this engine once at program initialization.<br>
38  * If the library is not used anymore unregister it using the unregister function.<br>
39  * Beware: This registration must not be done more than once!
40  * @see Manager, GLESEngine::unregisterEngine()
41  */
42  static void registerEngine();
43 
44  protected:
45 
46  /**
47  * Creates a new rendering engine.
48  * @param graphicAPI Preferred graphic API to use by the engine
49  */
50  GLESEngineAndroid(const GraphicAPI graphicAPI);
51 
52  /**
53  * Destructs a rendering engine.
54  */
55  ~GLESEngineAndroid() override = default;
56 
57  /**
58  * Returns a framebuffer reference of a just created framebuffer object.
59  * @see Engine::internalCreateFramebuffer().
60  */
62 
63  /**
64  * Creates a new Nvidia SceniX rendering engine.
65  * @param graphicAPI Preferred graphic API to use by the engine
66  * @return New rendering engine
67  */
68  static Engine* createEngine(const GraphicAPI graphicAPI);
69 };
70 
71 }
72 
73 }
74 
75 }
76 
77 }
78 
79 #endif // META_OCEAN_RENDERING_GLES_ANDROID_GLES_ENGINE_ANDROID_H
This class is the base class for all rendering engines like.
Definition: Engine.h:46
GraphicAPI
Definition of different graphic APIs.
Definition: Engine.h:57
This class holds framebuffer configurations.
Definition: rendering/Framebuffer.h:94
This class is the base class for all rendering framebuffers.
Definition: rendering/Framebuffer.h:48
FramebufferType
Definition of different framebuffer types.
Definition: rendering/Framebuffer.h:55
This class implements the engine for Android platforms.
Definition: GLESEngineAndroid.h:31
static void registerEngine()
Creates this engine and registeres it at the global engine manager.
Framebuffer * internalCreateFramebuffer(const Framebuffer::FramebufferType type, const Framebuffer::FramebufferConfig &config) override
Returns a framebuffer reference of a just created framebuffer object.
static Engine * createEngine(const GraphicAPI graphicAPI)
Creates a new Nvidia SceniX rendering engine.
GLESEngineAndroid(const GraphicAPI graphicAPI)
Creates a new rendering engine.
~GLESEngineAndroid() override=default
Destructs a rendering engine.
This class is the base class for all GLESceneGraph engines.
Definition: GLESEngine.h:30
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15