NI Home > Community > NI Discussion Forums

Machine Vision

Reply
Active Participant X.
Active Participant
X.
Posts: 1,836
0 Kudos

Delete ROI Contour/Clear ROI event capture

I am trying to figure out how to capture a "Delete ROI Contour" or a "Clear ROI" event (LabVIEW 2009 SP1).

"Mouse Up" doesn't seem to be triggered with Right Mouse Clicks (used for both actions). "Mouse Down" is triggered and tells me which button is pressed, but it is not helping me much figuring out what will happen next (unless I compare the previous ROI state with the one that will result from the user action...which I don't know what it will be and when it will end).

"Shortcut Menu Selection (App)" does not seem to be triggered by any of these actions, surprisingly, so I am quite at loss on how to detect (simply) these events...

Thanks for your suggestions.

X.

Active Participant
Andrey_Dmitriev
Posts: 1,536

Re: Delete ROI Contour/Clear ROI event capture

AFAIK these functions are not available in Run-Time. Only in development mode.

Comparing ROI states is probably easiest way to getting these events (simple polling should be sufficient).

 

Andrey.

 

Active Participant X.
Active Participant
X.
Posts: 1,836
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

I don't understand. Why would they be available as acceptable events in the Event Structure if they were not accessible at Run-Time?

I have emailed NI to report this as a bug.

Active Participant
Andrey_Dmitriev
Posts: 1,536
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

 


Xavier wrote:

I don't understand. Why would they be available as acceptable events in the Event Structure if they were not accessible at Run-Time?

I have emailed NI to report this as a bug.


Its not a "Bug". Its a "Feature":

 

http://zone.ni.com/reference/en-XX/help/370281M-01/nivisionlvbasics/display_an_image/#Image_Display_...

 

"Note  Not all functionality available during design time is available at run time."

 

Active Participant X.
Active Participant
X.
Posts: 1,836
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

I still don't understand :smileyhappy:

What good is an event such as "Shortcut Menu Selection (User)" at Edit time? There is no such thing as a User shortcut menu at Edit time, as far as I know!

As a corollary, if User or even App shortcut menu selections are inaccessible at runtime, we should be able to distinguish between a left click and a right click on the image. That is not the case. Left clicks are detected as events, but Right clicks are not detected.

In summary, if this is a "feature", it smacks of complete disregard with logic and consistency.

Best,

X.

Active Participant
Andrey_Dmitriev
Posts: 1,536
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

There are lot of things in Vision Display which are very inconvenient for end user and can be improved. This display is good for simple things (for example, if you working with single ROI). But when you try to build more or less complicated GUI application, then you will see lot of limitations. For example, you can't get easily ROI ID which is selected or moved by user. You have some troubles with ROI deletion. Some bugs with I16 image type still here. Multiple ROIs cannot have different colors. And so on, so on, so on... You don't need to understand it, all what you can do - is just find some workarounds for each problem (or develop your own image display, which is pretty complicated task). Try to submit Feature Request to NI for each inconvenient thing - may be something will be changed in a future...

 

Andrey.

 

Active Participant
Andrey_Dmitriev
Posts: 1,536
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

There are lot of things in Vision Display which are very inconvenient for end user and can be improved. This display is good for simple things (for example, if you working with single ROI). But when you try to build more or less complicated GUI application, then you will see lot of limitations. For example, you can't get easily ROI ID which is selected or moved by user. You have some troubles with ROI deletion. Some bugs with I16 image type still here. Multiple ROIs cannot have different colors. And so on, so on, so on... You don't need to understand it, all what you can do - is just find some workarounds for each problem (or develop your own image display, which is pretty complicated task). Try to submit Feature Request to NI for each inconvenient thing - may be something will be changed in a future...

 

Andrey.

 

Active Participant X.
Active Participant
X.
Posts: 1,836
0 Kudos

Re: Delete ROI Contour/Clear ROI event capture

Tell me about it... I have started posting suggestions in the LabVIEW Idea Exchange forum. Is there any other place where NI might be looking at?