From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
04-08-2014 09:32 PM - edited 04-08-2014 09:32 PM
Hello all,
I've been searching around and testing out the IMAQ ExtractSingeColorPlane and the IMAQ ColorThreshold. I've never done anything with extracting certain colors before, and I seem to run into errors when I try wiring my image source into these IMAQ blocks.
Anyway, I have a VI that opens up my webcam and continuously runs it in video mode (giving me a 32bit RGB image). The VI snaps an image of what the webcam sees and converts it to grayscale, then to a binary image. The problem I've run into is due to the threshold limits it picks up the green background that my objects sit on as well as the objects. I would like to know, if possible, how I could separate the green from the image entirely so that it does not affect my particle analysis? The furthest I've gotten is for the color threshold to spit out a grayscale image, but it doesn't change no matter how I alter the ranges for red, green, or blue.
Any assistance is greatly appreciated.
Thanks
04-09-2014 09:21 AM
I'm not sure why you are getting errors but that I don't think that has anything to do with the question that you asked.
First, have a look at the following example in the Example Finder (switch to directory structure):
\Vision\2. Functions\Color\Color Threshold Example.vi
Then, can you create an example of what you are doing and post over here so we can look at the steps that you are taking.
04-09-2014 12:15 PM
Hey thank you for the reply!
I've been using this vi as a sort of guiding tool to try to understand exactly what I'm doing.
I've attached what I want to do (atleast I think that's what I want logically), but I can't seem to get it right.
I've used this same kind of logic for coverting to grayscale and thresholding to create a binary image, so I'm not sure how to do it with color thresholding.
Thanks for your help.
04-09-2014 01:24 PM
Can you save it for 2012 and then upload?
04-09-2014 01:29 PM - edited 04-09-2014 01:33 PM
Err, how do I do that?
Edit: Did this work?
04-09-2014 01:44 PM
File -> Save for Previous Version..
04-09-2014 01:48 PM
I guess the previous post upload was incorrect. Sorry >.<
04-09-2014 01:50 PM
Ah this is not going to help me. Can you please save your image and send it to me so I can figure out how to achieve what you want to do.
04-09-2014 01:54 PM
So, this is what I'm trying to do. I'm just not sure what's wrong with the logic.
04-09-2014 01:58 PM
Oh sorry I was asking for the actual image that you acquired. I was able to successfully open your VI.