06-30-2009 12:22 PM
Hi,
I'm new to labVIEW and the vision module. I'm using IMAQ, and I want to be able to create a permanent vertical cursor over the image at a default location, and have the cursor dragable over the x-dimension, and return the x value location of the cursor.
Is there any way to accomplish this?
Thanks!
Richard C.
07-01-2009 10:23 AM
Hey Richard
Check out the attached example. The example uses the IMAQ overlay function to place a line on your image. Then, through an event structure architecture, you can then click on your image and set the new position of this line. The example is written in LabVIEW 8.6. Post back if you need further explanation of how the example works or if you have trouble opening it. Cursor
07-01-2009 12:54 PM
Hi,
Thanks for the quick reply! I'm using LabVIEW 8.5 (I probably should have mentioned this earlier), so I'm unable to open the file, could you post a file that's compatable with 8.5? I would really appreciate it!
Thanks,
Richard C.
07-01-2009 01:16 PM
Hey Richard,
Sorry about that. I should have anticipated that. Please see the attached VI. Post back if you still have trouble opening it and running it.
07-01-2009 04:21 PM
I can open this file just fine.
It was very helpful, though it only seems to work for still images. What I'm doing is taking the image output from a camera and plotting a cursor in real time. Right now, I can plot the default/starting x coordinate for the cursor, and change it's position by typing in a new coordinate. But I was hoping to introduce a "click to aquire" coordinate method. If you (or anyone else) knows a way to acomplish this, I'd greatly appreciate. But since I got a movable cursor up/running, it's not too high on my priorities.
Thanks for all the help so far though!
Richard C.
07-01-2009 04:50 PM
Hey Richard,
The code that I posted earlier is a good starting point for your application. You can take that routine and add it to your code. I have done this for a simple grab using a Firewire camera using the IMAQdx driver to acquire images. In this example you can see your image and see it update in 'real time.' The cursor will follow your mouse when you have your mouse over the image. If you left click on the mouse you will see the coordinates of where you clicked saved in a numeric indicator.
Again, this code could just be a starting point for your application.
07-01-2009 05:17 PM