11-14-2013 01:58 PM
Hello
I have a grayscale image which I want to rotate about the y-axis. any idea how to do it?. using a rotation matrix can be done?
11-14-2013 03:32 PM
hi manuel,
have a look at this thread https://forums.ni.com/t5/LabVIEW/Rotate-an-image/m-p/2482802#M758765
adding a canvas around the input image before applying the rotation matrix will avoid artefacts due to underfitting
Regards,
Alex
11-14-2013 04:59 PM - edited 11-14-2013 04:59 PM
Thanks for answering.
Maybe I did not explain properly, i'm trying to rotate the image about the axis y, as shown in figure.
Regards
11-14-2013 06:38 PM - edited 11-14-2013 06:46 PM
Hello Manuel33,
The image you provided seems to indicate that Alex's solution is what you are looking for (it's not immediately clear where the image you're manipulating with is in relation to the planes in the diagram), could you provide a "before" and "after" example that demonstrates what you are trying to achieve? Better yet, if you can, please post your code as well to show what you've already done and point out what part you are working on.
If all you need is the appearance of a rotation towards or away from the orthogonal plane (this is a 2D image we are talking about, isn't it?) you can achieve this affect by either deleting columns from the image or averaging column subsets. For example- if you want to have the appearance of rotating 45 degrees, delete or average every other column. If you want to add a "perspective" effect and taper the "far" edge, thats a bit more complex but I imagine it could also be achieved with selective deletion or averaging of pixels.
If you're working with a 3D image, that's a very different question. You should be able to rotate the object on which the image is overlaid using the Rotate Object VI available in the Graphics & Sound>>3D Picture Control>>Transformations palette.
Regards,
11-15-2013 02:42 PM
Hi, i´m traying to do something like this "Figure", i´m getting cross-sections of a concentric semisphere, and i want to plot it in 3D graph, but i can´t rotate the image properly.
11-16-2013 11:42 AM
The code work great for vertical lines as show in figure "Line", with 360 images i can form a 3d reconstruction, however i´m trying to form a reconstruction with 180 images of a concentric sphere, any idea that i can change in my code?
11-18-2013 03:42 AM
do you know about this thread?
If anyone wants to rotate an image around a different axis, they just have to figure out the rotation matrix and replace mine with theirs, so it's fairly scalable
http://forums.ni.com/t5/LabVIEW/got-bored-maybe-this-will-help-someone/m-p/1137515