00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _SO_GRADIENT_IMAGE_FILTER_H_
00025 #define _SO_GRADIENT_IMAGE_FILTER_H_
00026 #include <ImageViz/SoImageViz.h>
00027 #include <ImageViz/Engines/SoSubImageVizEngine.h>
00028 #include <ImageViz/Engines/SoImageVizEngineOutput.h>
00029 #include <ImageViz/Engines/SoImageVizEngine.h>
00030
00031 #include <Inventor/fields/SoSFEnum.h>
00032 #include <Inventor/fields/SoSFFloat.h>
00033 #include <ImageViz/Fields/SoSFImageDataAdapter.h>
00034
00035
00130 class SoGradientOperatorProcessing2d : public SoImageVizEngine
00131 {
00132
00133 SO_IMAGEVIZ_ENGINE_HEADER(SoGradientOperatorProcessing2d);
00134
00135 public:
00137 SoGradientOperatorProcessing2d();
00138
00140 SoSFImageDataAdapter inImage;
00141
00145 enum GradientOperator{
00151 CANNY_DERICHE = 0,
00156 SHEN_CASTAN = 1,
00161 CANNY = 3,
00167 GAUSSIAN = 4,
00173 SOBEL = 5,
00179 PREWITT = 6
00180 };
00181
00185 SoSFEnum gradientOperator;
00186
00190 enum GradientMode{
00196 AMPLITUDE_MAX_OF_MAGS = 0,
00202 AMPLITUDE_EUCLIDEAN = 1,
00210 AMPLITUDE_AND_ORIENTATION = 2,
00217 X_AND_Y_GRADIENTS = 3
00218 };
00219
00223 SoSFEnum gradientMode;
00224
00226 SoSFFloat standardDeviation;
00227
00229 SoImageVizEngineOutput<SoSFImageDataAdapter,SoImageDataAdapter*> outGradientXImage;
00230
00232 SoImageVizEngineOutput<SoSFImageDataAdapter,SoImageDataAdapter*> outGradientYImage;
00233
00235 SoImageVizEngineOutput<SoSFImageDataAdapter,SoImageDataAdapter*> outAmplitudeImage;
00236
00238 SoImageVizEngineOutput<SoSFImageDataAdapter,SoImageDataAdapter*> outOrientationImage;
00239
00240
00241 private:
00243 virtual ~SoGradientOperatorProcessing2d();
00244
00245 };
00246
00247 #endif