12-27-2016 07:25 AM
Hello to all.
First of all thanks a lot for reading this post and beeing able to help.
I have a VI which has two "Imaq Clamp Horizontal Max VI".
In those VI rectangle inputs are two different rectangles for each.
I can watch on a display that my VI meas the section in those rectangles correctly.
No I would like to do that when meas is less than 50px, the property rectangle will be red (by default is green)
How can I do that?
thanks a lot!!!
12-29-2016 03:27 PM
12-29-2016 03:35 PM
First of all thanks a lot for answering!
Yes, I can explain better.
I am using imaq clamp horizontal max vi, this VI has a input "rectangle" and it draw this rectangle (ROI) in green by default.
So when the output of this VI is less than 50pixels I would like that that rectangle will be red.
Look at attached image.
Thanks a lot
12-30-2016 01:49 AM - edited 12-30-2016 01:52 AM
Hi,
I gave this a look and found two ways that may work:
-Maybe using this VI: http://zone.ni.com/reference/en-XX/help/370281AA-01/imaqvision/imaq_overlay_roi/
-Or using property nodes: http://forums.ni.com/t5/Machine-Vision/How-can-I-create-different-colored-ROIs-using-the-ROI-propert...
(In your case it may be easier if there is only one ROI)
So you could use a case structure and if the condition you mention is true, you can set the color with the property node. (I think in this case a property node is a better option).
I'm not 100% sure of the implementation, but I think it is possible.
Regards,
12-30-2016 02:57 AM
Thanks a lot ofr answering!
I have looked at your solutions and absolutely they both can work.
The problem is that I have rectangles (not ROIS) but I can convert from rectangle to roy and then apply "overlay ROI) with a specific color.
If I do that in the image I will have drawed the rectangle in green(this rectangle is drawed by clamp vi by default) and ROI over it in a specific color. Maybe there is a better solution for jus having just rectangle or ROI.. not both.
Thanks again! I will try it.
12-30-2016 03:07 AM
that is good question because I think it is some kind of problem that should be fix for this vi
anyway your answer is this
this vi is subvi if you double click on this vi you could open windows of this subi
there is on other subvi inside this vi that relate to overlay (check figure that I attach )
as you see there is no terminal output for color control and it is green by default
you can add out put thermal for this control and save it ofter that you can change overlay any time that you want