ImFusion SDK 4.3
ClFastMarching Class Reference

#include <ImFusion/CL/ClFastMarching.h>

OpenCL Fast Marching implementation. More...

Detailed Description

OpenCL Fast Marching implementation.

Public Member Functions

 ClFastMarching (int mode=ClFastMarching2D, ClEnvironment *env=0)
 Creates an OpenCL based FastMarching solver for a specific dimension type.
 
void compute (float *phi, int w, int h, const std::vector< vec2 > &startPoints, float *F=0, int maxIter=5000, const vec2 &endPoint=vec2(-1, -1), float maxDist=std::numeric_limits< float >::infinity())
 2D Fast Marching Method for solving the Eikonal equation ||Grad(Phi)||*F = 1.
 
void compute (float *phi, int dim[3], const std::vector< vec3 > &startPoints, float *F=0, int maxIter=5000, const vec3 &endPoint=vec3(-1, -1, -1), float maxDist=std::numeric_limits< float >::infinity())
 3D Fast Marching Method for solving the Eikonal equation ||Grad(Phi)||*F = 1.
 

Static Public Member Functions

static const float ClMaxFloat ()
 Return maximum float used by OpenCL.
 

Constructor & Destructor Documentation

◆ ClFastMarching()

ClFastMarching ( int mode = ClFastMarching2D,
ClEnvironment * env = 0 )

Creates an OpenCL based FastMarching solver for a specific dimension type.

Parameters
modegives the dimension type: ClFastMarching2D (default) or ClFastMarching3D

Member Function Documentation

◆ compute() [1/2]

void compute ( float * phi,
int w,
int h,
const std::vector< vec2 > & startPoints,
float * F = 0,
int maxIter = 5000,
const vec2 & endPoint = vec2(-1, -1),
float maxDist = std::numeric_limits< float >::infinity() )

2D Fast Marching Method for solving the Eikonal equation ||Grad(Phi)||*F = 1.

For F = 1 this produces the distance map of the zero level set. See Osher et al. "Level Set Methods and Dynamic Implicit Surfaces" pp. 69 for details. (If you want to call this method, m_mode has to be set to CLFastMarching2D)

Parameters
philevel set function
wlevel set width
hlevel set height
startPointsvector of start points
Fvelocity, if set to zero a constant velocity of one is assumed
maxItermax iteration count
endPointNOT used yet!
maxDistNOT used yet!

◆ compute() [2/2]

void compute ( float * phi,
int dim[3],
const std::vector< vec3 > & startPoints,
float * F = 0,
int maxIter = 5000,
const vec3 & endPoint = vec3(-1, -1, -1),
float maxDist = std::numeric_limits< float >::infinity() )

3D Fast Marching Method for solving the Eikonal equation ||Grad(Phi)||*F = 1.

For F = 1 this produces the distance map of the zero level set. See Osher et al. "Level Set Methods and Dynamic Implicit Surfaces" pp. 69 for details. (If you want to call this method, m_mode has to be set to CLFastMarching3D)

Parameters
philevel set function
dimlevel set dimensions (dim[0] = width, dim[1] = height, dim[2] = depth)
startPointsvector of start points
Fvelocity, if set to zero a constant velocity of one is assumed
maxItermax iteration count
endPointNOT used yet!
maxDistNOT used yet!

The documentation for this class was generated from the following file:
Search Tab / S to search, Esc to close