Skip to content

Commit

Permalink
WIP: set location of RTShaders
Browse files Browse the repository at this point in the history
  • Loading branch information
simonschmeisser committed Mar 27, 2022
1 parent 5f48109 commit 99ce932
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/rviz/ogre_helpers/render_system.cpp
Expand Up @@ -261,6 +261,12 @@ void RenderSystem::setupRenderSystem()

void RenderSystem::setupResources()
{
auto& rgm = Ogre::ResourceGroupManager::getSingleton();
// todo: need to get from CMake/pkgconfig: const auto& mediaDir = Ogre::FileSystemLayer::resolveBundlePath(OGRE_MEDIA_DIR);
// add default locations
// todo: set in OGREBites but does not exist rgm.addResourceLocation(mediaDir + "/usr/share/OGRE-1.12.13/Media/Main", "FileSystem", Ogre::RGN_INTERNAL);
rgm.addResourceLocation(/*mediaDir +*/ "/usr/share/OGRE-1.12.13/Media/RTShaderLib/GLSL", "FileSystem", Ogre::RGN_INTERNAL);

std::string rviz_path = ros::package::getPath(ROS_PACKAGE_NAME);
Ogre::ResourceGroupManager::getSingleton().addResourceLocation(
rviz_path + "/ogre_media", "FileSystem", Ogre::ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME);
Expand Down

0 comments on commit 99ce932

Please sign in to comment.