Author Topic: Sound Engine  (Read 1258 times)

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Sound Engine
« on: December 28, 2010, 02:08:11 PM »
Even if the topic has been discussed before I do hope you will forgive me for bringing it up again.

Obviously Star Trek has sound in space and other lovely effects. My question and discussion is how will sound be handled in the game and what support will be given to those with special setups such as HDMI 7.1, Dolby Digital Live, and of course multichannel setups?

Is OpenAL used?

(Just in case you don't know what I am talking about folks)

http://en.wikipedia.org/wiki/Surround_sound
http://en.wikipedia.org/wiki/Dolby_Digital
http://en.wikipedia.org/wiki/HDMI
http://en.wikipedia.org/wiki/OpenAL

It may seem like small potatoes to some. However, for those of us with home theater like setups the lack of attention to the sound engine in many games has been quite the source of frustration. For instance many games seem to not use http://en.wikipedia.org/wiki/Dolby_Pro_Logic Pro Logic making it difficult for those without optical or HDMI setups to use multichannel.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #1 on: December 28, 2010, 02:43:55 PM »
That's actually a pretty good question, I would assume that it would depend on your hardware, but the game should simply be able to generate the different channels and pass them onto the sound card and let it decide how to encode them for your receiver.
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #2 on: December 28, 2010, 03:27:48 PM »
It isnt that simple. How do you generate the signal? How do you manage volume, distance, doppler, etc...
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #3 on: December 28, 2010, 04:56:04 PM »
It isnt that simple. How do you generate the signal? How do you manage volume, distance, doppler, etc...

Isn't that all part of OpenAL?
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #4 on: December 29, 2010, 07:17:09 AM »
Isn't that all part of OpenAL?

It is if OpenAL and its full feature set it being used that is.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Michael

  • aka NanoByte
  • Admiral
  • ****
  • Posts: 1928
  • Cookies: 59
  • VFX Leader
Re: Sound Engine
« Reply #5 on: December 30, 2010, 02:12:34 AM »
irrKlang is the Sound Engine we are using..... http://www.ambiera.com/irrklang/

It seems robust enough to suit all our needs... if not we can use DirectSound as well.
MB: GIGABYTE GA-X48-DQ6 775 X48 RT
CPU: Intel Core2 Duo E7500 Wolfdale 2.93GHz 3MB L2 Cache
GFX: SAPPHIRE Radeon HD 3870 512MB 256-bit GDDR4 PCI Express 2.0 x16
RAM: CORSAIR DOMINATOR 2GB (2 x 1GB) DDR2 1066 Dual Channel Kit
HDD: Seagate Barracuda 7200RPM 500GB X 2 in SATA RAID 0 Config

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #6 on: December 30, 2010, 01:43:14 PM »
irrKlang is the Sound Engine we are using..... http://www.ambiera.com/irrklang/

It seems robust enough to suit all our needs... if not we can use DirectSound as well.

It does seem to have a good number of features and has linux support.

However does Wine not have support for the DirectSound API considering many games use it? My worry (considering yall have mentioned willingness to work to get linux to work in the past) Is that Wine will not properly use the calls from the irrklang engine designed to work with windows.

Of course the huge issue is that after Vista hardware acceleration for Directsound directly is out. However

http://en.wikipedia.org/wiki/DirectSound

Quote
As of 2007, a solution to re-enable hardware acceleration of DirectSound3D and Audio Effects, such as EAX, called Creative ALchemy was launched[3]. Creative ALchemy intercepts calls to DirectSound3D and translates them into OpenAL calls to be processed by supported hardware such as Sound Blaster X-Fi and Sound Blaster Audigy. For software-based Creative audio solutions, ALchemy utilizes its built-in 3D audio engine without using OpenAL at all.

Realtek, a manufacturer of integrated HD audio codecs, has a product similar to ALchemy called 3D SoundBack. C-Media, a manufacturer of PC sound card chipsets, also has a solution called Xear3D EX, although it works instead by intercepting DirectSound3D calls transparently in the background without any user intervention.

In my opinion I think that is a very good option providing lots of flexibility for lots of platforms and sound systems. Especially as EAX like systems exist on many dedicated sound cards and realteks.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #7 on: December 30, 2010, 02:15:15 PM »
Actually. When I think about it.. I have an idea.

Is there any way to have sound handled externally from the main engine? If that was a case and there was some kind of API or whatever in (Sorry I am quite bad at programming lingo) perhaps an external program could use the data to create the sound in real time.

Say if the program is running under Wine in linux. A dedicated irrklang or OpenAL or whatever engine can run on linux (or mac) itself providing access to the well written audio systems on those platforms. Also it is a great new way for mods to improve the overall experience in my opinion.


Oh please do take my posts on this subjects as mere opinion please. Y'all are obviously expert programmers. I have just seen how much chaos sound can be and would like to continue to discuss it if the team has not locked in the decision as final.

---------------------------

For those a bit confused I figure you are saying "Wait isn't 3D rendering much more difficult than sound?" Well the main issue with 3D on linux or other platforms is making sure their drivers are turning your game into a glitchy mess. With sound however there is a SERIOUS issue.

Even on windows you have multiple sound systems at work. None of them are fully comparable and are full of issues. And the experience you get with one sound card can be COMPLETELY different from another.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #8 on: December 31, 2010, 10:22:54 PM »
Again devs feel free to tell me to STFU if this topic is getting annoying or the decision is final.

I found an interesting interview on STO's development while of course STO and Excalibur are VERY VERY different games I did find his points quite interesting

I quote http://www.hardwareheaven.com/interviews.php?interviewid=20

Quote
Does the game engine allow use of hardware acceleration for sound such as EAX for Creative users?
Greg Thompson - Audio Engineer:
We are using FMOD middleware for our audio engine.  FMOD has support for "hardware acceleration", however, for compatibility reasons, we do all audio rendering in software (on the CPU).

FMOD does pretty much everything that EAX does, and does not require proprietary hardware to achieve the same effect. Therefore the advantage to using FMOD is that it runs on every system, not just on systems with Creative cards that support EAX, which constitute a very small percentage of users (the vast majority are simply using on-board audio – RealTek or some other non-Creative hardware).

EAX is primarily about DSP FX (e.g., reverb, echo, flange, distortion) happening on the hardware.  FMOD supports what we need for that, and the performance cost on modern systems is fairly minimal on the CPU.  We also have to support XBOX, PS3 and potentially other game platforms, so FMOD’s cross-platform capabilities are a big plus.

So regardless of your audio hardware (or gaming platform) you will get an EAX-like audio experience. :-)

However I have to disagree somewhat. I notice in STO that distant battles have no sound not extremely low as they ought to be. This could be a very real limitation of software based sound rendering. Or is it?

The "player" ship is mainly the Excalibur and it seems to be able to launch a great many shuttles and fighters. Enemy ships have bays. I don't know if the goal is to have quite a few ships on screen at once but if some dont get sound or dont get all their sound.. Those with powerful systems could notice. Not a very big issue I just hope that aspect gets tested well if the sound engine is going to be bolted into Evolved.

Want to know what kind's of serious sound power people have these days? Try http://www.guru3d.com/article/sound-blaster-xfi-titanium-hd-review/ Normally I hate Creative with a passion. (Horrific non X-fi drivers) however with standardized X-Fi drivers and THX effects that many reviews are saying as mind blowing (Such as highly effective headphone surround sound) Even I am curious... Some cards even come with headphone amplifiers! (Designed to run 3-4 hundred USD headsets with over 100 impedance)

Currently I am running a Turtle Beach Montego DDL. I have to admit it was built around its Dolby Digital Live technology which was rather rare back then and not around analog audio. When I was running my home theater setup it did well. However lack of any surround effects for the headphones or stereo has me looking for its replacement.

Sorry if you explained this before Nano but are you using this irrKlang engine in NanoFX 1.6? I found it weird when I saw ffdshow rendering the Mp3 when I normally have it set to just handle decoding the Dolby digital stream from over the air Digital TV.

Perhaps to have some use to this topic. What sound card(s) and systems are you using folks? If you don't know and just have it hooked up to the back of the PC instead of a card you likely have onboard meaning likely no EAX ability. I only have old EAX 2 and I don't think I can even use it because I use Windows 7 and its different audio stack as opposed to XP.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Michael

  • aka NanoByte
  • Admiral
  • ****
  • Posts: 1928
  • Cookies: 59
  • VFX Leader
Re: Sound Engine
« Reply #9 on: January 01, 2011, 04:03:23 PM »
I'm thinking irrKlang is similar to FMOD where it is software rendered on the CPU... meaning everyone can experience the effects that irrKlang renders.  Just like DirectSound (which the NanoFX viewer is using), it can position sounds based on a 3D position.  DirectSound Translates that across your audio channels appropriately... thus producing Surround Sound.

I don't think we'll worry too much about this yet guys, our approach on this is similar to the 3D Graphics... start off basic and build on it until it's near perfect.  For now we'll have basic 3D sound and can build in the Sound Render Effects that irrKlang provides later such as doppler for fast moving objects passing the camera.  Above all, just like the Graphics looking like the show, we want the Sound to sound like the show as well (ie the Galaxy whipping by the camera at high warp with the doppler whoosh sound).

I used to have a Sound Blaster Audigy 2 ZS but it started crackling on me... it was a sad day when I had to stop using it.  Now I am just using onboard audio.... as I don't have a surround sound speaker setup anymore either.... one day I'd like that again... but not for now... lol
MB: GIGABYTE GA-X48-DQ6 775 X48 RT
CPU: Intel Core2 Duo E7500 Wolfdale 2.93GHz 3MB L2 Cache
GFX: SAPPHIRE Radeon HD 3870 512MB 256-bit GDDR4 PCI Express 2.0 x16
RAM: CORSAIR DOMINATOR 2GB (2 x 1GB) DDR2 1066 Dual Channel Kit
HDD: Seagate Barracuda 7200RPM 500GB X 2 in SATA RAID 0 Config

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #10 on: January 02, 2011, 01:55:12 PM »
You can no longer use older sound blasters including the Audigy series due to terrible drivers. However the X-Fi series seems to have better drivers these days.


No offense but I do not consider the DACs on Onboard audio to be good enough to do more than drive cheap HP speakers or Coby headphones. So if somehow Nano you end up leading the sound part as well let me send you my current Turtle Beach card as it has much better multichannel DACs and dolby digital live so you can test on a receiver if you wish.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Michael

  • aka NanoByte
  • Admiral
  • ****
  • Posts: 1928
  • Cookies: 59
  • VFX Leader
Re: Sound Engine
« Reply #11 on: January 02, 2011, 01:57:47 PM »
lol, we'll see...  I would probably end up getting an X-Fi down the road.  I miss playing with my Soundbanks and Midi as well, that used to be another one of my computer hobbies.
MB: GIGABYTE GA-X48-DQ6 775 X48 RT
CPU: Intel Core2 Duo E7500 Wolfdale 2.93GHz 3MB L2 Cache
GFX: SAPPHIRE Radeon HD 3870 512MB 256-bit GDDR4 PCI Express 2.0 x16
RAM: CORSAIR DOMINATOR 2GB (2 x 1GB) DDR2 1066 Dual Channel Kit
HDD: Seagate Barracuda 7200RPM 500GB X 2 in SATA RAID 0 Config

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #12 on: January 02, 2011, 02:09:11 PM »
lol, we'll see...  I would probably end up getting an X-Fi down the road.  I miss playing with my Soundbanks and Midi as well, that used to be another one of my computer hobbies.

If you do spring for one that Titanium HD looks good. Especially with replaceable OPamps.

The sub 100 USD ones I don't know about if I find some that look good I will post them here (Thankfully there are tons of reviews out there)

That 3870 can send perfect 2 channel PCM along an HDMI route BTW. Sadly tho there is no way to have any surround sound emulation doing that.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #13 on: January 02, 2011, 04:33:51 PM »
You can no longer use older sound blasters including the Audigy series due to terrible drivers. However the X-Fi series seems to have better drivers these days.


No offense but I do not consider the DACs on Onboard audio to be good enough to do more than drive cheap HP speakers or Coby headphones. So if somehow Nano you end up leading the sound part as well let me send you my current Turtle Beach card as it has much better multichannel DACs and dolby digital live so you can test on a receiver if you wish.

I can't say i've ever had a problem with on board audio, the quality seems to be sufficient for everything I do, which includes gaming and watching Blu Rays.
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #14 on: January 02, 2011, 07:06:48 PM »
I can't say i've ever had a problem with on board audio, the quality seems to be sufficient for everything I do, which includes gaming and watching Blu Rays.

What sound system do you have? There is a VAST difference between headphones and speakers optical and analog.

For instance if your setup with optical out that is perfectly clear audio until it reaches the receiver or DAC. However for a PC motherboard they have to push as much as they can for as cheap as they can into as little size as they can. As a result the chip dong all this work is usually a little deal on the motherboard with a bunch of traces. No external opamps no external ram etc... For digital that is fine for analog.. ya not great.

There is a reason I am offering to send a developer a 50USD card. A good chunk of the Star Trek experience is sound. How many times have you seen the experience ruined from a worn out tape washing out the Phaser and warp effects? And then what happens? You get used to it. I saw that full force when I saw an old TV show appear at hulu. I watched it when I was much younger as a 56k video steaming from a site. The audio was horrific but I got used to it. The Hulu version blew me away and I am sure I would be blown away again with a proper high ohm headphone set.

You can't frak that part up! It will cause harm to the experience and that will cause the effects the graphical department created to be less of a punch. Even worse the engine itself will likely see far more craft on screen than the old Bridge Commander in my opinion. That is going to put stress on any engine and the usual solution is just to cut off sounds from a certain distance. However, If it is possible I want to be able to hear sound from very distant fights. Even mixed into a massive battle. Doing that in software mode is going to be interesting but I do trust Nano when he says he wants the sound to be like the show.
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #15 on: January 02, 2011, 07:20:01 PM »
Well I've got the Logitech Z-5500 as it says in my forum sig, hooked through coax audio from the motherboard (the only reason I'm not using optical is that the receiver only has one port and the Xbox 360 and PS3 can only do optical), which uses a Realtek audio chip, can probably find out which one specifically if you want. I also use a pair of Creative Fatal1ty headphones when there are people home, since the Z-5500 is capable of shaking the walls if turned up too loud. The headphones are hooked though the Logitech system, which handles the muxing down from 5.1 to 2.0, I could have gotten one of those faux 5.1 headsets, but I've never heard one do convincing audio, and they usually have problems with either high end or low end.

If you want my opinion about audio in game, then I'd suggest reducing the high end on any distant audio, make it mostly bass, since that's the sort of sound that carries the best over distance anyway.
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #16 on: January 02, 2011, 07:37:13 PM »
Ouch I fail at reading sigs....  #loveFFX#

What do you mean by coax audio tho? SPDIF or digital audio can use a single RCA jack or Optical so it is a tad confusing.

If you name your mobo I can look for you. It matters little tho. Modern Realteks are somewhat better from about 2 years ago.

I have respect for using Logitech.. Without a doubt my parents 2.1 Logitechs are the best dedicated computer speakers I have EVER heard. However, I am stunned if you are meaning that you are tolerating mobo analog audio 300 USD speakers from a Realtek?! Blasphemy!

Solution to your optical http://www.amazon.com/Nyrius-SW100-Digital-Selector-Compatible/dp/B000812QC6/ (Then again you may be saying you want to use them at the same time in which case that isnt a good idea to mix optical)
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #17 on: January 02, 2011, 07:53:26 PM »
Quote
If you name your mobo I can look for you. It matters little tho. Modern Realteks are somewhat better from about 2 years ago.

Quote
Ouch I fail at reading sigs....

lol, mobo's the first one in the sig.

Quote
What do you mean by coax audio tho? SPDIF or digital audio can use a single RCA jack or Optical so it is a tad confusing.

SPDIF through an RCA cable, so digital audio.

I'd considered getting a switch, but I don't really have a need for one, the coax audio from the PC has never given me any problems, and I can swap the optical cable between the other two, since they're not on at the same time (I also use the same HDMI cable for both, cbf getting another one).
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64

Offline Zachstar

  • Lt. Commander
  • ****
  • Posts: 190
  • Cookies: 0
  • Member
Re: Sound Engine
« Reply #18 on: January 02, 2011, 08:09:25 PM »
Yep that shows I need sleep.  :P Failed again

Yes that is SPDIF same with coax as with optical so sorry for the big soap boxing. Other than lack of any DSP effects and all that jazz you are getting crystal clear 2.0 audio it is the little tiny crappy DACs in the mobo I do not like the DACs in Logitechs are quite good.

What you could use a good card for tho is achieving full digital separation of audio by analog from a a good card.  Have you considered getting one?

Edit: Realtek ALC889 Is that mobo's sound. Top of the line Realtek. And it also says it supports DTS connect.. Have you ever tried that? (That likely requires proper drivers rather than Windows autodetect ones.)

Link to the Realtek page http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=28&Level=5&Conn=4&ProdID=173
« Last Edit: January 02, 2011, 08:16:43 PM by Zachstar »
Phase Blasters, Rail Torpedoes Full Spread! FIRE!

Offline Black Patriot

  • Admiral
  • ****
  • Posts: 1019
  • Cookies: 3
  • Member
Re: Sound Engine
« Reply #19 on: January 02, 2011, 08:32:13 PM »
It'll do full 7.1 apparently, don't have a 7 speaker setup so I can't test it, but the 5.1 works fine. The drivers i've got at the moment don't seem to have an option for DTS, so I probably do need different ones, though the last time I tried to manually update the audio drivers (it was only a few days ago actually) I ended up with no sound whatsoever, had to roll back the drivers and let Windows install what it wanted.

I had looked into some cards, there's one from Creative that's designed to work with the headset I've got, but it'd mean moving the headset from the PC to the receiver whenever I wanted to listen to something else, unless I did a somewhat dodgy interconnect between the consoles and the PC, which doesn't sound like a good idea. At the end of the day I'm simply not sure what benefit I'd really get over the onboard audio, as you said it's already one of the top of the line chips from Realtek.
Gigabyte GA-X58A-UD3R
Intel Core i7-950 @ 3.6 GHz
12GiB G.Skill RAM
Gigabyte GTX 680 2048MB
128GB Kingston SSD (Windows 7 Drive)
64GB Kingston SSD (Windows 8 Drive)
2 x 160GB 7200rpm HDD (RAID 0)
8.2TiB Storage (on File Server)
875W Thermaltake ToughPower XT PSU
46" Samsung Series 6 LED @ 1080p
Logitech Z-5500 THX
Windows 7 Professional x64
Windows 8 Consumer Preview x64