The magnitude images are used; correlation is computed in the space or spectral domain.
At a number of positions (geometrically distributed or at positions read from an input file) in the image the correlation between master and slave is computed for different offsets. The offset with the highest correlation is the estimate for that position. The (approximate) offset between the two images is set to the offset that most occurred over the positions, so the one that is most likely. (Sometimes an estimated offset is totally unreliable, for example for a position in a sea, but the correlation is not very small. The estimated correlation at a position is likely to be biased. Therefor it would not be wise to use the offset between the two images based on the highest correlation values only, but we use this 'consistency test' instead.)