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.
03-17-2009 09:05 AM
I was getting the above error under LV 8.5, so I searched and found this example:
http://digital.ni.com/public.nsf/ad0f282819902a1986256f79005462b1/20ab177016de51c0c1256f03006a74cb/$FILE/ExtractColorPlane_Example.vi
which includes two vi's ExtractSingleColorPLane and ExtractColorPlanes. The first works fine , but ExtractColorPlanes throw the same error I was getting in my own code.
Any suggestions?
David
Solved! Go to Solution.
03-18-2009 05:04 PM
Hello David,
The reason why this error occurs in this example is due to a timing issue. The 'Image' image buffer first storest the color image that is read from a file and then stores the output of IMAQ ExtractSingleColorPlane. The IMAQ ExtractColorPlanes VI expects an RGB image to be its input. However, if the IMAQExtractSingleColorPlane VI runs BEFORE the IMAQ ExtractColorPlanes VI, the 'Image' image buffer no longer holds an RGB image. This is what leads to the error you mentioned in this case.
A workaround is to create a copy of the RGB image so that the buffer is not over-written. I have attached an image to show how this can be done. I hope this helps!
03-19-2009 08:20 PM
Vivek,
Thanks - I made the copy as you showed, and it works - sometimes. Something else is going on also, because if I run it several times in a row, it will run sometimes, and fail with the original error message other times. Other times I get no error message but the image from ExtractColorPlanes has obvious defects in it.
David
03-20-2009 10:23 AM
03-20-2009 06:38 PM
Randall,
Thanks - that works just fine. Which of the help files/ reference docs is most useful for such things?
David
03-23-2009 10:49 AM
02-18-2011 11:44 AM
Hi, I trie to run the VI, and it's not working, I don't know why, I've been the same problem.... any suggestigon?