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.

Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

IMAQ functions changing Image Types

Hello,

 

Here is my situation: in the code picture I am providing I am creating an image of type U8 (IMAQ Create). This same image is then passed through an image grab (IMAQdx Grab2) but the image type this second VI spits out is changed to an RGB type. It does not keep the U8 type.

 

Underneath the IMAQdx Grab2.vi there is only a call to the niimaqdx.dll that in turn calls its LV_IMAQdxGetImage2 function, an again when tracing it, the dll function does get a U8 as input but outputs an RGB.

 

The front panel shows the image types from each property node, the first as U8 (desired), second as RGB.

>>>>> I wish to keep the type as U8 <<<<<

 

Another side note, when the image wires are probed, an image is acquired for the RBG, but not for the U8.

 

Has anybody stumbled with this? Am I using a wrong dll? (I've downloaded the latest from NI)

 

Thanks

 

JR

0 Kudos
Message 1 of 2
(1,722 Views)
Many color cameras(RGB U32) do support Grayscale(U8) version as output.
-This should be changed in camera attributes:Acquisition attributes->Output Image Type
-If it doesn't support then try type casting or use IMAQ Extract Single Plane to get the U8 image from U32 image type.
Thanks
uday
0 Kudos
Message 2 of 2
(1,694 Views)