Home > Articles > Programming > Games

This chapter is from the book

Types of Music within Games

Composers can use music in many different ways within games to achieve the desired emotional effect. In this section we begin by defining the categories of music used within video games. In the next section you’ll learn about the function of music in games.

Sometimes as composers we’re adding music to support the game on an emotional level (extra-diegetic). At other times we’re adding to what the avatar of the player might be hearing as part of the game universe. It’s useful to define these different types of music in terms of function.

Extra-Diegetic Music (Underscore)

Extra-diegetic music, or non-diegetic music, refers to music that is added to a scene purely to enhance the emotions that the player should be feeling. This is commonly known as underscore. The musical ensemble or device that plays this music is not established to the player in the game. Its existence is not even inferred in the game world. Underscore works on a subconscious level to bring story elements together in its use of themes and motifs, as well as to intensify the emotional context of a scene. It also may inform the player or viewer of something that might be off-screen. Extra-diegetic music also helps with setting the stage by implying a specific time in history or a place within the world. With extra-diegetic music, the viewer does not expect to see the instruments on the screen playing the music.

It is commonly said that the best film scores are not noticed by the audience or viewer. More obvious (and clumsier) scores take the viewer out of the experience of watching a movie by bringing what should be an unconscious element to the forefront for the listener.

A classic film example is John Williams’s two-note motif from Jaws (1975). Whenever there is impending danger of the shark, the audience hears this motif. Later in the film, even though the shark is not on screen, this motif builds tension for the viewers because they expect to see the shark soon. Williams is a master film composer, as he actually uses this motif to teach the audience that this music equals an impending shark attack. Later in the film he breaks this mechanic by not playing the two-note motif before the shark’s entrance; when the shark appears, it’s one of the most terrifying moments in the film. Williams uses music to trick the audience into believing something based solely on his use of music, increasing the horror of the film.

In almost any modern video game, we hear extra-diegetic music enhancing the emotional underpinning of the story. In the game Red Dead Redemption (2010), for example, we hear an Ennio Morricone–inspired score as we follow the adventures of a former outlaw in the American frontier. The interactive score changes dynamically as the player goes from scene to scene, and from plot point to plot point. In the game Bioshock (2007), Garry Schyman composes music for an underwater city engulfed in chaos using aleatoric music techniques, along with solo violin passages creating a terrifying but beautiful collage of themes.

Diegetic Music (Source Music)

Diegetic music is music that a character would hear if he or she were actually in the game world itself. In films, we usually refer to this as “source music.” If we see someone on screen playing a violin, we expect to hear the violin. The function of diegetic music function is to enhance the player’s experience. Typically it’s used to increase the realism of the simulated world.

In Bioshock Infinite (2013), there are moments when we see various musical ensembles, including a barbershop quartet. When we see the barbershop quartet on screen and hear them singing, it’s an example of diegetic music.

Another example is from Mass Effect 2 (2010). When the player is standing outside of a nightclub, he hears the music from inside. This is music that the player would be hearing as part of the world itself.

Games like Grand Theft Auto V (2013) and L.A. Noire (2011) are 3D simulations of another world. Both games revolve around a driving mechanic where players drive different vehicles through this simulated world. These vehicles have radios, and players can change the radio station, so the music changes as they’re driving through this world. This is another example of diegetic music.

One last example of diegetic music within games occurs at the beginning of Assassin’s Creed III (2012), when the player is sneaking around a theater while an opera is being performed. We see the actors and musicians, and the music is coming from the universe itself.

In all of the previous examples, the music placement in the speakers is also very important to simulate where the music is coming from. We use real-time panning, equalization, and reverb techniques to simulate the position within the 3D space. As the player moves around this 3D space, the instruments or devices must pan dynamically to simulate the fact that this is a real place.

In many instances, diegetic music is licensed music. Licensed music has been created previously by an artist, and the game publisher must obtain the rights to use this music within a video game. On large games, a music supervisor may coordinate the licensing process by obtaining (and paying for) the relevant rights to the piece of music.

While playing a game, if we see a jukebox or some other music-making device or musician on screen, then we’ll want to hear the music that it creates. The realism of that world or simulation would be broken if we didn’t hear the sound. As composers, it’s critical to be wary of destroying the illusion of a world for the player.

Occasionally the distinction between diegetic music and extra-diegetic music becomes blurred. For example, we might start off listening to diegetic music, but then as the story progresses the same theme can be heard holding emotional elements of the storyline together.

Music as Gameplay

The third classification of music in games is music as gameplay—that is, when the player generates the music in real time as he or she plays the game.

One might consider all interactive music in games to be “music as gameplay,” but the difference here is that the game system is reacting directly to the actions of the player. Most interactive music systems have an indirect relationship to the underlying music system. For instance, when a player makes choices in a game that then affect the state of the character (e.g., explore or combat), the music would change based on those indirect choices. This is not an example of music as gameplay.

Games that use the music-as-gameplay paradigm typically operate on a lower level of detail than state changes in the music. If the game player makes an action that triggers a sound in rhythm or creates a sequence of notes, that would fall into this classification.

Game developers work with composers to devise an overall music system that complements the gameplay, defining the rules of how the music will play on a note-to-note or phrase-to-phrase level.

There are several different gameplay scenarios in this classification, including simulated performance, player-generated music, and rhythm action.

Simulated Performance

Games like Rock Band (2007) and Guitar Hero (2005) use musical controllers to simulate the effect of being in an actual band performing the music. These games typically use licensed music from popular bands and artists. The music in these games is played back depending on how well the player performs in the game. The better the player performs, the closer to the original licensed song the result will be.

Player-Generated Music

In some games, the player creates music dynamically while playing the game. In PaRappa the Rapper (1996), for example, the player is able to direct the lead character to rap. In what is essentially a rhythm action game, the player presses the control in rhythm in a specified order to get the lead character to rap in real time.

Another example of player-generated music is found in the first-person shooter/rhythm action game Rez (2001) from game designer Tetsuya Mizaguchi. In this game, the player creates music dynamically by shooting down geometric shapes in rhythm with the music, triggering musical notes and patterns.

Last, the game Bit.Trip Runner (2010) is a 2D platformer where the avatar runs from left to right at a constant pace. As the player jumps or collects coins in the world, a musical phrase or set of notes begins to play.

Just as we sometimes blur the lines between diegetic and extra-diegetic music, so you could make a case that games like Portal 2 (2011), which allow you to manipulate physical objects in a 3D world that make noise, feature player-generated music.

Rhythm Action

The last category of music as gameplay is rhythm action games. Dance Dance Revolution (1998), Amplitude (2003), and Space Channel 5 (1999) are all examples of rhythm action games. In these games, players listen to the rhythm of the music and then synchronize their actions by either dancing or hitting buttons on a controller in time with the music to gain rewards.

Player Customized Music

Players may also choose to import their own music into a game. The original Xbox 360 release mandated that every game must be made in such a way that you could turn off the musical underscore and replace it with user-chosen content. If the player wanted to hear John Williams’s Superman (1978) theme while he played Halo, for example, the system would allow for that.

To enable users to bring their own music into a game, systems would allow the players to encode music from a CD or flash drive directly to the memory of the console. Then, while playing a game, users could select to hear their personalized music within the game.

Entire games have been built around customized music, including Audiosurf (2008) and Vib Ribbon (1999). These rhythm action games create dynamic game levels built around the music that the player chooses.

Player-customized music is also popular in racing games. The 2012 release of SSX, which is a snowboarding game, allows players to import any music that they want into the game. The game then uses various digital signal processing (DSP)—filters, beat-matching delays, reverbs—remixing on the fly during gameplay to augment and enhance the custom music.

InformIT Promotional Mailings & Special Offers

I would like to receive exclusive offers and hear about products from InformIT and its family of brands. I can unsubscribe at any time.


Pearson Education, Inc., 221 River Street, Hoboken, New Jersey 07030, (Pearson) presents this site to provide information about products and services that can be purchased through this site.

This privacy notice provides an overview of our commitment to privacy and describes how we collect, protect, use and share personal information collected through this site. Please note that other Pearson websites and online products and services have their own separate privacy policies.

Collection and Use of Information

To conduct business and deliver products and services, Pearson collects and uses personal information in several ways in connection with this site, including:

Questions and Inquiries

For inquiries and questions, we collect the inquiry or question, together with name, contact details (email address, phone number and mailing address) and any other additional information voluntarily submitted to us through a Contact Us form or an email. We use this information to address the inquiry and respond to the question.

Online Store

For orders and purchases placed through our online store on this site, we collect order details, name, institution name and address (if applicable), email address, phone number, shipping and billing addresses, credit/debit card information, shipping options and any instructions. We use this information to complete transactions, fulfill orders, communicate with individuals placing orders or visiting the online store, and for related purposes.


Pearson may offer opportunities to provide feedback or participate in surveys, including surveys evaluating Pearson products, services or sites. Participation is voluntary. Pearson collects information requested in the survey questions and uses the information to evaluate, support, maintain and improve products, services or sites, develop new products and services, conduct educational research and for other purposes specified in the survey.

Contests and Drawings

Occasionally, we may sponsor a contest or drawing. Participation is optional. Pearson collects name, contact information and other information specified on the entry form for the contest or drawing to conduct the contest or drawing. Pearson may collect additional personal information from the winners of a contest or drawing in order to award the prize and for tax reporting purposes, as required by law.


If you have elected to receive email newsletters or promotional mailings and special offers but want to unsubscribe, simply email information@informit.com.

Service Announcements

On rare occasions it is necessary to send out a strictly service related announcement. For instance, if our service is temporarily suspended for maintenance we might send users an email. Generally, users may not opt-out of these communications, though they can deactivate their account information. However, these communications are not promotional in nature.

Customer Service

We communicate with users on a regular basis to provide requested services and in regard to issues relating to their account we reply via email or phone in accordance with the users' wishes when a user submits their information through our Contact Us form.

Other Collection and Use of Information

Application and System Logs

Pearson automatically collects log data to help ensure the delivery, availability and security of this site. Log data may include technical information about how a user or visitor connected to this site, such as browser type, type of computer/device, operating system, internet service provider and IP address. We use this information for support purposes and to monitor the health of the site, identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents and appropriately scale computing resources.

Web Analytics

Pearson may use third party web trend analytical services, including Google Analytics, to collect visitor information, such as IP addresses, browser types, referring pages, pages visited and time spent on a particular site. While these analytical services collect and report information on an anonymous basis, they may use cookies to gather web trend information. The information gathered may enable Pearson (but not the third party web trend services) to link information with application and system log data. Pearson uses this information for system administration and to identify problems, improve service, detect unauthorized access and fraudulent activity, prevent and respond to security incidents, appropriately scale computing resources and otherwise support and deliver this site and its services.

Cookies and Related Technologies

This site uses cookies and similar technologies to personalize content, measure traffic patterns, control security, track use and access of information on this site, and provide interest-based messages and advertising. Users can manage and block the use of cookies through their browser. Disabling or blocking certain cookies may limit the functionality of this site.

Do Not Track

This site currently does not respond to Do Not Track signals.


Pearson uses appropriate physical, administrative and technical security measures to protect personal information from unauthorized access, use and disclosure.


This site is not directed to children under the age of 13.


Pearson may send or direct marketing communications to users, provided that

  • Pearson will not use personal information collected or processed as a K-12 school service provider for the purpose of directed or targeted advertising.
  • Such marketing is consistent with applicable law and Pearson's legal obligations.
  • Pearson will not knowingly direct or send marketing communications to an individual who has expressed a preference not to receive marketing.
  • Where required by applicable law, express or implied consent to marketing exists and has not been withdrawn.

Pearson may provide personal information to a third party service provider on a restricted basis to provide marketing solely on behalf of Pearson or an affiliate or customer for whom Pearson is a service provider. Marketing preferences may be changed at any time.

Correcting/Updating Personal Information

If a user's personally identifiable information changes (such as your postal address or email address), we provide a way to correct or update that user's personal data provided to us. This can be done on the Account page. If a user no longer desires our service and desires to delete his or her account, please contact us at customer-service@informit.com and we will process the deletion of a user's account.


Users can always make an informed choice as to whether they should proceed with certain services offered by InformIT. If you choose to remove yourself from our mailing list(s) simply visit the following page and uncheck any communication you no longer want to receive: www.informit.com/u.aspx.

Sale of Personal Information

Pearson does not rent or sell personal information in exchange for any payment of money.

While Pearson does not sell personal information, as defined in Nevada law, Nevada residents may email a request for no sale of their personal information to NevadaDesignatedRequest@pearson.com.

Supplemental Privacy Statement for California Residents

California residents should read our Supplemental privacy statement for California residents in conjunction with this Privacy Notice. The Supplemental privacy statement for California residents explains Pearson's commitment to comply with California law and applies to personal information of California residents collected in connection with this site and the Services.

Sharing and Disclosure

Pearson may disclose personal information, as follows:

  • As required by law.
  • With the consent of the individual (or their parent, if the individual is a minor)
  • In response to a subpoena, court order or legal process, to the extent permitted or required by law
  • To protect the security and safety of individuals, data, assets and systems, consistent with applicable law
  • In connection the sale, joint venture or other transfer of some or all of its company or assets, subject to the provisions of this Privacy Notice
  • To investigate or address actual or suspected fraud or other illegal activities
  • To exercise its legal rights, including enforcement of the Terms of Use for this site or another contract
  • To affiliated Pearson companies and other companies and organizations who perform work for Pearson and are obligated to protect the privacy of personal information consistent with this Privacy Notice
  • To a school, organization, company or government agency, where Pearson collects or processes the personal information in a school setting or on behalf of such organization, company or government agency.


This web site contains links to other sites. Please be aware that we are not responsible for the privacy practices of such other sites. We encourage our users to be aware when they leave our site and to read the privacy statements of each and every web site that collects Personal Information. This privacy statement applies solely to information collected by this web site.

Requests and Contact

Please contact us about this Privacy Notice or if you have any requests or questions relating to the privacy of your personal information.

Changes to this Privacy Notice

We may revise this Privacy Notice through an updated posting. We will identify the effective date of the revision in the posting. Often, updates are made to provide greater clarity or to comply with changes in regulatory requirements. If the updates involve material changes to the collection, protection, use or disclosure of Personal Information, Pearson will provide notice of the change through a conspicuous notice on this site or other appropriate way. Continued use of the site after the effective date of a posted revision evidences acceptance. Please contact us if you have questions or concerns about the Privacy Notice or any objection to any revisions.

Last Update: November 17, 2020