Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Imaq invalid image type

Hi,

 

i try to analyse a video image. it is an image typ 32 bit rgb. In the sub vi I try to count the pixel with a red value greater than the green and the blue value. Therefore i need to split the colorplanes.

After that I write the values in an arry to count them.

 

Sometimes the Error "Invalid image typ" appears. I´m not sure why this error sometimes appeared and sometimes not.

 

I hope someone can help me to find the solution.

 

 

0 Kudos
Message 1 of 2
(4,282 Views)

Hello,

 

does the error happen only, when your ROI is passed as an empty cluster? So, if you have an active ROI, there is no error right?

 

Make sure your ROI is not empty, or alternatively you could use "IMAQ SetImageSize" after allocating the memory for the mask (set the size to the same size as the input rgb image with "IMAQ GetImageSize".

 

Does this help?

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
0 Kudos
Message 2 of 2
(4,261 Views)