Chunk Item Operation

Performs an operation on a chunk, such as modifying, deleting, or clearing items.

Settings

chunk name

Name of the chunk.

In chunk modules, the chunk name is case sensitive. This means that MYCHUNK is not equivalent to mychunk or MyChunk.

item names

Names of the items to retrieve or on which the operation is performed, expressed as a comma-text.

In chunk modules, the item names are case sensitive. This means that item1 is not equivalent to Item1 or ITEM1.
To avoid mismatch between names and RegEx ^, ., $, *, +, ?, (, ), [, ], {, }, \, | are not allowed in the names.

can be a RegEx (Regular Expression)
see regular expression.

  • ^a.* match any string starting by "a"
  • (?i)^a match any string starting by "a" or "A" (case insensitive)
  • .*a$ match any string ending by "a"
  • .*\d$ match any string ending by a number "1","2","3", etc.
  • .at matches any three-character string ending with "at", including "hat", "cat", "bat", "4at", "#at" and " at" (starting with a space).
  • [hc]at matches "hat" and "cat".
  • [^b]at matches all strings matched by .at except "bat".
  • [^hc]at matches all strings matched by .at other than "hat" and "cat".
  • ^[hc]at matches "hat" and "cat", but only at the beginning of the string or line.
  • [hc]at$ matches "hat" and "cat", but only at the end of the string or line.
  • \[.\] matches any single character surrounded by "[" and "]" since the brackets are escaped, for example: "[a]", "[b]", "[7]", "[@]", "[]]", and "[ ]" (bracket space bracket).
  • s.* matches s followed by zero or more characters, for example: "s", "saw", "seed", "s3w96.7", and "s6#h%(>>>m n mQ".
  • [hc]?at matches "at", "hat", and "cat".
  • [hc]*at matches "at", "hat", "cat", "hhat", "chat", "hcat", "cchchat", and so on.
  • [hc]+at matches "hat", "cat", "hhat", "chat", "hcat", "cchchat", and so on, but not "at".
  • cat|dog matches "cat" or "dog".
  • \\ to search the \ char (backslash)

operation

Type of operation to perform on the chunk:

  • add or modify item: modifies the chunk item or adds it if it doesn’t exist.
  • auto add or modify item: modifies the chunk item or adds it automatically if the payload is modified.
  • clear item: clears the content of the item, setting the array size to 0 or the string to NULL.
  • delete item: deletes the item from the chunk. After this operation, the item no longer exists in the chunk.
  • clear chunk: clears the entire chunk, deleting all items.
  • destroy chunk: completely destroys the chunk.

perform

Executes the selected operation immediately.

If the operation is set to auto add or modify item, the operation is performed automatically.

type

Determines the type of the payload: float, integer, string, or color.

index

Index of the payload array on which the operation is performed. Set to -1 for the entire content of the payload.

For floats, integers, and colors, it is the nth element of the array. For strings, it is the nth element of the comma-text.

In chunk modules, the item names are case sensitive. This means that item1 is not equivalent to Item1 or ITEM1.
To avoid mismatch between names and RegEx ^, ., $, *, +, ?, (, ), [, ], {, }, \, | are not allowed in the names.

payload

The content of the chunk item to modify or add.

display errors

Displays various errors that may occur during chunk operations.

Common errors

Type mismatch between payload and stored item If an item already exists as a float and you overwrite it with a different type (e.g., string), the item's type changes silently. Any other module reading that item with the original type assumption will get unexpected values. Keep the type consistent across all modules that read and write the same item.

"Auto add or modify" triggers on every payload change In auto add or modify item mode, the chunk is written every time the payload input changes — including during patch initialization or preset loading. This can cause unintended writes. Use add or modify item with an explicit perform trigger if you need precise control over when writes happen.

"Clear chunk" and "destroy chunk" are global operations Clear chunk deletes all items but the chunk still exists. Destroy chunk removes the chunk entirely. Both operations affect every module in Usine that references this chunk. Use with caution in complex setups.

"Delete item" vs "clear item" Clear item resets the item's content (array size to 0 or string to NULL) but the item still exists in the chunk. Delete item removes the item entirely — any chunk-item-get reading it will report it as invalid. Choose based on whether you want to preserve the item's existence or remove it.

Common Settings

info

show manual

Button. Opens the manual page of the selected object (or of its parent module for a control) in the web browser. If no page exists for this object, an error is traced in the trace panel.

For more details about information/help creation, see create-help-file.

description

Free multi-line text attached to the module, saved with the patch. It is only meant as an internal note for the patch designer: it is not displayed in the interface.

ID's

visible only in god mode, see setup-panel-tab-expert.

unique ID

Read-only, not saved. Current private numeric ID of the object, used internally to identify it (for example as the target of a bind ID).

preset ID

Read-only, not saved. Private ID used to store and recall the values of this control in presets.

recreate ID

Button. Generates a new unique ID, original ID and preset ID for the object. Use it if you experience difficulties in Polyphonic mode or if two objects share the same ID. Preset values and binds referring to the old IDs are lost.

Object Remote Address

absolute

Read-only, not saved. Absolute address of the object in the Usine objects tree, built from the workspace root. This is the address to use to reach the object from scripts, the objects panel or remote messages. Only shown for objects that are registered in the objects list. See objects-address.

local

Read-only, not saved. Address of the object relative to the current patch, valid inside that patch only. See objects-address.

user addr

Free user-defined address for the object (empty by default). When set, the object is also registered in the objects tree under this name, so it can be reached independently of its position in the workspace (the value is also reported in the mouse-over and mouse-down chunks). Changing it rebuilds the objects list. Only available on objects that support a user address. See objects-address.

See also

version 7.0.250121

Edit All Pages