directshow - Is it normal for a filter to receive BeginFlush and EndFlush in a graph which is not being seeked? -


I am working on a custom multiplexing filter that does not support demand - because it was not designed to do To go and do not need to.

When I connect it to the main Concept / Rovi MP4 demultiplexer side and the main Concept Broadcast MP4 / AVC decoder my filter just called after the IBaseFilter to receive BeginFlush, EndFlush, NewSegment call: Stop: But before that the first sample has been given. Setupation is not called. I shortened BeginFlush to a MP3 Demix filter.

Is this a true directshow behavior? I understand the role that plays in the demand of BeginFlush / EndFlush, but is it safe or acceptable at the beginning of streaming? I do not see much reference to BeginFlush / EndFlush in Microsoft documentation outside the context of the demand for operation. Call to BeginFlush is clearly happening during calls to IMediaControl :: Run (see Stack Calls below) rather than calling as SetPositions (or similar) as a result of the graph demand host program.

Is there a proper filtering process to leave the BeginFlush / EndFlush requests that come before the initial sample?

There are many filters out there that do not support the demand and therefore do not support BeginFlush / EndFlush well.
  quartz.dll! CFilterGraph :: stop () + 0x109 bytes quartz.dll! CFGControl :: Q () + 0x1b bytes quartz.dll! CFGControl :: CueThenRun () + 0x12 bytes quartz.dll! CFGControl :: CImplMediaControl :: StepRun () + 0x59 bytes quartz.dll! CFGControl :: CImplMediaControl :: Run () + 0x2d bytes  

probably "correct" right The word is not here, is it a legal practice? I think it is. Before starting streaming, Demultiplexer flushes, why not, that is why it is specific how they ask, which they flush before sending it from the clean point and they send it initially as well.

Flushing is not just a part of the demand for capacity. This is a key feature that should support and implement a filter, so when you receive the request, why not you flush? Or just ignore when you have nothing to flush? I would say that if it creates a kind of problem then the majority may do something wrong in a wrong way because the flushing request is not like that seems to be breaking. I think it is also legal to get it in the middle of streaming, let us know that for any reason the source or decoder decides to withdraw the data in the transit downstream.


Comments