Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

complex image & mask

Hi,

When trying to apply "IMAQ Mask" to a FFT-transformed, complex image there seems to be an update problem with the image (display) methods. Although the pixel values in the image information panel show zero for the masked-out region, there is no visual change. Even for further computations with the masked complex image it seems that the changed/masked values are ignored.
I tried "manual masking" with standard arithmetics which gives the same results (values as expected but no visual change).
A code snippet is attached to show the problem: I expect that wiring the complex image to IMAQ Mask's input behaves equal to wiring the 8bit-image, or am I wrong with something conceptual here?

Thanks for your hints.
Marc
0 Kudos
Message 1 of 3
(3,875 Views)
Hi Marc, Complex images memory representation is flipped vs. what is displayed. IMAQ Vision displays low frequencies in the center of the window. But memory representation has high frequencies in the center of the image. Inserting a call to IMAQ ComplexFlipFrequency before AND after calling IMAQ Mask should solve your problem. Of course one can also compute the flipped mask, but that's more involved 😉

Hope this helps,
Nicolas
Message 2 of 3
(3,856 Views)
Hi Nicolas,

Great! Works fine and as expected now! I was not aware of the persistant internal "standard representation", but that explains everything.
Thanks a lot!

Marc
0 Kudos
Message 3 of 3
(3,842 Views)