beetlebug▾
/

ztcl::audio info

Gives the ids of the audio engine, or the facts of one.

ztcl::audio info ?ID?

Description

With no ID, gives the ids of the sounds, of the voices that play, and of the patterns, as after info. With ID, gives a dict: type (sound, voice, or pattern) and the options of the id without their dash.

Returns

A list of ids, or a dict.

Examples

% ztcl::audio configure -device offline; set s [ztcl::audio load -wave sine -length 10]; ztcl::audio info $s
type sound frames 480 gain 1 length 10

% set m [ztcl::audio pattern [list $s {X x}] -meter 2/4]; ztcl::audio info $m
type pattern accent 0.6 command {} countin 0 gap {} loop 0 meter 2/4 subdivision 1 swing 0 tempo 120 tracks {sound1 {X x}}

Errors

% ztcl::audio info voice5
voice "voice5" doesn't exist
-errorcode TCL LOOKUP AUDIO voice5

Facts

Capability
audio. A new interpreter does not have it until the host turns it on.
Tcl release
Tcl 9.1 and 8.6.
Since
ztcl 1.0.0-beta.6

See also