Hi,
> I suppose the key point is whether it is possible to: > > - use song iterators just down to the mt32gm mapping level for now Right now, song iterators (are supposed to) fully support song decoding, including looping. No translation has been implemented yet, and neither has serialization or de-serialization. > - still leave room to take the iterators down to device level In theory, you can take them anywhere. What are you referring to with the device level? A native MIDI API? > - and also if there are ports that need the device level right now, or will > very soon > > That is, if there is something out there that will need the device level > now, we may as well go the whole way. Is there? Good question. For MacOS X we need some magic, either an alternative call path for main(), or a sound server based on the PCM callback provided by SDL. I've been working on a second proposal for a sound subsystem, but am not finished yet; this should scale down the complexity of the whole thing a bit more. The current (very incomplete) draft version is at http://darmstadt.gmd.de/~jameson/sound-2, this does not yet include the following: - Transferring messages to a 'track timer' (more bare-bones sound server replacement); my current idea is to implement this (on the API side) by run-time polymorphing the track player and using the current pipe and mutex'd queue implementations for message passing (on the implementation side). - How to implement a 'track timer' based on PCM callbacks (or directly on sound hardware interrupts). Here, message passing becomes a problem because we can't use semaphores; however, since the "interrupt handler" cannot be interrupted by the interpreter, this should be solveable. The obvious advantage is that this approach should map cleanly to any OS-specific MIDI APIs while still providing extensions to increase synchronity between the two song iterators where possible, and that a system without any support for SDL, fork(), or something similar will still get song cue support out of the box. It's main disadvantage is that it hasn't been implemented yet, although I might be overlooking other important disadvantages. Any feedback would be appreciated! llap, Christoph
