Hiss, Buzz, Hum: Using Noise and Complex Synthesis in JMusic

In the previous section, we created a musical instrument by connecting a sawtooth wave oscillator to a low-pass filter. We then used it to play a short musical phrase. To make richer, more interesting sounds, we will need to use a number of different audio components and combine the sounds from them. A very common way of combining sound elements is to simply add the results as if the sounds were being played simultaneously. In this first example, we create a square wave oscillator ...

Get Wicked Cool Java now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.