How does -fx handle negative values under Q16-HDRI?
Posted: 2008-04-20T14:42:42-07:00
I am testing Sean Burke's FFT routines now under IM 6.4.0-3 Q16-HDRI as we are finding that we can go only so far with examples without HDRI. Some things like deblurring seem to need HDRI and floating point accuracy. In particular the FFT can produce image pairs that are either the real and imaginary components or the magnitude and phase components. The real, imaginary and phase components will have negative values and also very small ranges of values. For example, the phase image will range from -pi to +pi (-3.14 to +3.13). In Q16-HDRI, if I understand correctly, the maximum value will be 65535. So 3 out of 65535 is very small and other values will be even smaller. Furthermore, we have negative values. I am trying to prototype some deblurring processes (remove motion blur or lens defocus) and need to do some complicated mathematical operations which include divides of the fft of the image by the fft of the filter. The real and imaginary and phase components of the FFT have negative values and I do not know what to expect from -fx. Can someone please clarify how -fx handles negatives in a Q16-hdri environment? Normally (non-HDRI) -fx treats the image as ranging from 0 to 1. In a Q16-HDRI environment will it treat the image as ranging from -1 to +1?
Similarly, if I am dividing two FFT components (e.g magnitude of image by magnitude of filter) and the denominator image is very small, the result may be larger than 1. What happens in this case?
Would either of these situations be mitigated by using Q32-hdri?
Thanks.
Fred
Similarly, if I am dividing two FFT components (e.g magnitude of image by magnitude of filter) and the denominator image is very small, the result may be larger than 1. What happens in this case?
Would either of these situations be mitigated by using Q32-hdri?
Thanks.
Fred