Re: setting video format
From: Joe Johnson (joe_at_eirbase.com)
Date: 06/28/04
- Next message: charly: "Re: Mpeg2 playback"
- Previous message: Joe Johnson: "Re: possible to connect 2 graphs?"
- In reply to: The March Hare (MVP): "Re: setting video format"
- Next in thread: Joe Johnson: "Re: setting video format"
- Reply: Joe Johnson: "Re: setting video format"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 28 Jun 2004 15:43:59 +0100
On Mon, 28 Jun 2004 07:19:06 -0600, The March Hare (MVP) wrote:
> On Mon, 28 Jun 2004 12:47:49 +0100, Joe Johnson wrote:
>
>> I live in Europe and thus need to change the video format on my
>> capture cards from the default of NTSC to PAL.
>>
>> The VIDEO_STREAM_CONFIG_CAPS seems to be the structure to use in
>> this case. I can retrieve the populated structure using the
>> IAMStreamConfig::GetStreamCaps() method but there doesn't seem to
>> be a way to return the altered structure.
>>
>> The IAMStreamConfig::SetFormat() method takes a pointer to an
>> AM_MEDIA_TYPE structure, but the 'formattype' member doesn't
>> seem to support passing the VIDEO_STREAM_CONFIG_CAPS structure
>> back.
>>
>> Has anybody come across this problem before and/or have a solution?
>> I don't want to have to call up a property page if at all possible.
>
> See "Configure the Video Output Format" in the SDK docs for setting frame
> rate and resolution. Particularly:
>
> "To request a particular frame rate, modify the value of AvgTimePerFrame in
> the VIDEOINFOHEADER or VIDEOINFOHEADER2 structure in the media type. The
> device may not support every possible value between the minimum and
> maximum, so the driver will use the closest value that it can. To see what
> value the driver actually used, call IAMStreamConfig::GetFormat after you
> call SetFormat."
Sorry, I didn't make the question clear enough. I've been through that
example many times already. As I said in my previous mail, the
AM_MEDIA_TYPE only supports certain casts, namely:
FORMAT_DvInfo DVINFO
FORMAT_MPEGVideo MPEG1VIDEOINFO
FORMAT_MPEG2Video MPEG2VIDEOINFO
FORMAT_VideoInfo VIDEOINFOHEADER
FORMAT_VideoInfo2 VIDEOINFOHEADER2
FORMAT_WaveFormatEx WAVEFORMATEX
They give a very nice example on how to change things in the
VIDEOINFOHEADER, which is easy to follow and understand because it's a
supported format type. But VIDEO_STREAM_CONFIG_CAPS is the structure
I need to change and I don't see it anywhere in the list of supported
types, so how do I pass it in?
Could it be that the the documentation is wrong and this structure was
omitted?
- Next message: charly: "Re: Mpeg2 playback"
- Previous message: Joe Johnson: "Re: possible to connect 2 graphs?"
- In reply to: The March Hare (MVP): "Re: setting video format"
- Next in thread: Joe Johnson: "Re: setting video format"
- Reply: Joe Johnson: "Re: setting video format"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|