eVision .NET API
Loading...
Searching...
No Matches
eVision.Easy3D.EPhotometricStereoImager Class Reference

Manages photometric stereo reconstruction. This class can build normals, albedos, gradients, mean curvatures and gaussian curvatures images from at least 3 input images by using photometric stereo The algorithm used assumes objects are Lambertian and light sources emit parallel rays. More...

Inheritance diagram for eVision.Easy3D.EPhotometricStereoImager:
Collaboration diagram for eVision.Easy3D.EPhotometricStereoImager:

Public Member Functions

 EPhotometricStereoImager ()
 Creates an EPhotometricStereoImager object.
 EPhotometricStereoImager (eVision.Easy3D.EPhotometricStereoImager other)
 Creates an EPhotometricStereoImager object.
void Load (string path)
 Loads the EPhotometricStereoImager. The given ESerializer must have been created for reading.
void Load (eVision.ESerializer serializer)
 Loads the EPhotometricStereoImager. The given ESerializer must have been created for reading.
void Save (string path)
 Saves the EPhotometricStereoImager. The given ESerializer must have been created for writing.
void Save (eVision.ESerializer serializer)
 Saves the EPhotometricStereoImager. The given ESerializer must have been created for writing.
float CalibrateFromSphere (eVision.EROIBW8[] sphereImages)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8[] sphereImages, eVision.EROIBW8 darkImage)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8[] sphereImages, eVision.ECircle circle)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8[] sphereImages, eVision.EROIBW8 darkImage, eVision.ECircle circle)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.EROIBW8 darkImage)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.ECircle circle)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
float CalibrateFromSphere (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.EROIBW8 darkImage, eVision.ECircle circle)
 Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.
bool IsCalibrated ()
 Returns whether the EPhotometricStereoImager is calibrated or not.
void GetCalibrationAngles (out float[] azimuths, out float[] elevations)
 Gets the calibration angles.
void SetCalibrationAngles (float[] azimuths, float[] elevations)
 Sets the calibration angles.
void ConfigureNonUniformLightingCorrection (eVision.EROIBW8[] flatImages)
 Configure the non uniform lighting correction of the scene by using flat images. Photometric stereo assumes the lights of each image to be of same direction and intensity. This is however rarely the case in practice, a way to attenuate the problem is to use flat images to correct non-uniform lighting before performing photometric stereo.
void ConfigureNonUniformLightingCorrection (eVision.EROIBW8[] flatImages, eVision.EROIBW8 darkImage)
 Configure the non uniform lighting correction of the scene by using flat images. Photometric stereo assumes the lights of each image to be of same direction and intensity. This is however rarely the case in practice, a way to attenuate the problem is to use flat images to correct non-uniform lighting before performing photometric stereo.
void Compute (eVision.EROIBW8[] objectImages)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8[] objectImages, eVision.ERegion region)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8[] objectImages, eVision.EROIBW8 darkImage)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8[] objectImages, eVision.EROIBW8 darkImage, eVision.ERegion region)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.ERegion region)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.EROIBW8 darkImage)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
void Compute (eVision.EROIBW8 image1, eVision.EROIBW8 image2, eVision.EROIBW8 image3, eVision.EROIBW8 image4, eVision.EROIBW8 darkImage, eVision.ERegion region)
 Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.
eVision.EImageBW8 GetAlbedos (eVision.Easy3D.EPhotometricStereoContrast contrast)
 Gets the albedos as an EImageBW8. Albedos are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 0.
eVision.EImageBW8 GetAlbedos (eVision.Easy3D.EPhotometricStereoContrast contrast, float maxValue)
 Gets the albedos as an EImageBW8. Albedos are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 0.
eVision.EImageBW8 ComputeGaussianCurvatures (eVision.Easy3D.EPhotometricStereoContrast contrast)
 Computes the gaussian curvatures as an EImageBW8. Gaussian curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.
eVision.EImageBW8 ComputeGaussianCurvatures (eVision.Easy3D.EPhotometricStereoContrast contrast, float maxAbsoluteValue)
 Computes the gaussian curvatures as an EImageBW8. Gaussian curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.
eVision.EImageBW8 ComputeMeanCurvatures (eVision.Easy3D.EPhotometricStereoContrast contrast)
 Computes the mean curvatures as an EImageBW8. Mean curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.
eVision.EImageBW8 ComputeMeanCurvatures (eVision.Easy3D.EPhotometricStereoContrast contrast, float maxAbsoluteValue)
 Computes the mean curvatures as an EImageBW8. Mean curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.
eVision.Easy3D.EZMap8 ComputeHeightMap ()
 Computes the height at each pixel as an EZMap8 by integrating the surface gradients.

Properties

float[] CalibrationAzimuthAngles [get]
 Gets the calibration azimuth angles.
float[] CalibrationElevationAngles [get]
 Gets the calibration elevation angles.
bool EnableNonUniformLightingCorrection [get, set]
 Gets/Sets whether the correction of the non uniformity of the lighting is corrected or not (disabled by default, enabled by calling EPhotometricStereoImager.ConfigureNonUniformLightingCorrection). Disabling it increases speed.
float GaussianBlurSigma [get, set]
 Gets/Sets the sigma parameter of the gaussian blurring applied before computing the curvatures. Default value is 1. Sigma must be > 0.
eVision.EImageC24 Normals [get]
 Gets the normals as an EImageC24.
eVision.EImageBW8 GradientsX [get]
 Gets the gradients on the X axis as an EImageBW8.
eVision.EImageBW8 GradientsY [get]
 Gets the gradients on the Y axis as an EImageBW8.

Detailed Description

Manages photometric stereo reconstruction. This class can build normals, albedos, gradients, mean curvatures and gaussian curvatures images from at least 3 input images by using photometric stereo The algorithm used assumes objects are Lambertian and light sources emit parallel rays.

License(s): Easy3D

Constructor & Destructor Documentation

◆ EPhotometricStereoImager() [1/2]

eVision.Easy3D.EPhotometricStereoImager.EPhotometricStereoImager ( )

Creates an EPhotometricStereoImager object.

◆ EPhotometricStereoImager() [2/2]

eVision.Easy3D.EPhotometricStereoImager.EPhotometricStereoImager ( eVision.Easy3D.EPhotometricStereoImager other)

Creates an EPhotometricStereoImager object.

Parameters
otherAnother EPhotometricStereoImager.

Member Function Documentation

◆ CalibrateFromSphere() [1/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4 )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
image1The first EROIBW8 of a sphere in a 4-image configuration.
image2The second EROIBW8 of a sphere in a 4-image configuration.
image3The third EROIBW8 of a sphere in a 4-image configuration.
image4The fourth EROIBW8 of a sphere in a 4-image configuration.

◆ CalibrateFromSphere() [2/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.ECircle circle )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
image1The first EROIBW8 of a sphere in a 4-image configuration.
image2The second EROIBW8 of a sphere in a 4-image configuration.
image3The third EROIBW8 of a sphere in a 4-image configuration.
image4The fourth EROIBW8 of a sphere in a 4-image configuration.
circleAn ECircle that represents the position of the sphere. Default: automatically computed.

◆ CalibrateFromSphere() [3/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.EROIBW8 darkImage )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
image1The first EROIBW8 of a sphere in a 4-image configuration.
image2The second EROIBW8 of a sphere in a 4-image configuration.
image3The third EROIBW8 of a sphere in a 4-image configuration.
image4The fourth EROIBW8 of a sphere in a 4-image configuration.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the calibration especially if the image is not dark when there is no illumination. Otherwise, it is not useful.

◆ CalibrateFromSphere() [4/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.EROIBW8 darkImage,
eVision.ECircle circle )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
image1The first EROIBW8 of a sphere in a 4-image configuration.
image2The second EROIBW8 of a sphere in a 4-image configuration.
image3The third EROIBW8 of a sphere in a 4-image configuration.
image4The fourth EROIBW8 of a sphere in a 4-image configuration.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the calibration especially if the image is not dark when there is no illumination. Otherwise, it is not useful.
circleAn ECircle that represents the position of the sphere. Default: automatically computed.

◆ CalibrateFromSphere() [5/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8[] sphereImages)

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
sphereImagesA vector of EROIBW8 of a sphere.

◆ CalibrateFromSphere() [6/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8[] sphereImages,
eVision.ECircle circle )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
sphereImagesA vector of EROIBW8 of a sphere.
circleAn ECircle that represents the position of the sphere. Default: automatically computed.

◆ CalibrateFromSphere() [7/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8[] sphereImages,
eVision.EROIBW8 darkImage )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
sphereImagesA vector of EROIBW8 of a sphere.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the calibration especially if the image is not dark when there is no illumination. Otherwise, it is not useful.

◆ CalibrateFromSphere() [8/8]

float eVision.Easy3D.EPhotometricStereoImager.CalibrateFromSphere ( eVision.EROIBW8[] sphereImages,
eVision.EROIBW8 darkImage,
eVision.ECircle circle )

Calibrates the light directions on several images (at least 3) of a sphere (or half sphere) and returns a score indicating the reliability of the calibration.

Parameters
sphereImagesA vector of EROIBW8 of a sphere.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the calibration especially if the image is not dark when there is no illumination. Otherwise, it is not useful.
circleAn ECircle that represents the position of the sphere. Default: automatically computed.

◆ Compute() [1/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4 )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
image1The first EROIBW8 of the object in a 4-image configuration.
image2The second EROIBW8 of the object in a 4-image configuration.
image3The third EROIBW8 of the object in a 4-image configuration.
image4The fourth EROIBW8 of the object in a 4-image configuration.

◆ Compute() [2/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.ERegion region )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
image1The first EROIBW8 of the object in a 4-image configuration.
image2The second EROIBW8 of the object in a 4-image configuration.
image3The third EROIBW8 of the object in a 4-image configuration.
image4The fourth EROIBW8 of the object in a 4-image configuration.
regionERegion within which the computation will be done.

◆ Compute() [3/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.EROIBW8 darkImage )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
image1The first EROIBW8 of the object in a 4-image configuration.
image2The second EROIBW8 of the object in a 4-image configuration.
image3The third EROIBW8 of the object in a 4-image configuration.
image4The fourth EROIBW8 of the object in a 4-image configuration.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the results especially if the image is not dark when there is no illumination. Otherwise, it is not useful.

◆ Compute() [4/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8 image1,
eVision.EROIBW8 image2,
eVision.EROIBW8 image3,
eVision.EROIBW8 image4,
eVision.EROIBW8 darkImage,
eVision.ERegion region )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
image1The first EROIBW8 of the object in a 4-image configuration.
image2The second EROIBW8 of the object in a 4-image configuration.
image3The third EROIBW8 of the object in a 4-image configuration.
image4The fourth EROIBW8 of the object in a 4-image configuration.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the results especially if the image is not dark when there is no illumination. Otherwise, it is not useful.
regionERegion within which the computation will be done.

◆ Compute() [5/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8[] objectImages)

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
objectImagesA vector of EROIBW8 of the object to reconstruct. The images must be in the same order as the calibration images/angles with respect to the light direction. If flat images are used, flat and object images must have the same size

◆ Compute() [6/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8[] objectImages,
eVision.ERegion region )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
objectImagesA vector of EROIBW8 of the object to reconstruct. The images must be in the same order as the calibration images/angles with respect to the light direction. If flat images are used, flat and object images must have the same size
regionERegion within which the computation will be done.

◆ Compute() [7/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8[] objectImages,
eVision.EROIBW8 darkImage )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
objectImagesA vector of EROIBW8 of the object to reconstruct. The images must be in the same order as the calibration images/angles with respect to the light direction. If flat images are used, flat and object images must have the same size
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the results especially if the image is not dark when there is no illumination. Otherwise, it is not useful.

◆ Compute() [8/8]

void eVision.Easy3D.EPhotometricStereoImager.Compute ( eVision.EROIBW8[] objectImages,
eVision.EROIBW8 darkImage,
eVision.ERegion region )

Compute the different photometric stereo images of an object. To retrieve them, see EPhotometricStereoImager.Normals, EPhotometricStereoImager.GetAlbedos, EPhotometricStereoImager.GradientsX, EPhotometricStereoImager.GradientsY, EPhotometricStereoImager.ComputeGaussianCurvatures and EPhotometricStereoImager.ComputeMeanCurvatures.

Parameters
objectImagesA vector of EROIBW8 of the object to reconstruct. The images must be in the same order as the calibration images/angles with respect to the light direction. If flat images are used, flat and object images must have the same size
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the results especially if the image is not dark when there is no illumination. Otherwise, it is not useful.
regionERegion within which the computation will be done.

◆ ComputeGaussianCurvatures() [1/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.ComputeGaussianCurvatures ( eVision.Easy3D.EPhotometricStereoContrast contrast)

Computes the gaussian curvatures as an EImageBW8. Gaussian curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.

Parameters
contrastan EPhotometricStereoContrast

Both gaussian and mean curvatures are computed in this method and are cached to avoid unnecessary computations.

◆ ComputeGaussianCurvatures() [2/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.ComputeGaussianCurvatures ( eVision.Easy3D.EPhotometricStereoContrast contrast,
float maxAbsoluteValue )

Computes the gaussian curvatures as an EImageBW8. Gaussian curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.

Parameters
contrastan EPhotometricStereoContrast
maxAbsoluteValuewhen contrast is EPhotometricStereoContrast_FixedRange, this parameter can be used to specify the maximal floating point value for the gaussian curvatures, otherwise it is ignored. All values outside of [-maxAbsoluteValue, +maxAbsoluteValue] are clipped. maxAbsoluteValue must be positive and defaults to 2.

Both gaussian and mean curvatures are computed in this method and are cached to avoid unnecessary computations.

◆ ComputeHeightMap()

eVision.Easy3D.EZMap8 eVision.Easy3D.EPhotometricStereoImager.ComputeHeightMap ( )

Computes the height at each pixel as an EZMap8 by integrating the surface gradients.

◆ ComputeMeanCurvatures() [1/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.ComputeMeanCurvatures ( eVision.Easy3D.EPhotometricStereoContrast contrast)

Computes the mean curvatures as an EImageBW8. Mean curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.

Parameters
contrastan EPhotometricStereoContrast

Both mean and gaussian curvatures are computed in this method and are cached to avoid unnecessary computations.

◆ ComputeMeanCurvatures() [2/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.ComputeMeanCurvatures ( eVision.Easy3D.EPhotometricStereoContrast contrast,
float maxAbsoluteValue )

Computes the mean curvatures as an EImageBW8. Mean curvatures are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 128. See EPhotometricStereoContrast for the different conversions.

Parameters
contrastan EPhotometricStereoContrast
maxAbsoluteValuewhen contrast is EPhotometricStereoContrast_FixedRange, this parameter can be used to specify the maximal floating point value for the mean curvatures, otherwise it is ignored. All values outside of [-maxAbsoluteValue, +maxAbsoluteValue] are clipped. maxAbsoluteValue must be positive and defaults to 3.

Both mean and gaussian curvatures are computed in this method and are cached to avoid unnecessary computations.

◆ ConfigureNonUniformLightingCorrection() [1/2]

void eVision.Easy3D.EPhotometricStereoImager.ConfigureNonUniformLightingCorrection ( eVision.EROIBW8[] flatImages)

Configure the non uniform lighting correction of the scene by using flat images. Photometric stereo assumes the lights of each image to be of same direction and intensity. This is however rarely the case in practice, a way to attenuate the problem is to use flat images to correct non-uniform lighting before performing photometric stereo.

Parameters
flatImagesA vector of EROIBW8 of the flat images. The images must be in the same order as the calibration images/angles with respect to the light direction.

◆ ConfigureNonUniformLightingCorrection() [2/2]

void eVision.Easy3D.EPhotometricStereoImager.ConfigureNonUniformLightingCorrection ( eVision.EROIBW8[] flatImages,
eVision.EROIBW8 darkImage )

Configure the non uniform lighting correction of the scene by using flat images. Photometric stereo assumes the lights of each image to be of same direction and intensity. This is however rarely the case in practice, a way to attenuate the problem is to use flat images to correct non-uniform lighting before performing photometric stereo.

Parameters
flatImagesA vector of EROIBW8 of the flat images. The images must be in the same order as the calibration images/angles with respect to the light direction.
darkImageAn image of the object when there is no specific illumination. This argument can help to improve the results especially if the image is not dark when there is no illumination. Otherwise, it is not useful.

◆ GetAlbedos() [1/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.GetAlbedos ( eVision.Easy3D.EPhotometricStereoContrast contrast)

Gets the albedos as an EImageBW8. Albedos are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 0.

Parameters
contrastan EPhotometricStereoContrast

Albedos are computed in EPhotometricStereoImager.Compute.

◆ GetAlbedos() [2/2]

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.GetAlbedos ( eVision.Easy3D.EPhotometricStereoContrast contrast,
float maxValue )

Gets the albedos as an EImageBW8. Albedos are inherently floating point images so a conversion must be specified. In all cases, a floating point value of 0 translates to an EBW8 value of 0.

Parameters
contrastan EPhotometricStereoContrast
maxValuewhen contrast is EPhotometricStereoContrast_FixedRange, this parameter can be used to specify the maximal floating point value for the albedos, otherwise it is ignored. All values bigger than the parameter are clipped. maxValue must be positive and defaults to 200.

Albedos are computed in EPhotometricStereoImager.Compute.

◆ GetCalibrationAngles()

void eVision.Easy3D.EPhotometricStereoImager.GetCalibrationAngles ( out float[] azimuths,
out float[] elevations )

Gets the calibration angles.

Parameters
azimuthsThe vector of azimuth angles to retrieve
elevationsThe vector of elevation angles to retrieve

When facing the image, the axis x points right, y points top and z points towards the camera. Azimuth angles are oriented trigonometrically around the z axis. A light source on the right of the image would have an azimuth of 0 degrees. One on top would have an azimuth of 90 degrees. Elevation is the angle formed by the base plane and the light source. A light source on the horizon would have an elevation of 0 degrees. One on the camera would have an elevation of 90 degrees.

◆ IsCalibrated()

bool eVision.Easy3D.EPhotometricStereoImager.IsCalibrated ( )

Returns whether the EPhotometricStereoImager is calibrated or not.

◆ Load() [1/2]

void eVision.Easy3D.EPhotometricStereoImager.Load ( eVision.ESerializer serializer)

Loads the EPhotometricStereoImager. The given ESerializer must have been created for reading.

Parameters
serializerThe serializer.

Neither photometric stereo results nor intermediary computations are serialized. Thus, results of a call to EPhotometricStereoImager.Compute performed before serialization cannot be retrieved after serialization. On the other hand, the results of the calibration and the NonUniformLightingCorrection are serialized and can be used again.

◆ Load() [2/2]

void eVision.Easy3D.EPhotometricStereoImager.Load ( string path)

Loads the EPhotometricStereoImager. The given ESerializer must have been created for reading.

Parameters
pathThe file path.

Neither photometric stereo results nor intermediary computations are serialized. Thus, results of a call to EPhotometricStereoImager.Compute performed before serialization cannot be retrieved after serialization. On the other hand, the results of the calibration and the NonUniformLightingCorrection are serialized and can be used again.

◆ Save() [1/2]

void eVision.Easy3D.EPhotometricStereoImager.Save ( eVision.ESerializer serializer)

Saves the EPhotometricStereoImager. The given ESerializer must have been created for writing.

Parameters
serializerThe ESerializer object that is written to.

Neither photometric stereo results nor intermediary computations are serialized. Thus, results of a call to EPhotometricStereoImager.Compute performed before serialization cannot be retrieved after serialization. On the other hand, the results of the calibration and the NonUniformLightingCorrection are serialized and can be used again.

◆ Save() [2/2]

void eVision.Easy3D.EPhotometricStereoImager.Save ( string path)

Saves the EPhotometricStereoImager. The given ESerializer must have been created for writing.

Parameters
pathThe file path.

Neither photometric stereo results nor intermediary computations are serialized. Thus, results of a call to EPhotometricStereoImager.Compute performed before serialization cannot be retrieved after serialization. On the other hand, the results of the calibration and the NonUniformLightingCorrection are serialized and can be used again.

◆ SetCalibrationAngles()

void eVision.Easy3D.EPhotometricStereoImager.SetCalibrationAngles ( float[] azimuths,
float[] elevations )

Sets the calibration angles.

Parameters
azimuthsThe vector of azimuth angles to set
elevationsThe vector of elevation angles to set

When facing the image, the axis x points right, y points top and z points towards the camera. Azimuth angles are oriented trigonometrically around the z axis. A light source on the right of the image would have an azimuth of 0 degrees. One on top would have an azimuth of 90 degrees. Elevation is the angle formed by the base plane and the light source. A light source on the horizon would have an elevation of 0 degrees. One on the camera would have an elevation of 90 degrees.

Property Documentation

◆ CalibrationAzimuthAngles

float [] eVision.Easy3D.EPhotometricStereoImager.CalibrationAzimuthAngles
get

Gets the calibration azimuth angles.

When facing the image, the axis x points right, y points top and z points towards the camera. Azimuth angles are oriented trigonometrically around the z axis. A light source on the right of the image would have an azimuth of 0 degrees. One on top would have an azimuth of 90 degrees.

◆ CalibrationElevationAngles

float [] eVision.Easy3D.EPhotometricStereoImager.CalibrationElevationAngles
get

Gets the calibration elevation angles.

When facing the image, the axis x points right, y points top and z points towards the camera. Elevation is the angle formed by the base plane and the light source. A light source on the horizon would have an elevation of 0 degrees. One on the camera would have an elevation of 90 degrees.

◆ EnableNonUniformLightingCorrection

bool eVision.Easy3D.EPhotometricStereoImager.EnableNonUniformLightingCorrection
getset

Gets/Sets whether the correction of the non uniformity of the lighting is corrected or not (disabled by default, enabled by calling EPhotometricStereoImager.ConfigureNonUniformLightingCorrection). Disabling it increases speed.

It must be configured (EPhotometricStereoImager.ConfigureNonUniformLightingCorrection) before being enabled.

◆ GaussianBlurSigma

float eVision.Easy3D.EPhotometricStereoImager.GaussianBlurSigma
getset

Gets/Sets the sigma parameter of the gaussian blurring applied before computing the curvatures. Default value is 1. Sigma must be > 0.

The bigger the sigma, the longer processing will take.

◆ GradientsX

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.GradientsX
get

Gets the gradients on the X axis as an EImageBW8.

Gradients on the X axis are computed in EPhotometricStereoImager.Compute.

◆ GradientsY

eVision.EImageBW8 eVision.Easy3D.EPhotometricStereoImager.GradientsY
get

Gets the gradients on the Y axis as an EImageBW8.

Gradients on the Y axis are computed in EPhotometricStereoImager.Compute.

◆ Normals

eVision.EImageC24 eVision.Easy3D.EPhotometricStereoImager.Normals
get

Gets the normals as an EImageC24.

Normals are computed in EPhotometricStereoImager.Compute.