Must multimedia players check the message queue and invoke DispatchMessage?

Juan Lang juan.lang at gmail.com
Tue Mar 22 11:52:44 CDT 2011


> None of Wine's MCI drivers do.
(snip)
> Who could shed some light?

Have you looked at any open source MCI drivers?  They may or may not
be of the best quality, but at least one exists in my brief perusal:
the MediaXW package,
http://sourceforge.net/projects/mediaxw/

> What do you mean exactly by "message pumping"? There are a few places in Wine
> that call PeekMessage e.g. MCI_DefYieldProc, MMSYSTEM_MidiStream_MessageHandler,
> but to me it looks like an error when that is not accompanied by DispatchMessageA/W
> of all the messages that the local handler does not understand.
> I'd expect DispatchMessage, not PeekMessage to invoke all the callbacks.
> Isn't it an error for all loops executing on the app's thread?

It's a broad topic, but yes, basically you want to call
DispatchMessage on some messages periodically.  See e.g.
MsgWaitForMultipleHandles.
--Juan



More information about the wine-devel mailing list