Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Cursor Control In an Image

Hi guys,

 

Currently, i am only able to control one cursor although my programme allows me to add in mulitple cursors into the image. Right now, i uses the "last mouse position" which i obtained from the image to execute my respective desired movement in either a linear or circular motion. However, I will like to be able to control multiple cursors, with each cursor able to move by their own according to the instructions given by me. The limitation i faced was that i relied on the "last mouse position" from the image. Thus, I only have one set of data to play with as determined by the mouse cursor. Although I am able to retrieve mulitple positions of the other cursor, I was unable to manipulate them to my means.  

 

Software explaination:

The scroller of my mouse determines whichever cursor will be controlled. At each time, only one cursor is moving. 

 

Thank you in advance. 

 

Regards,

Scott

0 Kudos
Message 1 of 3
(4,709 Views)

Instead of relying on such a complicated scheme to implement cursors, I recommend that you make use of the ROI features built in to the IMAQ Picture control.  There are many ways to take advantage of the ROI property node.  You can check the ROI value for any changes (like when you add a cursor), and use that event to COPY the ROI to another holding variable.  You can then do things like put down new cursors, without needing to worry about holding down CTRL (palce multiple ROI shapes).  I'm oversimplifying it a bit, but ROI is the way to go.

Machine Vision, Robotics, Embedded Systems, Surveillance

www.movimed.com - Custom Imaging Solutions
0 Kudos
Message 2 of 3
(4,669 Views)

Hi MoviJohn,

 

Thanks for the reply. Can i take it that you wanted me to compare the images with and without the cursor first then subsequently use it as a trigger to implement my function? Next, I was wondering in this event when i have 2 cursors in the images, is it possible for me to control both cursors simulataneously? Thank you

 

Your Regards,

Scott

0 Kudos
Message 3 of 3
(4,645 Views)