From db00cb1613d80114841e2562d36a501a7bd69db7 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 11 Feb 2009 09:16:58 +0000 Subject: [PATCH] From Roland Smeenk, "Attached are two small fixes: -I changed the SET of COLLADA_BOOST_INCLUDE_DIR to use findpath, so users may override this setting if they choose not to build against to precompiled boost libraries delivered with the Collada DOM. -Changed daeRMaterials.cpp to prevent a compiler warning about a potentially uninitialized variable." --- CMakeModules/FindCOLLADA.cmake | 4 +++- src/osgPlugins/dae/daeRMaterials.cpp | 6 ++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/CMakeModules/FindCOLLADA.cmake b/CMakeModules/FindCOLLADA.cmake index b2a35cb0d..3b3eea4f4 100644 --- a/CMakeModules/FindCOLLADA.cmake +++ b/CMakeModules/FindCOLLADA.cmake @@ -260,7 +260,9 @@ IF(COLLADA_DYNAMIC_LIBRARY OR COLLADA_STATIC_LIBRARY) ${COLLADA_DOM_ROOT}/external-libs/boost/lib/mingw ) - SET(COLLADA_BOOST_INCLUDE_DIR ${COLLADA_DOM_ROOT}/external-libs/boost) + FIND_PATH(COLLADA_BOOST_INCLUDE_DIR boost/filesystem/convenience.hpp + ${COLLADA_DOM_ROOT}/external-libs/boost + ) ENDIF(WIN32) diff --git a/src/osgPlugins/dae/daeRMaterials.cpp b/src/osgPlugins/dae/daeRMaterials.cpp index ecdf2f1be..d1a1c3f07 100644 --- a/src/osgPlugins/dae/daeRMaterials.cpp +++ b/src/osgPlugins/dae/daeRMaterials.cpp @@ -1197,10 +1197,8 @@ void daeReader::processTransparencySettings( domCommon_transparent_type *ctt, } } - domFloat Transparency; - if (NULL == pTransparency) - Transparency = 1.0f; - else + domFloat Transparency = 1.0f; + if (NULL != pTransparency) { if (NULL != pTransparency->getFloat()) {