01-22-2013 07:10 AM
Hi,
I want to apply an affine transformation on an image in LabVIEW with a known rotation-matrix.
Can somebody help me if there is a NI which can rotate and shift the image with the aid of my rotation-matrix.
Thanks for your help,
Lars
01-23-2013 08:01 AM
Hi Lars,
your post is a little bit to short to understand your problem. I think you want to use the Vision Development Module to rotate and shift a Vision-Image.
Could you provide me and the forum users a little bit more information?
How looks your rotation-matrix?
Do you want to use LabVIEW or the Visssion Assistant?
Which program parts are already available?
Regards, Stephan
01-24-2013 06:21 AM
It is a bit tricky to explain what I want to do but I hope I can wangle this.
In detail I´ve got two cameras which should record the same picture.
But in reality there is a little shift and a small rotation between these two pictures which I want to correct.
To do this I´ve got a Matlab-program that calculate the difference between the pictures in form of an affine 2x3 transformationmatrix.
This matrix got the information for the difference in the first four elements and the shift-information in the last two ones.
What I want to do in LabView now, is to use these matrix to rotate and shift the image in realtime.
So that I get a corrected Picture that is mostly identical to the other one.
Up to now I got a Labview program that reads out the camerasignal and display both images in realtime.
Regards,
Lars
01-28-2013 02:45 AM
Hi Lars,
thank you for the addional information. I think that I now know what you want to realize.
I think you can choose between two different ways to implement this function in Vision.
The first possibility is to use the IMAQ Rotate VI and the IMAQ Resample VI. If you want to use this VIs, you have to modify your 2x3 transformation matrix for this VIs. Can can found additional information for this two VIs here:
Scale an IMAQ Image - http://zone.ni.com/devzone/cda/epd/p/id/2270
IMAQ Rotate VI http://zone.ni.com/reference/en-XX/help/370281P-01/imaqvision/imaq_rotate/
The other possibility is that you convert your image to a 2D-Array and apply the transfomation whit the LabVIEW math functions. To transform th image to a 2D-Array, use the following function:
IMAQ ImageToArray VI - http://zone.ni.com/reference/en-XX/help/370281P-01/imaqvision/imaq_imagetoarray/