Announcement

Collapse
No announcement yet.

An Audiophile's Guide to BF:BC2

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • An Audiophile's Guide to BF:BC2

    Garandx posted in the forums this audio information on the Battlefield Blog. Its a good read:

    Hi there!
    I'm one of the audio programmers at DICE responsible for the audio tech in Frostbite. We know there are many people out there who care passionately about audio in our games, so we thought it'd be nice to give you some information on how our audio engine works and why we do things the way we do. Hopefully with this information you'll know how to get the most out of the audio in Bad Company on whichever platform you choose to play it on. It's going to get quite technical, but I'll try to summarize each section to make everything crystal clear.

    Background
    When we started building our "Next Gen" engine, Frostbite, we thought about what "Next Gen" would mean for us on the audio side of things. We came to the conclusion that we wanted to be able to use more filters in order to be able to create more dynamic sound behavior, and we wanted the same functionality and result across all platforms we target. This meant doing all the audio processing ourselves. We'd previously used software mixing in BF:1942 and hybrid hardware/software mixing in BF:Modern Combat on the PS2 (to be able to add some filters and 16 more "voices"), but before this point sound in games was mostly just playing back wave forms almost completely unaffected except for volume and pitch alterations. <!--more-->

    This of course meant that we wanted sounds to be able to have an arbitrary amount of filters and submixes in any order, which hardware accelerating audio pipelines simply didn't/doesn't support. We felt confident in the fact that all our target platforms either had moved (Xbox360, PS3) or were about to move (PC) to software-based audio pipelines, instead of having fixed-functionality hardware pipelines (Xbox, PS2, some sound cards on PC), so software mixing was the obvious choice for us.

    So in short, we went down a path that let us do things exactly the way we felt we needed to do it in order to continue to deliver a high-quality, innovative aural experience in our games and I hope you all agree we've succeeded!

    Performance
    Naturally, doing all of the audio processing in software puts the CPU under some extra strain. Since Xbox360/PS3 has fixed hardware and both have multiple cores available to do many things in parallel, you could say this is only an issue for the PC SKU where we may end up having less cores than on console. In Bad Company, all audio processing is performed sequentially on a single hardware thread regardless of platform. For PC this means that a CPU with a higher frequency will help more than one with more cores. But of course, there are other areas of the game that execute in parallel, so having more than 2 cores will help the game in general. This is an area we're constantly looking to improve and the results of our efforts will show up in future titles.

    The bottom line is that as long as your computer lives up to the minimum spec for the game, things will be just fine. If you're on console there's obviously no need to worry about this stuff at all.

    Fidelity
    As is common today, we do all audio processing in 32-bit IEEE floating point (at 48kHz) in order to maintain the highest fidelity possible in the final audio stream we deliver to the platform's underlying audio driver. Our source wave forms are encoded using different codecs depending on what is most optimal for each platform. Those codecs are what affects the quality of the audio that the game produces the most. Once we've passed the audio to the underlying audio driver, any difference in fidelity depends on how that driver mixes our audio in together with other audio streams from other active processes and what gear you have. On PC we convert our audio to 16-bit PCM before sending it to DirectSound instead of relying on DirectSound to do it for us. This is mostly a legacy workaround for compatibility/quality issues with some sound cards, but adding support for more than 16-bit output would result in an invalidation of many years worth of tweaking and tuning done to reliably output quality audio through DirectSound, without any noticeable improvement in final audio fidelity for you guys and a massive increase in QA work for us. I'll dedicate the entire next section to this 16-bit "controversy" so those of you who are already in the know, or simply don't care, can skip it easier.

    As I already mentioned, the gear you listen to the game through will of course affect the audio fidelity. If you're really keen on audio, you will want to either avoid using the internal DAC that is on your sound card (PC) or in your console. This is simple to do, just make sure you use digital audio output! It's only once you need to go from digital to analog (like to the speakers) that you will need to go through a DAC. You'll also want to keep the DAC outside your computer/console to reduce the induction of noise from other components. This could be as simple as using an external sound card (PC) or a hi-fi/surround system (consoles or PC if your sound card supports digital output).

    The next thing to remember is to turn off as much post-processing as possible and make sure you have nice speakers. Any "enhancements" made to the signal after we send it to the audio driver may introduce unwanted artifacts, so turn off "Cinema" modes, "Crispalizers" and such. This goes for sound cards in PCs, home theatre systems and TVs alike. Our sound designers take great care to mix and even master the game thoughtfully, so make sure to select the "Sound System" setting in the audio options screen so that it corresponds as closely as possible to the gear you have! This way the game will adapt its EQ settings and dynamic range to try and make sure the game sounds as clear as possible through your speakers.

    Let's simplify all this down and say that 5.1/48kHz/16-bit will get you the best experience on PC, and on consoles a mid-range sound system will do just fine. The game was made with 5.1 (and stereo) in mind, so there's no need to invest in a fancy new 7.1 system.

    Bit Depth
    I will try to keep this section short, but in doing so I'll have to make it quite technical. In digital audio, bit depth refers to the dynamic range of each sample in an audio signal. So 16-bit PCM gives us a dynamic range of about 96 dB (the simplified formula is 6*bitCount). Don't confuse bit depth with bit rate (number of bits per second) or sample rate, which decides the highest frequency possible to represent as half the sample rate. The human ear typically has a dynamic range of about 120 dB. So our 16 bits won't fully cover the entire dynamic range of the ear. Now if you simply look at the numbers you might feel that since 96 < 120 it would be obvious to want 24 bits (32-bit DACs aren't really used in consumer products) since the dynamic range would be a whopping 144 dB! In reality however, most consumer DACs will have an SNR (Signal-Noise Ratio) below 96 dB and only if you have a really fancy card it'll have an SNR above 96 dB, if you're lucky. And those are measurements done in an optimal environment, not inside your machine! What that means is that you'll start hearing the noise louder than the intended audio signal as it gets that quiet.

    You could of course reason that turning the volume up would make even the quietest signal audible, but consider that even if you might be able to get your sound system to play back a 0 dB FS signal (loudest possible output from a sound card) much louder than 100 dB SPL, you wouldn't be able to stand listening to it for long without your ears hurting. Indeed, around 140 dB SPL would mean painful damage to our ears.

    So OK, getting the quietest 16-bit signal loud enough in your speakers to be easily heard isn't the most difficult thing to do, but noise will not be far behind and what you'd hear would not benefit your gaming experience in any way. In fact, the HDR audio system in Frostbite culls sounds on loudness during processing, so the 96 dB of dynamic range that 16-bit PCM gives us is more than sufficient to represent our final mix. Also worth mentioning is the fact that it's more important to have a larger dynamic range earlier in the audio processing chain. For example, recording in 24-bit has clear advantages over 16-bit because you'll want your source material as detailed as possible. This is also why all our processing is done in 32-bit floating point, it will retain our source material's dynamic range as well as possible throughout all the processing that we subject it to. But once we've mixed and mastered everything down to a single "full scale" audio stream, 16 bits means plenty of dynamic range.

    In short, don't stare yourself blind on numbers on a box with shiny labels, but by all means make sure you have a nice DAC (high SNR) and some nice speakers.

    Hardware Acceleration
    I touched upon this briefly in the Background section, but it's worth clarifying. Hardware acceleration has been trailing the obvious development in how audio is treated in games for years, unlike graphics acceleration that instead has pushed that area continuously forward. Nowadays even GPGPUs suit the needs of contemporary audio processing better than do hardware accelerating sound cards and we're very excited about the opportunities that something like Intel's Larrabee might give us.

    Also, the main benefit that hardware accelerating sound cards has provided to date has been environmental effects, such as reverberation. We believe that we get equivalent or better, more consistent, results from our software solution for a modest CPU cost by today's standards. Even the software APIs available for these cards are lacking in many areas, mainly by retaining the structure of DirectSound that even Microsoft themselves have now abandoned for game development in favor of the more up-to-date XAudio API.

    There's nothing to say these APIs couldn't be updated to support the type of functionality needed for advanced audio processing, but the hardware would really need to approach a more general-purpose processor than what today's cards have and then we're back at Larrabee or simply a regular CPU with more cores.

    In Closing
    Everyone here in the audio department at DICE are very passionate about what we do and on behalf of all of us I'd like to take this opportunity to thank you all for your encouraging comments and interest in audio in our games, be it on the blog, forums or in comments on videos!

    We'll keep an eye on your comments for thoughts that might inspire another post about audio in Frostbite.

    Thank you

    Thanks again Garandx for posting it up. Audio is one of those things that get taken for granted in so many games and our every day lives.

    Source
    Twitter: @CptainCrunch
    Battlelog/Origin: CptainCrunch

  • #2
    Re: An Audiophile's Guide to BF:BC2

    Its a bit confusing
    He mentions digital out as preferred to avoid using the DAC for best fidelity
    So can someone suggest a hardware config based on his reccomendations - assuming all I want is a headset ( no speakers)

    Comment


    • #3
      Re: An Audiophile's Guide to BF:BC2

      Originally posted by [3SA]D|Pvt.Obi
      Its a bit confusing
      He mentions digital out as preferred to avoid using the DAC for best fidelity
      So can someone suggest a hardware config based on his reccomendations - assuming all I want is a headset ( no speakers)
      Auzentech X-Fi Forte -Integrated Headphone amp + X-Fi CMSS-3D Headphones = can't get any better.

      Comment


      • #4
        Re: An Audiophile's Guide to BF:BC2

        *goes and turns off x-fi crystalizer*

        Comment


        • #5
          Re: An Audiophile's Guide to BF:BC2

          Originally posted by [3SA]D|Pvt.Obi
          Its a bit confusing
          He mentions digital out as preferred to avoid using the DAC for best fidelity
          So can someone suggest a hardware config based on his reccomendations - assuming all I want is a headset ( no speakers)
          As I already mentioned, the gear you listen to the game through will of course affect the audio fidelity. If you're really keen on audio, you will want to either avoid using the internal DAC that is on your sound card (PC) or in your console. This is simple to do, just make sure you use digital audio output! It's only once you need to go from digital to analog (like to the speakers) that you will need to go through a DAC. You'll also want to keep the DAC outside your computer/console to reduce the induction of noise from other components.
          Depends on your speakers setup, once you've gone through the DAC through your soundcard you don't want to go through another DAC on your speakers/sound system - and you'll want to turn off all effect processing through either and let the game do the mixing and effects. The rest goes without saying, if you have a poor quality sound experience from extra noise bleeding into your sound output (noisy power supply, poorly made motherboard with cheap components) - You'll have to sort this out. Using 2 speaker setup or a headset I wouldn't waste any extra money changing out your sound card or going with an external one, however having a faster CPU never hurts...

          For PC this means that a CPU with a higher frequency will help more than one with more cores. But of course, there are other areas of the game that execute in parallel, so having more than 2 cores will help the game in general.

          Comment


          • #6
            Re: An Audiophile's Guide to BF:BC2

            so i have xi fi titanium pro, should i turn off the CMSS3d, the xi fi crystilezer and EAX also?

            Comment


            • #7
              Re: An Audiophile's Guide to BF:BC2

              Originally posted by Levente
              so i have xi fi titanium pro, should i turn off the CMSS3d, the xi fi crystilezer and EAX also?
              I would say yes - you'll want to turn it all off, go watch some of the beta footage on youtube. All the positional sound effects are pre-processed by the game.

              Comment


              • #8
                Re: An Audiophile's Guide to BF:BC2

                I think this is a great post.

                It really shows a behind the scenes to developing a game. Some older hardware is no longer supported. This has been the way PC gaming has always been (unfortunately). But now developers are talking about it as a blog. Dual core was created for these kinds of shortcuts, and they are taking advantage. Newish sound cards (plus the built in ones) have architectures that make this ability available to the developer. The developer is taking advantage of this.

                I think audio is the drummer of the video game band. You never really notice it, but when it is good it totally makes the song [game]. And when it's not there it just doesn't feel the same.

                A perfect example is Desert Combat. Desert Combat "Final" introduced a little discussed feature of sound time delay (not new, but well refined in the final release). If artillery (bring it back DICE) was fired and landed far away, you heard it later than when it actually hit. Plus, you heard a different sound from the guy that it landed right next to. You heard a low thud and rumbling. While the guy closer heard a loud bang (and he heard it before you did because he was closer).

                This idea was even brought to machine guns. It was nice to know that sounds you thought were background noise was actually an event happening on the other side of the map.

                So the audio portion can really bring people into the game. And it sounds like instead of just giving you a different wav file for different scenarios, the engine will use your environment to determine which filters to apply the the sound that just happened (e.g. do i make it echo?). And all this requires newer stuff.

                Comment


                • #9
                  Re: An Audiophile's Guide to BF:BC2

                  Originally posted by Levente
                  so i have xi fi titanium pro, should i turn off the CMSS3d, the xi fi crystilezer and EAX also?
                  EAX wont have any effect if you have it turned on, Crystalizer is to your own taste, and CMSS3D do not turn that off in any case.

                  Comment


                  • #10
                    Re: An Audiophile's Guide to BF:BC2

                    why what does CMSS3D do? should i switch to entertianment mode istead of gaming mode?

                    Comment


                    • #11
                      Re: An Audiophile's Guide to BF:BC2

                      it depends if you have a true 5.1 source. CMSS3D is 5.1 emulation out of a stereo source. the game itself will natively output to 5.1 if you have the speakers so you want that turned off.

                      oh and keep it on game mode for all gaming.

                      Comment


                      • #12
                        Re: An Audiophile's Guide to BF:BC2

                        Originally posted by Minmaster
                        it depends if you have a true 5.1 source. CMSS3D is 5.1 emulation out of a stereo source. the game itself will natively output to 5.1 if you have the speakers so you want that turned off.

                        oh and keep it on game mode for all gaming.
                        CMSS-3D Headphones is 8.1 with elevation filter, the surround accuracy is way better than on a 5.1 speaker system if you have proper headphones.

                        CMSS-3D Virtual for 2.1 speakers is a different thing, much worse than a 5.1 system..

                        Originally posted by Levente
                        why what does CMSS3D do? should i switch to entertianment mode istead of gaming mode?
                        Keep it in gaming mode, otherwise you will get CMSS-3D that is meant for music so you will not get proper surround in games.

                        Comment


                        • #13
                          Re: An Audiophile's Guide to BF:BC2

                          i'm talking about CMSS3D for turning stereo source into 5.1 output. it seems to work pretty well actually for stereo music/movies BUT it's not needed for gaming where games like BF and MW are already natively outputting 5.1 (if you choose it to).

                          Comment


                          • #14
                            Re: An Audiophile's Guide to BF:BC2

                            Originally posted by Leopardi
                            CMSS-3D Headphones is 8.1 with elevation filter, the surround accuracy is way better than on a 5.1 speaker system if you have proper headphones.

                            CMSS-3D Virtual for 2.1 speakers is a different thing, much worse than a 5.1 system..



                            Keep it in gaming mode, otherwise you will get CMSS-3D that is meant for music so you will not get proper surround in games.
                            wait cmss-3d is meant for music? i always leave it off for music and keep it on for games. isn't it positional audio so that you can you hear if some is coming from behind or left side? im confused?

                            Comment


                            • #15
                              Re: An Audiophile's Guide to BF:BC2

                              Originally posted by unreal_calibur
                              wait cmss-3d is meant for music? i always leave it off for music and keep it on for games. isn't it positional audio so that you can you hear if some is coming from behind or left side? im confused?
                              Yes in entertainment mode there is CMSS-3D meant for music and movies, and in game mode there is different CMSS-3D meant for games.

                              Comment

                              Working...
                              X