A GPU implementation of the Marching Cubes algorithm for extracting surfaces from volumes using OpenCL and OpenGL
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
OpenCLUtilities @ a160e7b Added the openCLUtilities submodule Jun 27, 2012
.gitmodules changed OpenCLUtilities url in .gitmodules so people who clone the pr… Jul 5, 2012
CMakeLists.txt added cmake files for compiling the project Jun 27, 2012
FindGLEW.cmake added cmake files for compiling the project Jun 27, 2012
LICENSE updated license Nov 13, 2012
README.md
gpu-mc-morton.cl use define in compile instead of string replacement of HP size Sep 11, 2014
gpu-mc.cl use define in compile instead of string replacement of HP size Sep 11, 2014
gpu-mc.cpp added the round function that is missing on windows Sep 11, 2014
gpu-mc.hpp Added the openCLUtilities submodule Jun 27, 2012
main.cpp Added the openCLUtilities submodule Jun 27, 2012
rawUtilities.cpp fixed memory leak Feb 14, 2012
rawUtilities.hpp Added parsing of input arguments and moved reading of raw to a seperate Aug 10, 2011

README.md

About

A GPU implementation of the Marching Cubes algorithm for extracting surfaces from volumes using OpenCL and OpenGL. See http://www.eriksmistad.no/marching-cubes-implementation-using-opencl-and-opengl/ for detailed information about this implementation.

Note that this software has been moved into the FAST framework where it is further developed and maintained.

Dependencies

OpenGL, GLUT, GLU, GLEW and OpenCL (with C++ bindings)

Notes about implementation

  • Example 3D RAW files can be downloaded from www.volvis.org
  • Currently only supports 8 bit raw files, but should be easily extended to other types
  • Due to the lack of 3D texture write support on NVIDIA GPUs a slower version is used on NVIDIA GPUs. This version uses regular buffers and morton codes to emulate 3D caching. (not optimal, but at least it works)
  • See LICENCE file for license information
  • If you clone the project, remember to run git submodule init and git submodule update to fetch the contents of the OpenCLUtilities submodule

Compiling

Use the attached CMakeLists.txt to compile the program: cmake CMakeLists.txt

Usage

Run the program with the following arguments:

filename.raw sizeX sizeY sizeZ [stepSizeX stepSizeY stepSizeZ] [spacingX spacingY spacingZ]