cartodata
5.0.5
|
Volume utilities classes. More...
#include <cartodata/volume/volumeutil.h>
Static Public Member Functions | |
template<class UnaryFunction > | |
static VolumeRef< T > | apply (UnaryFunction f, const VolumeRef< T > &o) |
applies a unary function to each voxel of a volume More... | |
template<class BinaryFunction > | |
static VolumeRef< T > | apply (BinaryFunction f, const VolumeRef< T > &o1, const VolumeRef< T > &o2) |
applies a binary function to each voxel of a pair of volumes More... | |
template<class UnaryFunction > | |
static void | selfApply (UnaryFunction f, VolumeRef< T > &o) |
same as apply() except that the input volume is used to store the result More... | |
template<class BinaryFunction > | |
static void | selfApply (BinaryFunction f, VolumeRef< T > &o1, const VolumeRef< T > &o2) |
same as apply() except that the first input volume is used to store the result More... | |
template<class BinaryFunction > | |
static T | accumulate (BinaryFunction f, const VolumeRef< T > &o2, T initial) |
Apply a binary function to each voxel of the volume, with a "current" value as second argument. More... | |
template<class BinaryFunction > | |
static T | accumulate (BinaryFunction f, const Volume< T > &o2, T initial) |
Volume utilities classes.
Definition at line 1242 of file volumeutil.h.
|
inlinestatic |
Apply a binary function to each voxel of the volume, with a "current" value as second argument.
The voxel result is used for other voxels function calls. Useful for min/max for instance: min = VolumeUtil<T>::accumulate( std::min<T>, volume, std::numeric_limits<T>::max() ); max = VolumeUtil::accumulate( std::max<T>, volume, -stdnumeric_limits<T>::max() ); May be used also for sum etc.
Definition at line 1272 of file volumeutil.h.
References carto::volumeutil::accumulate().
Referenced by carto::VolumeUtilBase< T, true >::max(), and carto::VolumeUtilBase< T, true >::min().
|
static |
Definition at line 327 of file volumeutil_d.h.
References carto::Volume< T >::at(), carto::VolumeProxy< T >::getSizeT(), carto::VolumeProxy< T >::getSizeX(), carto::VolumeProxy< T >::getSizeY(), and carto::VolumeProxy< T >::getSizeZ().
|
static |
applies a unary function to each voxel of a volume
Definition at line 73 of file volumeutil_d.h.
References carto::VolumeRef< T >::at(), carto::VolumeRef< T >::getSizeT(), carto::VolumeRef< T >::getSizeX(), carto::VolumeRef< T >::getSizeY(), carto::VolumeRef< T >::getSizeZ(), and carto::VolumeRef< T >::header().
Referenced by carto::VolumeUtilBase< T, true >::max().
|
static |
applies a binary function to each voxel of a pair of volumes
Definition at line 148 of file volumeutil_d.h.
References carto::VolumeRef< T >::at(), carto::VolumeRef< T >::getSizeT(), carto::VolumeRef< T >::getSizeX(), carto::VolumeRef< T >::getSizeY(), carto::VolumeRef< T >::getSizeZ(), and carto::VolumeRef< T >::header().
|
static |
same as apply() except that the input volume is used to store the result
Definition at line 281 of file volumeutil_d.h.
References carto::VolumeRef< T >::at(), carto::VolumeRef< T >::getSizeT(), carto::VolumeRef< T >::getSizeX(), carto::VolumeRef< T >::getSizeY(), and carto::VolumeRef< T >::getSizeZ().
Referenced by carto::VolumeUtilBase< T, true >::max().
|
static |
same as apply() except that the first input volume is used to store the result
Definition at line 298 of file volumeutil_d.h.
References carto::VolumeRef< T >::at(), carto::VolumeRef< T >::getSizeT(), carto::VolumeRef< T >::getSizeX(), carto::VolumeRef< T >::getSizeY(), and carto::VolumeRef< T >::getSizeZ().