Reputation: 14385
I have a DirectShow application written in Delphi 6. I want to reduce the buffer size of the Renderer from its current 500 ms value to something smaller. The problem is, its input pin does not support IAMBufferNegotiation, which is odd since the renderer is the ear piece on my VOIP phone and it would obviously need a smaller buffer size to avoid an unpleasant delay during phone calls.
I tried a loopback test in Graph Edit connecting the VOIP phones' capture filter (microphone) to the renderer (ear piece). I know the buffer size is 500 ms because that's what Graph Edit shows for the renderer's properties. However, when I use the VOIP phone in a Skype call the delay is much shorter, about 50-100 milliseconds as I would expect.
So Skype knows how to change the renderer's default buffer size. How can I do the same trick?
Upvotes: 1
Views: 1086
Reputation: 69734
Output pin is normally responsible for setting up the allocator, and IAMBufferNegotiation
is typically available on the output pin. You want to reduce buffers size at capture filter's output pin only, and it will generate small buffers which are going to travel through the graph being still small buffers and small chunks of data, so reducing buffer sizes at intermediate filters is not necessary.
Upvotes: 3