Ignition Rendering

API Reference

5.0.0
RenderEngineManager.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015 Open Source Robotics Foundation
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17 #ifndef IGNITION_RENDERING_RENDERENGINEMANAGER_HH_
18 #define IGNITION_RENDERING_RENDERENGINEMANAGER_HH_
19 
20 #include <list>
21 #include <map>
22 #include <memory>
23 #include <string>
24 #include <vector>
27 #include "ignition/rendering/config.hh"
28 #include "ignition/rendering/Export.hh"
29 
30 namespace ignition
31 {
32  namespace rendering
33  {
34  inline namespace IGNITION_RENDERING_VERSION_NAMESPACE {
35  //
36  // forward declarations.
37  class RenderEngine;
38  class RenderEngineManagerPrivate;
39 
46  class IGNITION_RENDERING_VISIBLE RenderEngineManager :
47  public virtual common::SingletonT<RenderEngineManager>
48  {
50  public: RenderEngineManager();
51 
53  public: ~RenderEngineManager();
54 
57  public: unsigned int EngineCount() const;
58 
63  public: bool HasEngine(const std::string &_name) const;
64 
69  public: bool IsEngineLoaded(const std::string &_name) const;
70 
73  public: std::vector<std::string> LoadedEngines() const;
74 
82  public: RenderEngine *Engine(const std::string &_name,
83  const std::map<std::string, std::string> &_params = {},
84  const std::string &_path = "");
85 
92  public: RenderEngine *EngineAt(unsigned int _index,
93  const std::map<std::string, std::string> &_params = {},
94  const std::string &_path = "");
95 
101  public: bool UnloadEngine(const std::string &_name);
102 
108  public: bool UnloadEngineAt(unsigned int _index);
109 
115  public: void RegisterEngine(const std::string &_name,
116  RenderEngine *_engine);
117 
122  public: void UnregisterEngine(const std::string &_name);
123 
127  public: void UnregisterEngine(RenderEngine *_engine);
128 
132  public: void UnregisterEngineAt(unsigned int _index);
133 
136  public: void SetPluginPaths(const std::list<std::string> &_paths);
137 
142 
145  };
146  }
147  }
148 }
149 #endif
Collection of render-engines. This provides access to all the render-engines available at runtime...
Definition: RenderEngineManager.hh:46
#define IGN_COMMON_WARN_RESUME__DLL_INTERFACE_MISSING
STL class.
STL class.
STL class.
An abstract interface to a concrete render-engine. A RenderEngine is responsible for initializing a r...
Definition: RenderEngine.hh:36
#define IGN_COMMON_WARN_IGNORE__DLL_INTERFACE_MISSING