Revision: 8497
          http://playerstage.svn.sourceforge.net/playerstage/?rev=8497&view=rev
Author:   natepak
Date:     2010-01-13 04:40:58 +0000 (Wed, 13 Jan 2010)

Log Message:
-----------
Updates to match ogre < 1.7.0 and fixes to cmake

Modified Paths:
--------------
    code/gazebo/trunk/CMakeLists.txt
    code/gazebo/trunk/cmake/SearchForStuff.cmake
    code/gazebo/trunk/server/AssimpLoader.hh
    code/gazebo/trunk/server/CMakeLists.txt
    code/gazebo/trunk/server/gui/CMakeLists.txt
    code/gazebo/trunk/server/rendering/CMakeLists.txt
    code/gazebo/trunk/server/rendering/OgreAdaptor.cc
    code/gazebo/trunk/server/sensors/camera/StereoCameraSensor.cc
    code/gazebo/trunk/worlds/CMakeLists.txt

Modified: code/gazebo/trunk/CMakeLists.txt
===================================================================
--- code/gazebo/trunk/CMakeLists.txt    2010-01-13 01:41:06 UTC (rev 8496)
+++ code/gazebo/trunk/CMakeLists.txt    2010-01-13 04:40:58 UTC (rev 8497)
@@ -96,7 +96,7 @@
   message (STATUS "Cmake C Flags:${CMAKE_C_FLAGS}")
   
   IF (BUILD_GAZEBO)
-    ADD_SUBDIRECTORY(3rd_party)
+    #ADD_SUBDIRECTORY(3rd_party)
     ADD_SUBDIRECTORY(libgazebo)
     ADD_SUBDIRECTORY(server)
     ADD_SUBDIRECTORY(worlds)

Modified: code/gazebo/trunk/cmake/SearchForStuff.cmake
===================================================================
--- code/gazebo/trunk/cmake/SearchForStuff.cmake        2010-01-13 01:41:06 UTC 
(rev 8496)
+++ code/gazebo/trunk/cmake/SearchForStuff.cmake        2010-01-13 04:40:58 UTC 
(rev 8497)
@@ -15,6 +15,10 @@
 SET (INCLUDE_WEBGAZEBO ON CACHE BOOL "Build webgazebo" FORCE)
 SET (OGRE_LIBRARY_PATH "/usr/local/lib" CACHE INTERNAL "Ogre library path")
 
+SET (assimp_include_dirs "" CACHE STRING "Assimp include paths. Use this to 
override automatic detection.")
+SET (assimp_library_dirs "" CACHE STRING "Assimp library paths. Use this to 
override automatic detection.")
+SET (assimp_libraries "" CACHE STRING "Assimp libraries Use this to override 
automatic detection.")
+
 SET (boost_include_dirs "" CACHE STRING "Boost include paths. Use this to 
override automatic detection.")
 SET (boost_library_dirs "" CACHE STRING "Boost library paths. Use this to 
override automatic detection.")
 SET (boost_libraries "" CACHE STRING "Boost libraries. Use this to override 
automatic detection.")
@@ -338,6 +342,37 @@
 ENDIF (libdl_library AND libdl_include_dir)
 
 ########################################
+# Find assimp
+IF (NOT assimp_include_dirs AND NOT assimp_library_dirs AND NOT 
assimp_libraries )
+
+  FIND_PATH(assimp_include_dir assimp.h ${assimp_include_dirs} ENV CPATH)
+  
+  IF (NOT assimp_include_dir)
+    BUILD_ERROR("assimp not found. See the following website for installation 
instructions: http://assimp.sourceforge.net";)
+    MESSAGE (STATUS "Looking for assimp.h - not found")
+    SET (assimp_include_dirs /usr/include CACHE STRING
+      "Assimp include paths. Use this to override automatic detection.")
+  ELSE (NOT assimp_include_dir)
+    MESSAGE (STATUS "Looking for assimp.h - found")
+    set (assim_include_dirs ${assimp_include_dir} CACHE STRING
+      "Assimp include paths. Use this to override automatic detection.")
+  ENDIF (NOT assimp_include_dir)
+  
+  FIND_LIBRARY(assimp_library assimp ENV LD_LIBRARY_PATH)
+  
+  IF (NOT assimp_library)
+    MESSAGE (STATUS "Looking for libassimp - not found")
+    BUILD_ERROR("libassimp not found. See the following website for 
installation instructions: http://assimp.sourceforge.net";)
+  ELSE (NOT assimp_library)
+    MESSAGE (STATUS "Looking for libassimp - found")
+    APPEND_TO_CACHED_LIST(assimp_libraries
+                          "Assimp libraries Use this to override automatic 
detection."
+                          ${assimp_library})
+  ENDIF (NOT assimp_library)
+  
+ENDIF (NOT assimp_include_dirs AND NOT assimp_library_dirs AND NOT 
assimp_libraries )
+
+########################################
 # Find bullet
 FIND_PATH( bullet_include_dir btBulletDynamicsCommon.h ${bullet_include_dirs} 
ENV CPATH)
 IF (NOT bullet_include_dir)

Modified: code/gazebo/trunk/server/AssimpLoader.hh
===================================================================
--- code/gazebo/trunk/server/AssimpLoader.hh    2010-01-13 01:41:06 UTC (rev 
8496)
+++ code/gazebo/trunk/server/AssimpLoader.hh    2010-01-13 04:40:58 UTC (rev 
8497)
@@ -3,9 +3,9 @@
 
 #include <string>
 
-#include <assimp/assimp.hpp>
-#include <assimp/aiScene.h>
-#include <assimp/aiPostProcess.h>
+#include <assimp.hpp>
+#include <aiScene.h>
+#include <aiPostProcess.h>
 
 #include "MeshLoader.hh"
 

Modified: code/gazebo/trunk/server/CMakeLists.txt
===================================================================
--- code/gazebo/trunk/server/CMakeLists.txt     2010-01-13 01:41:06 UTC (rev 
8496)
+++ code/gazebo/trunk/server/CMakeLists.txt     2010-01-13 04:40:58 UTC (rev 
8497)
@@ -20,12 +20,13 @@
   sensors/imu
   sensors/ir
   sensors/ray
-  ${CMAKE_SOURCE_DIR}/3rd_party/assimp/include
+  #${CMAKE_SOURCE_DIR}/3rd_party/assimp/include
   ${LIBAVCODEC_PATH}
   ${LIBAVFORMAT_PATH}
   ${libtool_include_path}
   ${gazeboserver_include_dirs}
   ${boost_include_dirs}
+  ${assimp_include_dirs}
   ${freeimage_include_dir}
   ${bullet_include_dir}
   ${threadpool_include_dirs_split}
@@ -33,11 +34,12 @@
 )
 
 LINK_DIRECTORIES(  
- ${CMAKE_BINARY_DIR}/3rd_party/assimp 
+  #${CMAKE_BINARY_DIR}/3rd_party/assimp 
  ${CMAKE_BINARY_DIR}/libgazebo 
  ${CMAKE_BINARY_DIR}/server/gui 
  ${CMAKE_BINARY_DIR}/server/physics/bullet 
  ${boost_library_dirs} 
+ ${assimp_library_dirs} 
  ${bullet_dynamics_dirs} 
  ${bullet_collision_dirs} 
  ${bullet_softbody_dirs} 
@@ -143,6 +145,7 @@
                                    BulletDynamics
                                    ${gazeboserver_link_libs} 
                                    ${boost_libraries} 
+                                   ${assimp_libraries} 
                                    gazebo_server
                                    BulletDynamics
                                    ${freeimage_library} 

Modified: code/gazebo/trunk/server/gui/CMakeLists.txt
===================================================================
--- code/gazebo/trunk/server/gui/CMakeLists.txt 2010-01-13 01:41:06 UTC (rev 
8496)
+++ code/gazebo/trunk/server/gui/CMakeLists.txt 2010-01-13 04:40:58 UTC (rev 
8497)
@@ -43,7 +43,7 @@
 
 #target_link_libraries(gazebo_gui ${FLTK_LIBRARIES} BulletDynamics 
BulletCollision LinearMath)
 
-target_link_libraries(gazebo_gui ${FLTK_LIBRARIES})
+target_link_libraries(gazebo_gui ${FLTK_LIBRARIES} Xpm)
 
 set_target_properties(gazebo_gui PROPERTIES OUTPUT_NAME "gazebo_gui" VERSION 
${GAZEBO_VERSION})
 

Modified: code/gazebo/trunk/server/rendering/CMakeLists.txt
===================================================================
--- code/gazebo/trunk/server/rendering/CMakeLists.txt   2010-01-13 01:41:06 UTC 
(rev 8496)
+++ code/gazebo/trunk/server/rendering/CMakeLists.txt   2010-01-13 04:40:58 UTC 
(rev 8497)
@@ -42,6 +42,6 @@
 )
 
 add_library(gazebo_rendering SHARED ${sources})
-target_link_libraries( gazebo_rendering ${OGRE_LIBRARIES})
+target_link_libraries( gazebo_rendering ${OGRE_LIBRARIES} X11)
 install ( TARGETS gazebo_rendering DESTINATION ${CMAKE_INSTALL_PREFIX}/lib )
 APPEND_TO_SERVER_HEADERS(${headers})

Modified: code/gazebo/trunk/server/rendering/OgreAdaptor.cc
===================================================================
--- code/gazebo/trunk/server/rendering/OgreAdaptor.cc   2010-01-13 01:41:06 UTC 
(rev 8496)
+++ code/gazebo/trunk/server/rendering/OgreAdaptor.cc   2010-01-13 04:40:58 UTC 
(rev 8497)
@@ -408,17 +408,17 @@
   Ogre::RenderSystem *renderSys;
 
   // Set parameters of render system (window size, etc.)
-  Ogre::RenderSystemList rsList = this->root->getAvailableRenderers();
+  Ogre::RenderSystemList *rsList = this->root->getAvailableRenderers();
   int c = 0;
 
   renderSys = NULL;
 
   do
   {
-    if (c == (int)rsList.size())
+    if (c == (int)rsList->size())
       break;
 
-    renderSys = rsList.at(c);
+    renderSys = rsList->at(c);
     c++;
   }
   while (renderSys->getName().compare("OpenGL Rendering Subsystem")!= 0);

Modified: code/gazebo/trunk/server/sensors/camera/StereoCameraSensor.cc
===================================================================
--- code/gazebo/trunk/server/sensors/camera/StereoCameraSensor.cc       
2010-01-13 01:41:06 UTC (rev 8496)
+++ code/gazebo/trunk/server/sensors/camera/StereoCameraSensor.cc       
2010-01-13 04:40:58 UTC (rev 8497)
@@ -259,7 +259,7 @@
     autoParamDataSource.setCurrentRenderTarget(this->renderTargets[i]);
     autoParamDataSource.setCurrentSceneManager(sceneMgr);
     autoParamDataSource.setCurrentCamera(this->GetOgreCamera(), true);
-    pass->_updateAutoParams(&autoParamDataSource,1);
+    pass->_updateAutoParamsNoLights(&autoParamDataSource);
     
     renderSys->setLightingEnabled(false);
     renderSys->_setFog(Ogre::FOG_NONE);
@@ -273,14 +273,14 @@
     {
       renderSys->bindGpuProgram( 
pass->getVertexProgram()->_getBindingDelegate() );
       renderSys->bindGpuProgramParameters(Ogre::GPT_VERTEX_PROGRAM,
-          pass->getVertexProgramParameters(),1);
+          pass->getVertexProgramParameters());
     }
 
     if (pass->hasFragmentProgram())
     {   
       renderSys->bindGpuProgram( 
pass->getFragmentProgram()->_getBindingDelegate() );
       renderSys->bindGpuProgramParameters(Ogre::GPT_FRAGMENT_PROGRAM, 
-          pass->getFragmentProgramParameters(),1);
+          pass->getFragmentProgramParameters());
     }
    
     this->renderTargets[i]->update();

Modified: code/gazebo/trunk/worlds/CMakeLists.txt
===================================================================
--- code/gazebo/trunk/worlds/CMakeLists.txt     2010-01-13 01:41:06 UTC (rev 
8496)
+++ code/gazebo/trunk/worlds/CMakeLists.txt     2010-01-13 04:40:58 UTC (rev 
8497)
@@ -19,7 +19,6 @@
            simpleshapes.world
            stereocamera.world
            terrain.world
-           test.world
            trimesh.world
            wizbot.world
 )


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Playerstage-commit mailing list
Playerstage-commit@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/playerstage-commit

Reply via email to