On Mon, 20 Oct 2008 23:16:11 -0700, <cr*****@gmail. comwrote:
Thanks for your reply. My own program is generating the animation and
this is probably what I want to do. If you are familiar with this,
can you elaborate more on what needs to be done or at least give the
DShow interface names so I can start looking them up on MSDN?
Sorry...I haven't done this stuff recently enough to have the relevant
interface names off the top of my head. Basically, though...you'll want
to set up a graph with the appropriate encoder and file writer as the
renderer, and your own pull source filter as the input.
Looking at the built-in "File Source (Async)" filter, it looks like a good
start would be the IBaseFilter and IAsyncReader filter interfaces (the
latter being implemented by the output pin of your IBaseFilter).
If you want more details, I recommend the DirectShow specific forums, such
as microsoft.publi c.win32.program mer.directx.vid eo. There's also
microsoft.publi c.multimedia.di rectx.dshow.pro gramming...I don't recall
that newsgroup, but it looks like it's been around since '97. I don't
know what the difference between the two might be, other than that the
"video" newsgroup is likely to be more specific to video-related
questions, while the other is probably more general.
Is a source filter basically an array of images?
In DirectShow, the entire process is set up as a directed graph. Each
node in the graph is a "filter". Every filter exposes input pins, output
pins, or both. The pins are the logical connection between one filter and
another.
Different filters do different things. Source filters provide data,
transformation filters change the data, and renderers write data. Sources
can be files, video cameras, or programmaticall y generated, for example.
Transformations including codecs, color-space conversion, video effects,
etc. Renderers can be video cards, files, network i/o, etc.
Source filters have only output pins, renderers have only input pins.
So, when I write "source filter", I mean that you'll implement a filter
with an output pin that will present each image in sequence to the
DirectShow graph that you've set up to write the file. You'll use as the
renderer an appropriate codec writing into the "File Writer" filter. When
I describe the filter as a "pull" filter, that means that the downstream
input pin is responsible for requesting each video frame as needed. A
"push" filter is one where the source controls the flow. "Pull" is
generally more appropriate when you want the renderer to go as fast as it
can (such as when writing a file).
This is all already pretty off-topic. Hopefully the above is enough to
get you pointed in the right direction, and you can get more help in the
more directly related forums as needed. (They may even clear up whatever
mistakes I've made in the above...as I said, it's been awhile and I may be
a bit rusty).
Pete