initialization.cpp
Go to the documentation of this file.
1 #include "initialization.h"
2 
3 #include <OgreRoot.h>
4 #include <OgreRenderSystem.h>
5 
6 #include <exception>
7 #include <stdexcept>
8 
9 #include <ros/package.h>
10 
11 namespace rviz
12 {
14 {
15  delete Ogre::Root::getSingletonPtr();
16 }
17 
18 // This should be folded into RenderSystem, but it should work fine as
19 // is, so I'm leaving it for now.
20 void initializeResources(const V_string& resource_paths)
21 {
22  V_string::const_iterator path_it = resource_paths.begin();
23  V_string::const_iterator path_end = resource_paths.end();
24  for (; path_it != path_end; ++path_it)
25  {
26  Ogre::ResourceGroupManager::getSingleton().addResourceLocation(
27  *path_it, "FileSystem", Ogre::ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME);
28  }
29 
30  Ogre::ResourceGroupManager::getSingleton().initialiseAllResourceGroups();
31 }
32 
33 } // namespace rviz
initialization.h
rviz::cleanupOgre
void cleanupOgre()
Definition: initialization.cpp:13
rviz::V_string
std::vector< std::string > V_string
Definition: effort_display.h:72
rviz
Definition: add_display_dialog.cpp:54
package.h
rviz::initializeResources
void initializeResources(const V_string &resource_paths)
Definition: initialization.cpp:20


rviz
Author(s): Dave Hershberger, David Gossow, Josh Faust, William Woodall
autogenerated on Fri Dec 13 2024 03:31:02