what have i done

This commit is contained in:
2025-10-15 15:05:23 +02:00
parent c5733897ea
commit 1015e9e18f
123 changed files with 28542 additions and 1030 deletions

View File

@ -0,0 +1,187 @@
import type { CsoundReference } from './types'
// Miscellaneous
export const miscellaneous: CsoundReference[] = [
{
name: 'directory',
type: 'opcode',
category: 'Miscellaneous',
description: 'Reads a directory and outputs to a string array a list of file names.',
syntax: 'SFiles[] = directory(SDirectory [, SExtention])',
example: '--8<-- "examples/directory.csd"',
parameters: [
{
name: 'SDirectory',
description: 'a string that identifies the directory to browse for files',
type: 'initialization'
},
{
name: 'SExtention',
description: 'Optional. Sets the desired file type. If left out, all files names will be retrieved.',
type: 'initialization'
},
],
seeAlso: ['Miscellaneous opcodes']
},
{
name: 'framebuffer',
type: 'opcode',
category: 'Miscellaneous',
description: 'Read audio signals into 1 dimensional k-rate arrays and vice-versa with a specified buffer size.',
syntax: 'kout[] = framebuffer(ain, isize)\n aout = framebuffer(kin, isize)',
example: '--8<-- "examples/framebuffer.csd"',
rates: ['k-rate'],
parameters: [
{
name: 'isize',
description: 'The amount of samples that the buffer will contain.',
type: 'initialization'
},
{
name: 'ain',
description: 'The audio signal input to the framebuffer.',
type: 'performance'
},
{
name: 'aout',
description: 'The audio signal output from the framebuffer. _kin_ -- The k-rate array input to the framebuffer.',
type: 'performance'
},
],
seeAlso: ['Array-based spectral opcodes']
},
{
name: 'modmatrix',
type: 'opcode',
category: 'Miscellaneous',
description: 'Modulation matrix opcode with optimizations for sparse matrices.',
syntax: 'modmatrix(iresfn, isrcmodfn, isrcparmfn, imodscale, inum_mod, \\\n inum_parm, kupdate)',
example: '--8<-- "examples/modmatrix.csd"',
parameters: [
{
name: 'iresfn',
description: 'ftable number for the parameter output variables',
type: 'initialization'
},
{
name: 'isrcmodfn',
description: 'ftable number for the modulation source variables',
type: 'initialization'
},
{
name: 'isrcparmfn',
description: 'ftable number for the parameter input variables',
type: 'initialization'
},
{
name: 'imodscale',
description: 'scaling/routing coefficient matrix. This is also a csound ftable, used as a matrix of inum_mod rows and inum_parm columns.',
type: 'initialization'
},
{
name: 'inum_mod',
description: 'number of modulation variables',
type: 'initialization'
},
{
name: 'inum_parm',
description: 'number of parmeter (input and output) variables.',
type: 'initialization'
},
{
name: 'kupdate',
description: 'flag to update the scaling coefficients. When the flag is set to a nonzero value, the scaling coefficients are read directly from the imodscale ftable. When the flag is set to zero, the scaling coefficients are scanned, and an optimized scaling matrix stored internally in the opcode.',
type: 'performance'
},
],
seeAlso: ['Miscellaneous opcodes']
},
{
name: 'nchnls_hw',
type: 'opcode',
category: 'Miscellaneous',
description: 'Returns the number of audio channels in the underlying hardware.',
syntax: 'idacc, iadcc = nchnls_hw()',
example: '--8<-- "examples/nchnls_hw.csd"',
seeAlso: ['Miscellaneous opcodes']
},
{
name: 'olabuffer',
type: 'opcode',
category: 'Miscellaneous',
description: 'Sum overlapping frames of audio as k-rate arrays and read as an audio signal.',
syntax: 'aout = olabuffer(kin, ioverlap)',
example: '--8<-- "examples/framebuffer.csd"',
rates: ['k-rate'],
parameters: [
{
name: 'ioverlap',
description: 'The amount of overlaps per k-array input frame sample size. For example for an input window size of 1024, and a hop size of 256 the overlap factor would be 4. The overlap factor must be larger than or equal to ksmps and must also be an integer multiple of the input k-rate array sample count.',
type: 'initialization'
},
{
name: 'aout',
description: 'The resulting audio signal from the added input frames.',
type: 'performance'
},
{
name: 'kin',
description: 'A k-rate array containing sequential frames of audio.',
type: 'performance'
},
],
seeAlso: ['Array-based spectral opcodes']
},
{
name: 'pwd',
type: 'opcode',
category: 'Miscellaneous',
description: 'Asks the underlying operating system for the current directory (folder) name as a string.',
syntax: 'Sres = pwd()',
example: '--8<-- "examples/pwd.csd"',
parameters: [
{
name: 'Sres',
description: 'the returned string.',
type: 'performance'
},
],
seeAlso: ['Miscellaneous opcodes']
},
{
name: 'select',
type: 'opcode',
category: 'Miscellaneous',
description: 'Select sample value from three based on audio-rate comparisons of two signals.',
syntax: 'aout = select(a1, a2, aless, aequal, amore)',
example: '--8<-- "examples/select.csd"',
parameters: [
{
name: 'a1',
description: 'audio signals that are compared.',
type: 'performance'
},
{
name: 'a2',
description: 'audio signals that are compared.',
type: 'performance'
},
{
name: 'aless',
description: 'audio signal selected if a1[n]&lt;a2[n]',
type: 'performance'
},
{
name: 'aequal',
description: 'audio signal selected if a1[n]=a2[n]',
type: 'performance'
},
{
name: 'asig',
description: 'audio signal selected if a1[n]&gt;a2[n]',
type: 'performance'
},
],
seeAlso: ['Miscellaneous opcodes']
},
]