By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,376 Members | 1,559 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,376 IT Pros & Developers. It's quick & easy.

Too much CPU in video-capture session

P: n/a
Hi everybody!

Im developing an application which involves capturing video from a
webcam. I use video for windows API. The program doesn't capture
real-time video, but it only captures still-images from time to time.
When the program is waiting and doing nothing, the CPU is at 50%. I
would like to know if there is any posibility to reduce the amount of
CPU used.

By the way, the code that I used to start the still-image capture
session is the following:

-----

hWndC = capCreateCaptureWindow ("CW",
WS_POPUP,
0,
0,
0,
0,
NULL,
nID);
capDriverConnect(hWndC, 0);

capCaptureGetSetup(hWndC, &Parameters, sizeof(Parameters));
Parameters.fYield = false;
capCaptureSetSetup(hWndC, &Parameters, sizeof(Parameters));

capPreview(hWndC, false);

----

Any advice?

Thank you very much for your help!

Oct 25 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Perro Flaco wrote:
Hi everybody!

Im developing an application which involves capturing video from a
webcam. I use video for windows API. The program doesn't capture
real-time video, but it only captures still-images from time to time.
When the program is waiting and doing nothing, the CPU is at 50%. I
would like to know if there is any posibility to reduce the amount of
CPU used.

By the way, the code that I used to start the still-image capture
session is the following:

-----

hWndC = capCreateCaptureWindow ("CW",
WS_POPUP,
0,
0,
0,
0,
NULL,
nID);
capDriverConnect(hWndC, 0);

capCaptureGetSetup(hWndC, &Parameters, sizeof(Parameters));
Parameters.fYield = false;
capCaptureSetSetup(hWndC, &Parameters, sizeof(Parameters));

capPreview(hWndC, false);

----

Any advice?

Thank you very much for your help!


I'd suggest you post on a Microsoft newsgroup like
comp.os.ms-windows.programmer.win32, as the present newsgroup is for
standard C++ language issues, not OS-specific APIs.

Cheers! --M

Oct 25 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.