slow dialog box in windowed mode

Started by
2 comments, last by Endurion 15 years, 9 months ago
Hi all, I created an application where I use directdraw 7 to output a video to the screen. It is in windowed mode. I also have a dialog bar that controls the gain and exposure of the camera that is capturing the video. I use trackbars and edit boxes. However the dialog box is kind of slow. when I drag the bar, the edit boxes take time to update their values. (the dialog box is in overlapped child window) Is there a way to speed it up? Thank you,
Advertisement
Is your app using a lot of CPU time? If you're slow on handling messages, it will slow down your modeless dialog processing.
Do you call UpdateWindow in the dialog in the same call where the edit control is changed? If not, your dialog has to wait for the next paint to update, which won't occur until your video processing takes a break or calls OnIdle() (or whatever you use to be polite to the rest of the world).

Please don't PM me with questions. Post them in the forums for everyone's benefit, and I can embarrass myself publicly.

You don't forget how to play when you grow old; you grow old when you forget how to play.

What does your message pump look like?

You should process all available messages before doing the render/update stuff. Otherwise you'll end up with seemingly lagging controls.

Fruny: Ftagn! Ia! Ia! std::time_put_byname! Mglui naflftagn std::codecvt eY'ha-nthlei!,char,mbstate_t>

This topic is closed to new replies.

Advertisement