Re: Limit capture file size(video) in C#



On 2 Jun 2006 04:51:53 -0700, bjames3 wrote:

I am trying to limit capture(video) file size by doing
the following:

captureGraphBuilder.AllocCapFile(fname, 2000000);
captureGraphBuilder.SetOutputFileName(MediaSubType.Avi, fname, out mux,
out sink);

The file size is always larger than 2MB.
I am probably not implementing this correctly. Can anyone tell
me what I'm doing wrong?

The docs say:

"The AllocCapFile method preallocates a capture file to a specified size.
For best results, always capture to a defragmented, preallocated capture
file that is larger than the size of the capture data."

They don't say anything about it limiting the capture to this size. AFAIK,
it doesn't.


--
Please read this before replying:
1. Dshow & posting help: http://tmhare.mvps.org/help.htm
2. Trim & respond inline (please don't top post or snip everything)
3. Benefit others: follow up if you are helped or you found a solution
.



Relevant Pages


Loading