muzgen/doc/guide/quickstart.rst

28 lines
920 B
ReStructuredText
Raw Permalink Normal View History

Quick Start
===========
Hello ! So you want to make some sound design ? MuzGen allows you to
generate some sound using a language named **MuzScript**. Ok, let's
start with a simple example.
.. code-block:: bash
@out [sine 440]
Here, ``@out`` is a *directive* and ``sine`` is a *command*.
Let start with commands. A command is kind of a function. It has a
name followed by its parameters if any.
Here, the command ``sine`` takes one parameter: the signal
frequency. Like its name suggests, ``sine`` is a signal composed of
one sine wave with the given frequency and an amplitude of 1.
.. note::
The parameter ``440`` is not a simple number. In fact,
it's a signals too ! We call this kind of number **constant signal**.
In order to hear our sine wave, we have to specify how we want it to
be played. That is what the directive ``@out`` does. It will play the
followed signal on the default audio device.