Home › Forums › Breakaway Audio Enhancer › Two questions, please
- This topic has 5 replies, 2 voices, and was last updated 16 years, 7 months ago by Leif.
-
AuthorPosts
-
April 7, 2008 at 2:28 pm #23AnonymousGuest
Hello. My two questions are:
(1) Can you please say more about how the planned Vista-specific version will differ from the existing version?
(2) Why are there two instances of breakaway.exe running (according to Task Manager)?
Many thanks
April 8, 2008 at 2:09 am #3975LeifKeymasterHi Brian!
1) Certainly! The Vista version, if all goes right, will implement its audio back-end as an APO. This way it will essentially get invited in to process the audio along the path to your sound card, instead of having to elbow itself in the way it does now.
The current version implements a virtual sound card (Breakaway Pipeline) and just has all windows apps use that, and then Breakaway is responsible for processing the audio and sending it to the real sound card. This works fine in XP (and it is the best and only way there), but in Vista, doing an APO is a much cleaner solution, and will work better.
2) I’m surprised nobody has asked this before!
Due to the Windows architecture (all versions), it’s impossible to have a Normal Priority thread, and a true Realtime Priority thread (priority 31), in the same process (instance).
So, in order to get the low latency audio engine stable enough, I had to very painstakingly write the code to support Breakaway running in two different processes, while communicating with one another. One of them is the audio engine, and the other is the user interface. You can easily find out which is which by maximizing the Breakaway window, and looking in Task Manager. The one that uses the most memory then, is the user interface.
If you don’t like having two processes, you can easily disable this feature. In Breakaway, go to the Settings, and uncheck "Audio Realtime Priority". That’s it.
When you uncheck Audio Realtime Priority, the audio engine will run as a Time Critical thread (priority 15), not true realtime, and thus the requirement for a second process goes away.
For reference, the Normal thread priority is 8.
Why should the audio engine run at such a high priority?
It comes down to this — if the system is completely clogged for just a moment, which thing gets to go first? Should it be the hard drive, the mouse pointer, or the audio?I pick the Audio, because any tiny drop-out (even if it’s just a millisecond!) is very audible and distracting, but having the mouse pointer (extreme example) freeze for a millisecond is completely imperceptible.
///Leif
April 8, 2008 at 8:58 am #3976AnonymousGuestThanks very much for this full and helpful reply. Two followup questions, please:
(1) What is your timeframe for developing the Vista version? I like the quality of the results from the current version, but I don’t feel too comfortable with the way it interfaces with the Windows sound system, as you have described it.
(2) In Vista and with my sound card (SigmaTel High Definition Audio), various enhancements are natively available in the Windows Sound playback config, e.g. bass management, room correction. A choice of output formats is also supported (I prefer 24 bit, 48000Hz). Will the Vista version of Breakaway bypass my chosen playback device, or will it pass the sound through it, as the current version appears to do?
Many thanks once again.
April 8, 2008 at 11:14 am #3977LeifKeymasterHi Brian!
No problem, thank you for the good questions 😉.
For timeframe, I’m not quite sure. The Winamp versions are ahead on the priority queue (although they’re not very difficult to do, I’ve done many Winamp plug-ins before). Vista programming, however, is completely new territory for me, and may take a while. I’m still debating whether I will actually be able to put up with Vista on my main work machine, or whether I should stick with XP on it.
So, I can’t promise a timeframe yet, because I simply don’t know myself. However, it shouldn’t take too many months.
I have no reason to believe that the native enhancement wouldn’t be available simultaneously. The native enhancements are in fact done as APOs, so basically Breakaway should just be added to the list. That’s how I hope it will work, anyway.
Breakaway will most likely be able to use any format you select.
The current version of Breakaway does not in fact bypass the chosen device. When installing, your currently selected sound card will be the default selected in the Breakaway wizard, and this is indeed the card that will be used for output.
Unless you want to play surround sound (more than 2 channels), there’s really no reason to be afraid of the current version in Vista – if it works reliably on your system, you can really just use it as is.
While the current version uses older Windows technologies (Kernel Streaming if available, WaveIn/WaveOut otherwise), there’s several pieces of code in place to ensure that it does run on Vista as well.
///Leif
April 16, 2008 at 2:40 pm #3978AnonymousGuestI see you’ve said in another forum thread (in response to Arieli) that you’re now giving top priority to making standalone Breakaway more Vista-compatible. That’s good news! But then you also say that you may do this by enabling DirectSound. I don’t understand that – I thought DirectSound no longer exists in Vista’s revamped sound architecture. Please enlighten me! Many thanks.
April 16, 2008 at 4:14 pm #3979LeifKeymasterHi Brian!
Yes – as a stopgap measure. A true vista version (using an sAPO) is technically a better solution, but it’s completely new territory for me, and thus will take too long. Better to make the current version more vista compatible – that way it will work properly for vista users, while I go back into the lab and take the time it needs to do it the "right way"(tm).
DirectSound is emulated in Vista, as is WaveIn/Out.
Breakaway’s currently biggest problem (the huge latency in Vista) comes from the fact that Microsoft made the WaveIn/WaveOut emulation intentionally awful in vista, to "encourage" people to use a more modern interface. That does make sense – WaveIn/WaveOut is very very old (1991 or so), whereas DirectSound is a little bit newer, released around 1996 if I remember correctly, and more suited for realtime audio.
I’ve never actually learned to use DirectSound before. I’ve used WaveIn/WaveOut (because it has worked perfectly up to and including XP), and when I needed lower latency, I started using Kernel Streaming (which is even faster and more stable than DirectSound). Breakaway uses Kernel Streaming if it’s available — the problem is that it isn’t available at all on most Vista systems, leaving Breakaway to resort to the only other interface it currently knows — WaveIn/WaveOut.
Writing a DirectSound object and making Breakaway use it will be much easier and faster than doing an sAPO as that requires redoing the whole structure from scratch. So, it seems to be the optimal order to do things, to bring the most happiness (in the form of good audio) to the greatest number of people possible, in the least amount of time 😉.
We’re also working on getting the pipeline driver signed, so that Breakaway will be able to run in Vista64 too. Stay tuned 🙂.
///Leif
-
AuthorPosts
- You must be logged in to reply to this topic.