uncalibrated_photometric_stereoT_uncalibrated_photometric_stereoUncalibratedPhotometricStereoUncalibratedPhotometricStereouncalibrated_photometric_stereo (算子)

名称

uncalibrated_photometric_stereoT_uncalibrated_photometric_stereoUncalibratedPhotometricStereoUncalibratedPhotometricStereouncalibrated_photometric_stereo — 从几个不同照明的图像重建表面。

签名

uncalibrated_photometric_stereo(Images : NormalField, Gradient, Albedo : ResultType : )

Herror T_uncalibrated_photometric_stereo(const Hobject Images, Hobject* NormalField, Hobject* Gradient, Hobject* Albedo, const Htuple ResultType)

void UncalibratedPhotometricStereo(const HObject& Images, HObject* NormalField, HObject* Gradient, HObject* Albedo, const HTuple& ResultType)

HImage HImage::UncalibratedPhotometricStereo(HImage* Gradient, HImage* Albedo, const HTuple& ResultType) const

static void HOperatorSet.UncalibratedPhotometricStereo(HObject images, out HObject normalField, out HObject gradient, out HObject albedo, HTuple resultType)

HImage HImage.UncalibratedPhotometricStereo(out HImage gradient, out HImage albedo, HTuple resultType)

def uncalibrated_photometric_stereo(images: HObject, result_type: Sequence[str]) -> Tuple[HObject, HObject, HObject]

描述

uncalibrated_photometric_stereouncalibrated_photometric_stereoUncalibratedPhotometricStereoUncalibratedPhotometricStereoUncalibratedPhotometricStereouncalibrated_photometric_stereo can be used to extract high-frequency surface details from a given object with no prior knowledge about the illumination, geometry and reflectance of the object. The geometry of interest can be for example dents, folds or scratches. The operator can usually not be used for measuring the overall shape of an object. The operator returns the normals NormalFieldNormalFieldNormalFieldNormalFieldnormalFieldnormal_field of the surface as a 3-channel image with each image encoding a component of the normal. This is used as a visualization of the result as a color coded image. Further, it returns the GradientGradientGradientGradientgradientgradient and the AlbedoAlbedoAlbedoAlbedoalbedoalbedo of the surface. Which result should be calculated can be controlled with ResultTypeResultTypeResultTypeResultTyperesultTyperesult_type. This operator is related to photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo, but does not require known (i.e. previously calibrated) light directions. Note that photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo is faster and more accurate, but needs the light direction information. For sensible results an orthographic projection of the camera is assumed for both the calibrated and uncalibrated case. This is typically reached by using a telecentric lens or at least a lens with a long focal distance.

The operator requires at least three images of the same object, taken with a static, non-moving camera and different lighting directions for each image. For best results, the object should exhibit Lambertian reflection properties, no inter-reflection or shadow castings.

执行信息

参数

ImagesImagesImagesImagesimagesimages (输入对象)  singlechannelimage(-array) objectHImageHObjectHImageHobject (byte / uint2)

The input images with different illumination.

NormalFieldNormalFieldNormalFieldNormalFieldnormalFieldnormal_field (输出对象)  image(-array) objectHImageHObjectHImageHobject * (real)

The normal field of the surface.

GradientGradientGradientGradientgradientgradient (输出对象)  image objectHImageHObjectHImageHobject * (vector_field)

The gradient field of the surface .

AlbedoAlbedoAlbedoAlbedoalbedoalbedo (输出对象)  image objectHImageHObjectHImageHobject * (real)

The albedo of the surface.

ResultTypeResultTypeResultTypeResultTyperesultTyperesult_type (输入控制)  string-array HTupleSequence[str]HTupleHtuple (string) (string) (HString) (char*)

The result type.

默认值: 'all' "all" "all" "all" "all" "all"

值列表: [], 'albedo'"albedo""albedo""albedo""albedo""albedo", 'all'"all""all""all""all""all", 'gradient'"gradient""gradient""gradient""gradient""gradient", 'normal_field'"normal_field""normal_field""normal_field""normal_field""normal_field", 'normalized_gradient'"normalized_gradient""normalized_gradient""normalized_gradient""normalized_gradient""normalized_gradient"

示例(HDevelop)

* read severally illuminated images
FName := 'photometric_stereo/pharma_braille_0' + [1:4] + '.png'
read_image(Images, FName)
* extract surface normals, gradients and albedo from images
uncalibrated_photometric_stereo(Images, NormalField, Gradient, Albedo, 'all')
derivate_vector_field (Gradient, Result, 0.1, 'mean_curvature')
reconstruct_height_field_from_gradient (Gradient, HeightField, 'poisson', \
                                        [], [])

结果

算子 uncalibrated_photometric_stereouncalibrated_photometric_stereoUncalibratedPhotometricStereoUncalibratedPhotometricStereoUncalibratedPhotometricStereouncalibrated_photometric_stereo returns the NormalFieldNormalFieldNormalFieldNormalFieldnormalFieldnormal_field for the given images as well as the appropriate gradients for each pixel and the AlbedoAlbedoAlbedoAlbedoalbedoalbedo of the object.

替代

photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo

另见

photometric_stereophotometric_stereoPhotometricStereoPhotometricStereoPhotometricStereophotometric_stereo

参考文献

H. Hayakawa: “Photometric stereo under a light source with arbitrary motion”. Journal Optical Society America, Vol. 11, No. 11/November 1994.

模块

三维计量