No Time To Play

The state of modern audio libraries

by on Jul.21, 2016, under Opinion

Imagine the following scenario: you’re prototyping a game, and for now all you want is to put a colored box on the screen. It should be a simple function call, right? Wrong. For one thing, you can’t just draw anything you want, it has to come from an external image file. Which is in a complex, multi-layered format that can only be created with large specialized software suites, most of them expensive, and requiring semi-professional knowledge to use at all. Then there’s the code itself: you have to unpack the file, pick only the parts you need from it, and set up the display just so before sending any data to the screen…

Thankfully, various people have created more friendly wrappers, that let you load a 3rd-party image and blit it to the screen with just a couple of function calls. Then you discover that the image format you’re using does not, in fact, work on another operating system, contrary to what the library documentation claims…

A while later, a consortium of vendors releases a portable API that does, in fact, let you draw directly to the screen. Except it takes telling the machine exactly how to line up each pixel so that they form a box, for every color channel separately. And then you have to funnel the resulting data through the pathway described above…

Ridiculous? Absurd? Implausible?

This is the state of audio APIs in 2016, and for some reason nobody sees anything wrong with it. All too often, I just need to play one of a few chimes here and there, and maybe a brief sequence of musical notes in a loop to mark important moments in a game. In the 8-bit era, I could do this by passing a character string to the PLAY statement — a single line of code. And some of those machines only had a lousy beeper. What excuse do we have today? Have computers grown so “advanced” and “sophisticated” that they can’t even express simple goals anymore? In our drive to achieve great things, are we forgetting how to satisfy the most basic of needs?

I’m reminded of the Communist regime in Romania, in the late 1980s — a government that could erect the second-largest building in the world, while increasingly failing to feed its own working people.

You know how they ended, right?

People give all kinds of reasons for the popularity of pixel art and chiptunes among indie game developers. I propose another one: fatigue. Fatigue with the complexity of tools and pipelines designed to allow for drawing millions of polygons a second, and playing sound in a virtual 3D space, lip-synced with the animation of motion-capped NPCs… but nothing less. Folks, we’re just trying to make games, not revolutionize the multimedia landscape… fifth time this century.

Thankfully, graphics are simple to work with these days, whether you’re dealing with 2D image files, drawing APIs or even basic 3D. Only audio is unreasonably hard. And there’s no excuse.

Creative Commons License
The state of modern audio libraries by Felix Pleşoianu is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

:

1 Comment for this entry

  • fluffy

    I totally agree. Even integrated engines like Unreal and Unity make it exceptionally difficult to bring in and play a single audio file. Android API is also stupidly difficult to do things on, because there are a bunch of different audio APIs for different reasons and some of them allow certain kinds of resources but others don’t. Like I still haven’t figured out how the hell to play a sound effect that’s obtained from an arbitrary external source instead of being built as a resource – for those I can only figure out how to use the streaming API which is high-latency and very limited.

    OpenAL is the closest thing I’ve seen to a not-terrible platform-independent audio API and it’s still pretty horrid. And I give up trying to figure out a nice platform-independenet way to just do my own procedural sound mixing…

Leave a Reply

Turn on pictures to see the captcha *

Posts by date

July 2016
M T W T F S S
« Jun   Aug »
 123
45678910
11121314151617
18192021222324
25262728293031

Posts by month