Following the Amcap sample, my filter gets its idea of the resolution of the
sample that it will see in Transform(.) from calls to CheckInputType and the
VIDEOINFOHEADER that is part of the CMediaType. Since the last input type it
checks has the wrong resolution, it was getting confused and I've had to make
an ugly kludge hack-around.
So these are my questions: Is there a way to know within CheckInputType
whether the call is coming from upstream or downstream? Or is there maybe
some other, more reliable, way to determine the dimensions of the sample
presented to Transform(.)? And a bonus question - why might anything
downstream of my filter call CheckInputType after the graph has started
running?
Thanks for any help . ..
Hi Doctor Bonzo,
This is the best example of a transform filter I have seen:
http://read.pudn.com/downloads40/sourcecode/windows/directx/138748/YUVGray/YuvGray.cpp__.htm
You may want to take a look at it. It handles dynamic resolution/
stride changes from the renderer. It may also help you with what you
are trying to do by using it as an example.
Hope this helps...
Tom
"Tom Handal" wrote:
> http://read.pudn.com/downloads40/sourcecode/windows/directx/138748/YUVGray/YuvGray.cpp__.htm
This is indeed a good example - much better than what I was using which was
apparently from some preliminary DirectShow dox. Thanks for the pointer.