Skip to content

Commit

Permalink
Merge pull request wdas#38 from marcusva/master
Browse files Browse the repository at this point in the history
- fix GLUT/OpenGL include paths for the tools
  • Loading branch information
aselle committed Jan 28, 2014
2 parents 504b22d + b230375 commit 6d8d2ec
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/lib/core/KdTree.h
Expand Up @@ -34,7 +34,11 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
*/
#ifndef KdTree_h
#define KdTree_h
#if defined(__clang__) && defined(_LIBCPP_VERSION)
#include <numeric>
#elif defined(__GNUC__)
#include <ext/numeric>
#endif

namespace Partio
{
Expand Down Expand Up @@ -286,7 +290,11 @@ void KdTree<k>::setPoints(const float* p, int n)

// assign sequential ids
_ids.resize(n);
#if defined(__clang__) && defined(_LIBCPP_VERSION)
std::iota(_ids.begin(), _ids.end(), 0);
#elif defined(__GNUC__)
__gnu_cxx::iota(_ids.begin(), _ids.end(), 0);
#endif
// _ids.reserve(n);
// while ((int)_ids.size() < n) _ids.push_back(_ids.size());
_sorted = 0;
Expand Down
1 change: 1 addition & 0 deletions src/tools/CMakeLists.txt
Expand Up @@ -36,6 +36,7 @@ include_directories(
)

IF(GLUT_FOUND AND OPENGL_FOUND)
INCLUDE_DIRECTORIES(${GLUT_INCLUDE_DIR} ${OPENGL_INCLUDE_DIR})
ADD_EXECUTABLE(partview partview.cpp)
target_link_libraries(partview ${PARTIO_LIBRARIES} ${GLUT_LIBRARY} ${OPENGL_LIBRARY})
install(TARGETS partview DESTINATION bin)
Expand Down

0 comments on commit 6d8d2ec

Please sign in to comment.