52#include <vigra/stdimage.hxx>
53#include <vigra/imageinfo.hxx>
54#include <vigra/impex.hxx>
58typedef vigra::RGBValue < unsigned char , 0 , 1 , 2 >
pixel_type ;
87 template <
class IN ,
class OUT >
88 void eval (
const IN & c , OUT & result )
const
141 template <
class IN ,
class OUT >
142 void eval (
const IN & c , OUT & result )
const
144 result[0] = c[0] / 192.0f ;
145 result[1] = 10.0f - result[0] ;
146 result[2] = c[1] / 108.0f ;
150int main (
int argc ,
char * argv[] )
162 colour_space ( vigra::Shape3 ( 10 , 10 , 10 ) , 5 , bcv ) ;
197 target_type target ( vigra::Shape2 ( 1920 , 1080 ) ) ;
210 vigra::ImageExportInfo imageInfo (
"slice.tif" );
212 vigra::exportImage ( target ,
214 .setPixelType(
"UINT8")
215 .setCompression(
"100")
216 .setForcedRangeMapping ( 0 , 255 , 0 , 255 ) ) ;
218 std::cout <<
"result was written to slice.tif" << std::endl ;
vigra::MultiArray< 2, pixel_type > target_type
class evaluator encodes evaluation of a spline-like object. This is a generalization of b-spline eval...
void transform(const unary_functor_type &functor, const vigra::MultiArrayView< dimension, typename unary_functor_type::in_type > &input, vigra::MultiArrayView< dimension, typename unary_functor_type::out_type > &output, int njobs=vspline::default_njobs, vspline::atomic< bool > *p_cancel=0)
implementation of two-array transform using wielding::coupled_wield.
vspline::chain_type< T1, T2 > chain(const T1 &t1, const T2 &t2)
chain is a factory function yielding the result of chaining two unary_functors.
int main(int argc, char *argv[])
vigra::RGBValue< unsigned char, 0, 1, 2 > pixel_type
vspline::evaluator< coordinate3_type, pixel_type, VSIZE, -1, double, voxel_type > ev_type
vigra::TinyVector< double, 3 > voxel_type
vigra::TinyVector< float, 3 > coordinate3_type
vigra::TinyVector< float, 2 > coordinate2_type
vigra::MultiArray< 2, pixel_type > target_type
void eval(const IN &c, OUT &result) const
void eval(const IN &c, OUT &result) const
class bspline now builds on class bspline_base, adding coefficient storage, while bspline_base provid...
void prefilter(vspline::xlf_type boost=vspline::xlf_type(1), int njobs=vspline::default_njobs)
prefilter converts the knot point data in the 'core' area into b-spline coefficients....
class unary_functor provides a functor object which offers a system of types for concrete unary funct...
includes all headers from vspline (most of them indirectly)