13#ifndef ML_IDENTICAL_INTENSITIES_CLUSTER_ALGORITHM_H
14#define ML_IDENTICAL_INTENSITIES_CLUSTER_ALGORITHM_H
29template <
typename DATATYPE>
40 return *
static_cast<DATATYPE*
>(position);
45 return static_cast<MLdouble>(getVoxel(position));
Type specific implementations of the interface class for clustering algorithms.
Structure computes and holds all cluster information. For internal use.
Implementation of a clustering algorithm checking for identical image intensity values.
static ML_FORCE_INLINE DATATYPE getVoxel(void *position)
Get the typed voxel value for current position.
ML_FORCE_INLINE bool isInTolerance(DATATYPE neighborValue, DATATYPE currentValue)
Tolerance calculation for scalar images.
IdenticalIntensitiesClusterAlgorithm(const ComputeClusterParameters ¶meters, Clusters *clusters)
static ML_FORCE_INLINE MLdouble getVoxelAsDouble(void *position)
#define ML_FORCE_INLINE
Forcing the use of 'inline' for methods.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
Structure to hold parameters for cluster computation.