OpenMusic

Visual Programming | Computer-Assisted Composition

Navigation : Previous | Next

Data Boxes

Contents

  1. Use
  2. Adding a Data Box
  3. Editing the Content of a Box
  4. Connection to Another Box

Data boxes are the simplest of all OM boxes. A data box represents a constant value. This value belongs to one of the primitive Lisp types, which are available in the OM Kernel / Lisp package.

Use

A data box is designed to pass data to other boxes in a patch. It is made of a text field that expresses a value or a text, and an output that allows to connect this content to other boxes.

—|—

Primitive Lisp Types

There are several primitive Lisp types :

any type of numeric data

a list of any type of item between parenthesis

—|—|—|—

an integer number

a text between double quotes - inverted commas -

decimal number

the Lisp expression for “true”

a/b

the Lisp expression of “false” or “nothing”

Adding a Data Box

Typing Directly In the Patch Editor

Cmd click in the patch editor and type a content - for instance 4, (2 3 4), “hello”, etc. - directly in the text prompt.

—|—

Menus Or Library Window

Note

A data box accepts any primitive type, no matter what its type was initially.

Editing the Content of a Box

Double click on a box to edit its content.

—|—

** To confirm the input value, press Enter or click in the patch editor. ** **No line return is allowed in data boxes. **

Resizing

To fit the box size to its content, select it and type i.

Connection to Another Box

Click on the outlet to create a connection and drag it to the wanted inlet of another box.

Connecting a simple value box to the pitch inlet of a "note"
box.

Connecting a simple value box to the pitch inlet of a “note” box.

—|—

Automatic Connection

To add a connected data box to a factory or function box, SHIFT click on an input. This data box will have the default value of the input, which will then be displayed permanently.

—|—

References :

Contents :

Navigation : Previous | Next