LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Remove last point from polygon ROI while drawing it

Hello.

 

I would like to allow the user to correct a polygon ROI drawn on an image viewer while still drawing the ROI. More specifically, the user should be able to make a right click to remove the last drawn point from the polygon ROI and add additional points with further left clicks until he finishes the ROI with a double click.
 
Currently I don't see any way to access the ROI while the user is still drawing it. Only after the ROI is finished with a double click I can access it via the ROI property of the image viewer.

 

Does anyone know of a solution to this problem?

0 Kudos
Message 1 of 5
(1,655 Views)

I was going to suggest to add an option for the user to remove a point by customizing the shortcut menu. It seems however this would remove some functionality of that menu: https://forums.ni.com/t5/Machine-Vision/Image-Run-Time-Shortcut-Menu/m-p/3335129#M48232

0 Kudos
Message 2 of 5
(1,600 Views)

I do not see how your suggestion would solve the problem that the ROI data is not accessible while the ROI is still drawn. So how can I modify the polygon ROI and remove, for example, the last point before the user ends the drawing operation with a double click. 

0 Kudos
Message 3 of 5
(1,592 Views)

@mprantl wrote:

I do not see how your suggestion would solve the problem that the ROI data is not accessible while the ROI is still drawn. So how can I modify the polygon ROI and remove, for example, the last point before the user ends the drawing operation with a double click. 


It doesn't. As you said the ROI is only accessible until after the double click and I don't see NI changing this behavior.

I was suggesting you could let the user remove a point after creating the polygon. It seems it's either that or starting over.

0 Kudos
Message 4 of 5
(1,576 Views)

Ok. I misunderstood your first answer. I was just hoping that maybe one can access the ROI under construction in a DLL call but I couldn't find anything. 

0 Kudos
Message 5 of 5
(1,568 Views)