LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

IMAQ write to bmp

I am grabing an image and I am trying to save it. For this I am creating a file and then using IMAQ Write to BMP File but it doesn't work. I suppose that there is something wrong in the way I am creating the file or something like that. Could someone have a look at my .vi ? Thank you.
0 Kudos
Message 1 of 4
(2,885 Views)

Hi there,

Looking at your vi,

What is happening is that you are disposing of the image at the same time as you are trying to save the image.  If you wire the error out from the write to bmp file vi to the error in of the dispose of image vi.  Then you will save the file before you dispose of the image.

That should solve your problem.  Post back if you have any problems.

Thanks

AdamB

Applications Engineering Team Leader | National Instruments | UK & Ireland
0 Kudos
Message 2 of 4
(2,867 Views)

Not sure what you intend to do with this image, maybe you'll be done with it after saving it or something else of that nature, but bmp files are often very large in comparison to other file techniques (png, etc.).

Take it or leave it, but may I suggest using another image type if you intend to do image processing on your file.

Regards,

0 Kudos
Message 3 of 4
(2,859 Views)
Thank you Adam, it's working now.
0 Kudos
Message 4 of 4
(2,856 Views)