ClassesClasses | | Operators

phase_correlation_fftphase_correlation_fftPhaseCorrelationFftPhaseCorrelationFft (Operator)

Name

phase_correlation_fftphase_correlation_fftPhaseCorrelationFftPhaseCorrelationFft — Compute the phase correlation of two images in the frequency domain.

Signature

phase_correlation_fft(ImageFFT1, ImageFFT2 : ImagePhaseCorrelation : : )

Herror phase_correlation_fft(const Hobject ImageFFT1, const Hobject ImageFFT2, Hobject* ImagePhaseCorrelation)

Herror T_phase_correlation_fft(const Hobject ImageFFT1, const Hobject ImageFFT2, Hobject* ImagePhaseCorrelation)

void PhaseCorrelationFft(const HObject& ImageFFT1, const HObject& ImageFFT2, HObject* ImagePhaseCorrelation)

HImage HImage::PhaseCorrelationFft(const HImage& ImageFFT2) const

static void HOperatorSet.PhaseCorrelationFft(HObject imageFFT1, HObject imageFFT2, out HObject imagePhaseCorrelation)

HImage HImage.PhaseCorrelationFft(HImage imageFFT2)

Description

phase_correlation_fftphase_correlation_fftPhaseCorrelationFftPhaseCorrelationFftPhaseCorrelationFft calculates the phase correlation of the Fourier-transformed input images in the frequency domain. The phase correlation is calculated by multiplying ImageFFT1ImageFFT1ImageFFT1ImageFFT1imageFFT1 with the complex conjugate of ImageFFT2ImageFFT2ImageFFT2ImageFFT2imageFFT2 and dividing by the absolute value of this product. It should be noted that in order to achieve a correct scaling of the phase correlation in the spatial domain, the operators fft_genericfft_genericFftGenericFftGenericFftGeneric or rft_genericrft_genericRftGenericRftGenericRftGeneric with Norm = 'none'"none""none""none""none" must be used for the forward transform and fft_genericfft_genericFftGenericFftGenericFftGeneric or rft_genericrft_genericRftGenericRftGenericRftGeneric with Norm = 'n'"n""n""n""n" for the reverse transform. If ImageFFT1ImageFFT1ImageFFT1ImageFFT1imageFFT1 and ImageFFT2ImageFFT2ImageFFT2ImageFFT2imageFFT2 contain the same number of images, the corresponding images are phase-correlated pairwise. Otherwise, ImageFFT2ImageFFT2ImageFFT2ImageFFT2imageFFT2 must contain only one single image. In this case, the phase correlation is performed for each image of ImageFFT1ImageFFT1ImageFFT1ImageFFT1imageFFT1 with ImageFFT2ImageFFT2ImageFFT2ImageFFT2imageFFT2 .

Attention

The filtering is always performed on the entire image, i.e., the domain of the image is ignored.

Execution Information

Parameters

ImageFFT1ImageFFT1ImageFFT1ImageFFT1imageFFT1 (input_object)  (multichannel-)image(-array) objectHImageHImageHobject (complex)

Fourier-transformed input image 1.

ImageFFT2ImageFFT2ImageFFT2ImageFFT2imageFFT2 (input_object)  (multichannel-)image(-array) objectHImageHImageHobject (complex)

Fourier-transformed input image 2.

Number of elements: ImageFFT2 == ImageFFT1 || ImageFFT2 == 1

ImagePhaseCorrelationImagePhaseCorrelationImagePhaseCorrelationImagePhaseCorrelationimagePhaseCorrelation (output_object)  image(-array) objectHImageHImageHobject * (complex)

Phase correlation of the input images in the frequency domain.

Example (HDevelop)

* Compute the phase correlation of two images.
get_image_size(Image1,Width,Height)
rft_generic(Image1,ImageFFT1,'to_freq','none','complex',Width)
rft_generic(Image2,ImageFFT2,'to_freq','none','complex',Width)
phase_correlation_fft(ImageFFT1,ImageFFT2,PhaseCorrelationFFT)
rft_generic(PhaseCorrelationFFT,PhaseCorrelation,'from_freq','n', \
            'real',Width)
* Determine the translation between the two images.
local_max_sub_pix (PhaseCorrelation, 'facet', 1, 0.02, Row, Column)

Result

phase_correlation_fftphase_correlation_fftPhaseCorrelationFftPhaseCorrelationFftPhaseCorrelationFft returns 2 (H_MSG_TRUE) if all parameters are correct. If the input is empty the behavior can be set via set_system(::'no_object_result',<Result>:)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>). If necessary, an exception is raised.

Possible Predecessors

fft_genericfft_genericFftGenericFftGenericFftGeneric, fft_imagefft_imageFftImageFftImageFftImage, rft_genericrft_genericRftGenericRftGenericRftGeneric

Possible Successors

fft_genericfft_genericFftGenericFftGenericFftGeneric, fft_image_invfft_image_invFftImageInvFftImageInvFftImageInv, rft_genericrft_genericRftGenericRftGenericRftGeneric

Alternatives

correlation_fftcorrelation_fftCorrelationFftCorrelationFftCorrelationFft

References

C. D. Kuglin, D. C. Hines: “The Phase Correlation Image Alignment Method”; IEEE International Conference on Cybernetics and Society; pp. 163-165; 1975.

Module

Foundation


ClassesClasses | | Operators