Getting Started

Hello, sinetone!!



In timbre.js, programming is performed by combining the T-Object generated by T() function. T-object type is specified by a string as the first argument of the T-function. Below is a simple example of generating a sine wave. Sound is heard? Next, re-run after changing to saw from sin. You will hear different type of sound (sawtooth wave).

The second argument specifies properties in the form of a dictionary. In the following example we set to play 880(Hz) the property of the sin-oscillator frequency.

set() is if you will specify properties later. In fact, the dictionary of the second argument is internally calling this method. The following example is almost the same as in the previous example.

Subsequent arguments are input objects. Most T-object is added to the value of input objects in front of its own processing. For example, an envelope object outputs the values that multiplied by values of input objects. In the following example,


The basic processing flow of the T-object