cleaned up and fixed cubemarcher.cpp