video compressor

video compressor

Post by Juha Vuorm » Thu, 24 Aug 2000 04:00:00



How to find out the video compressor (CinePak, Microsoft Video 1 etc...)
used for an AVI file?
This info is probably written in in the stream header for the video stream,
but how can I read it??

Juha Vuorma

 
 
 

video compressor

Post by Mike D Sutto » Thu, 24 Aug 2000 04:00:00


Quote:> How to find out the video compressor (CinePak, Microsoft Video 1 etc...)
> used for an AVI file?
> This info is probably written in in the stream header for the video
stream,
> but how can I read it??

Have a look on Ray Mercers site over at:
http://www.shrinkwrapvb.com/
Hope this helps,

    Mike

 -- EDais --

WWW: Http://Members.xoom.com/EDais/



 
 
 

video compressor

Post by Juha Vuorm » Fri, 25 Aug 2000 04:00:00




Quote:> > How to find out the video compressor (CinePak, Microsoft Video 1 etc...)
> > used for an AVI file?
> > This info is probably written in in the stream header for the video
> stream,
> > but how can I read it??

> Have a look on Ray Mercers site over at:
> http://www.shrinkwrapvb.com/
> Hope this helps,

Not really. Using the code from that site returns a long integer for the
compressor (AVI_STREAM_INFO fccHandler ). I need it as a clear string
expression (like "Cinepak Codec by Radius")
 
 
 

video compressor

Post by Mike D Sutto » Fri, 25 Aug 2000 04:00:00


Quote:> Not really. Using the code from that site returns a long integer for the
> compressor (AVI_STREAM_INFO fccHandler ). I need it as a clear string
> expression (like "Cinepak Codec by Radius")

I'd have thought it should simply be a case of mapping these back so a set
of pre-defined strings like the genre of an ID3 tag for instance.  I'm not
sure though, I've never worked with video files before in VB.  I'd imagine
Ray would be able to shed some more light on this subject though.
Good luck,

    Mike

 -- EDais --

WWW: Http://Members.xoom.com/EDais/


 
 
 

video compressor

Post by Ray Merce » Sat, 26 Aug 2000 12:01:50


the codecs are defined in the *.h files in MS Visual Studio.  Just grep the
Include directory of Visual C++ (assuming you have it installed) to find the
mapping of codec to long integer.

Alternatively, take a look at the mmInfo example on my site.  In the source
for that you will see that I have already done the work for most of these
compression codecs.

Hope this helps,
Ray Mercer
www.shrinkwrapvb.com




> > > How to find out the video compressor (CinePak, Microsoft Video 1
etc...)
> > > used for an AVI file?
> > > This info is probably written in in the stream header for the video
> > stream,
> > > but how can I read it??

> > Have a look on Ray Mercers site over at:
> > http://www.shrinkwrapvb.com/
> > Hope this helps,

> Not really. Using the code from that site returns a long integer for the
> compressor (AVI_STREAM_INFO fccHandler ). I need it as a clear string
> expression (like "Cinepak Codec by Radius")

 
 
 

video compressor

Post by Juha Vuorm » Sat, 26 Aug 2000 04:00:00


Sorry, maybe I'm just stupid (not so familiar with avi file structure), but
I can't find info about AVI compression codecs in the source of mmInfo.
Reading avi stream into AVI_STREAM_INFO (fccHandler) does return a long
integer for compression codec, but can't find any ifo about how to get the
actual name of the compression code out of this long integer.

(And I do not have Visual C++ installed).

Juha Vuorma



> the codecs are defined in the *.h files in MS Visual Studio.  Just grep
the
> Include directory of Visual C++ (assuming you have it installed) to find
the
> mapping of codec to long integer.

> Alternatively, take a look at the mmInfo example on my site.  In the
source
> for that you will see that I have already done the work for most of these
> compression codecs.

> Hope this helps,
> Ray Mercer
> www.shrinkwrapvb.com





> > > > How to find out the video compressor (CinePak, Microsoft Video 1
> etc...)
> > > > used for an AVI file?
> > > > This info is probably written in in the stream header for the video
> > > stream,
> > > > but how can I read it??

> > > Have a look on Ray Mercers site over at:
> > > http://www.shrinkwrapvb.com/
> > > Hope this helps,

> > Not really. Using the code from that site returns a long integer for the
> > compressor (AVI_STREAM_INFO fccHandler ). I need it as a clear string
> > expression (like "Cinepak Codec by Radius")

 
 
 

video compressor

Post by Ray Merce » Sun, 27 Aug 2000 00:12:29



Quote:> Sorry, maybe I'm just stupid (not so familiar with avi file structure),
but
> I can't find info about AVI compression codecs in the source of mmInfo.

No. You are right.  I guess I was thinking of the mmReg.bas file in which I
translated the *wave* codecs from the C header to a VB bas.  Sorry.

Quote:> Reading avi stream into AVI_STREAM_INFO (fccHandler) does return a long
> integer for compression codec, but can't find any ifo about how to get the
> actual name of the compression code out of this long integer.

The long is a FOURCC code which just means four character code.  I guess I
never got around to putting these in a VB bas module but the info you need
is here (John McGowans AVI overview which is linked to from my AVI tutorial
pages);
http://www.jmcgowan.com/avicodecs.html#FourCC

Here are a few to save you some time;
BI_RLE8    &H00000001
RLE8        &H38454C52
BI_RLE4    &H00000002

they are listed here (a link off the site above);
http://www.webartz.com/fourcc/

Hope this helps,
Ray Mercer
www.shrinkwrapvb.com

 
 
 

video compressor

Post by Juha Vuorm » Thu, 31 Aug 2000 14:30:31


Thanks Ray, these sites do contain lots of info.
Juha





> > Sorry, maybe I'm just stupid (not so familiar with avi file structure),
> but
> > I can't find info about AVI compression codecs in the source of mmInfo.

> No. You are right.  I guess I was thinking of the mmReg.bas file in which
I
> translated the *wave* codecs from the C header to a VB bas.  Sorry.

> > Reading avi stream into AVI_STREAM_INFO (fccHandler) does return a long
> > integer for compression codec, but can't find any ifo about how to get
the
> > actual name of the compression code out of this long integer.

> The long is a FOURCC code which just means four character code.  I guess I
> never got around to putting these in a VB bas module but the info you need
> is here (John McGowans AVI overview which is linked to from my AVI
tutorial
> pages);
> http://www.jmcgowan.com/avicodecs.html#FourCC

> Here are a few to save you some time;
> BI_RLE8    &H00000001
> RLE8        &H38454C52
> BI_RLE4    &H00000002

> they are listed here (a link off the site above);
> http://www.webartz.com/fourcc/

> Hope this helps,
> Ray Mercer
> www.shrinkwrapvb.com