Jump to content

imaq avi2 write frame bug


Recommended Posts

Hi all,

 

I am writing an avi file composed of u8 grayscale images using IMAQ AVI2 write frame function. But when I am reading the file image type with IMAQ AVI2 Get info the image type is shown as u32-RGB :oops: . I searched through net but I couldn't find a solution. Could I get help on the knowledge why it does so? 

 

Vision Version:13.0.0

Codecs Tried:  Cinepak Codec by Radius,FF Video Codec 1 (FFV1) (NI Vision),Motion JPEG (NI Vision),Y800                                                  Uncompressed Grey Scale (NI Vision),YUV 4:2:0 Planar (NI Vision).

 

Thanks in advance,

Prabhakaran :thumbup1:

Link to comment

Hi,

 

It seems that the problem occurs in reading the avi file using avi2 open file . Because the IMAQ AVI2 Get Info provides output of U8 if used with the write session and U32 with read session. Is this a bug or are there any means to avoid this?

 

AVI is really only a container format and mostly meant by Microsoft to be used for real world video. What format the data is actually written in depends highly on the available codecs on your machine. Most likely it won't support U8 and/or greyscale without installing a very specific codec that supports such a format. And if you created such a formatted AVI you won't be able to replay it on machines that have not the same codec installed.

 

The Windows AVI interface correctly changes the format to an available codec format that, at what it believes at its own discretion is the closest match to the incoming format. If you check the format of the resulting AVI file with some AVI file format checker you will see that it is already RGB when written on disc and the reading will simply read in what is on disc and has no way to magically know that it should convert it back to U8 greyscale.

Link to comment

AVI is really only a container format and mostly meant by Microsoft to be used for real world video. What format the data is actually written in depends highly on the available codecs on your machine. Most likely it won't support U8 and/or greyscale without installing a very specific codec that supports such a format. And if you created such a formatted AVI you won't be able to replay it on machines that have not the same codec installed.

 

The Windows AVI interface correctly changes the format to an available codec format that, at what it believes at its own discretion is the closest match to the incoming format. If you check the format of the resulting AVI file with some AVI file format checker you will see that it is already RGB when written on disc and the reading will simply read in what is on disc and has no way to magically know that it should convert it back to U8 greyscale.

Hi Rolf,

Thanks for your reply. But I have tried "Y800 Uncompressed Grey Scale (NI Vision)" codec. This codec comes along with NI Vision installer. From the name of the codec, looks like it supports grey scale images to be written. 

 

Earlier, we were able to write and read grey scale images using AVI1 vis and we don't have to specify codec in the AVI1 vis.

 

Thanks,

Prabhakaran. :thumbup1: 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.