Hello,
Thank you for your post.
I'm not sure how far you have got with your VI, but here's a method of retro-fitting a ROI into your program.
- Build a new script using Vision Assistant using only acquisition and an 'Image Mask from ROI' step
- Acquire your desired image and specify your ROI
- Create a new VI from this script (Tools >> Create LabVIEW VI...)
- A cluster (including two arrays) of suitable data will be generated within the new LabVIEW code. The top (blue) array is your ROI data . The lower array (pink with blue insert) is your mask data with a similar format to the ROI, but with masking specifics added . You can then copy and paste this cluster into the VI you're developing.
This design would obviously only give you a 'picture-specific' ROI. You would have to manually modify your array if you wished to change the ROI for any reason. Bear in mind also, if you change the ROI values in the cluster, then you must change the numeric values in the Mask array also. If you do not your image may contain a large portion of black pixels where the image has been 'cut off'.
This should give you a good starting point, but if you have any further questions then please let me know.
Many thanks,
National Instruments | Northern California