X-Posting-Agent: Hamster/1.3.21.120 From: Peter Haas Newsgroups: borland.public.delphi.multimedia Subject: Re: Video capture frame rate Date: Tue, 12 Jun 2001 18:32:52 +0200 References: <3b25fce2_2@dnews> X-Newsreader: Forte Agent 1.8/32.548 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Host: 62.155.203.52 Message-ID: <3b26443a_1@dnews> X-Trace: dnews 992363578 62.155.203.52 (12 Jun 2001 09:32:58 -0700) Lines: 56 Path: dnews Xref: dnews borland.public.delphi.multimedia:1679 Hi Nick, Nick Barrett wrote in <3b25fce2_2@dnews>: > How does one set the capture frame rate when using capCaptureSequenceNoFile? > I have tried changing CaptureParms.dwRequestMicroSecPerFrame in my program > but there seem to be no change to the rate that VideoStreamCallback is > called. I have tested the following method in my demo, there are no problems. I can set 1 frame per second and 50 frames per second, the frame rate will realize. UDFrameRate is a TUpDown. var CaptureParms : TCaptureParms; begin if FCapWnd <> 0 then begin capCaptureGetSetup(FCapWnd, @CaptureParms, SizeOf(CaptureParms)); with CaptureParms do begin // frame rate dwRequestMicroSecPerFrame := 1000000 div UDFrameRate.Position; // background capture fYield := True; // abort by mouse click fAbortLeftMouse := True; fAbortRightMouse := True; // abort after 30 seconds fLimitEnabled := True; wTimeLimit := 30; // abort with space key vKeyAbort := vk_space; end; capCaptureSetSetup(FCapWnd, @CaptureParms, SizeOf(CaptureParms)); capCaptureSequenceNoFile(FCapWnd); end; end; But, I know a effect from my program: If the duration of the callback procedure to big, the next frame(s) will skip. Use dwTimeCaptured to detect the correct position of the frame. But this behavior can be dependant from the video card driver. I use a miroMEDIA PCTV from miro (after the takeover to pinnacle the cards will renamed in miroVIDEO PCTV and later in STUDIO PCTV). The driver based on the BT848 driver Version 2.3.040. Maybe your driver have a another behavior, if your computer too slow for a frame rate. Bye Peter.