Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

DIB handle to Imaq Image

I'm using an ActiveX which controls an IEEE1394 digital camera, and returns a DIB handle number. Does someone know how I can retrieve that bitmap into LabView for image processing with Imaq VI's?
0 Kudos
Message 1 of 4
(3,346 Views)
There are a couple of things that need to get done.
1. NI Vision requires that data in a 4 byte RGBValue structure while the DIB data is 3 bytes so the entire DIB must be copied into the RGBValue structure.
2. The DIB is stored upside down so the image must be flipped by rows (i.e. row 480 becomes row 1, 479 to 2 etc.)

Once the data is in this format then you can successfully run it through the imaqArrayToImage function so that it can be displayed and manipulated.

Randy
0 Kudos
Message 2 of 4
(3,346 Views)
Thanks, Randy. Though, my problem is even earlier. I only get a "DIB handle" (number) from the ActiveX control. How do I get the data (array, variant or something) that handle stands for? Should I make some API call? I think that must be easy in C, but I don't know what function should I invoke.

Felipe
0 Kudos
Message 3 of 4
(3,346 Views)
I am trying to do the same thing. Have you been able to figure it out?

Terry Sopkow
0 Kudos
Message 4 of 4
(3,346 Views)