Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Using IMAQ ROIToMask or IVA Mask from ROI.vi

I am having difficulty using the ROI vi's in Labview. When I use the IMAQ ROIToMask with a ROI descriptor the indicator image on the front panel is white in the ROI, when it should be the original image? The image also seems to be cropped where the ROIs are, but I want the whole image black except the ROIs? I used a Labview code created from Vision Assistant 7.1, and by inserting the ROI Descriptor obtained from the other Labview program it worked just fine? I believe I am setting up the image property node incorrectly, but I am not sure. They both should have the same ROI descriptors, so they should have the same resulting image? I can send the 2 Labview codes and a sample image if that would help? Thank you in advance for any assistance.

Kevin Baker
0 Kudos
Message 1 of 2
(6,526 Views)
Hey Kevin,
Take a look at the "Mask Example.VI" found in the NI Example Finder. And also take a look at the Histogram Example.VI and see how you can use the ROItoMask VI, and then incorporate it into the Mask Example and this should help do what you are trying to do. It sounds as if you might be leaving out the IMAQ Mask VI, which is why the ROItoMask is only giving you just white inside of the ROI in your resulting image.
If, after trying this out, and you are still having some difficulties, you can attach your code and we can take a look at it. Hopefully these examples will get you on the right path. Please keep us updated on how things are going. Thanks and have a great day.

Regards,
DJ
Applications Engineer
National Instruments
Message 2 of 2
(6,509 Views)