import type { CsoundReference } from './types' // Signal Generators:Wave Terrain Synthesis export const signalGeneratorsWaveTerrainSynthesis: CsoundReference[] = [ { name: 'sterrain', type: 'opcode', category: 'Signal Generators:Wave Terrain Synthesis', description: 'A wave-terrain synthesis opcode using curves computed with the superformula.', syntax: 'aout = sterrain(kamp, kcps, kx, ky, krx, kry, krot, ktab0, ktab1, km1, km2, \\\n kn1, kn2, kn3, ka, kb, kperiod)', example: '--8<-- "examples/sterrain.csd"', rates: ['k-rate'], parameters: [ { name: 'ktabx', description: 'The two tables that define the terrain - they can be changed at krate.', type: 'performance' }, { name: 'ktaby', description: 'The two tables that define the terrain - they can be changed at krate.', type: 'performance' }, { name: 'kn1', description: '!=0 and continous.', type: 'performance' }, { name: 'ka', description: '!=0 and continous.', type: 'performance' }, { name: 'kb', description: '!=0 and continous.', type: 'performance' }, { name: 'kn2', description: 'continous.', type: 'performance' }, { name: 'kn3', description: 'continous.', type: 'performance' }, { name: 'km1', description: 'positive integer > 0: note that the curves are not on all combinations of km1,km2 closed and have poles (closed in infinity) for example if kn1>0 and there exists an n,m in Z with 2*km1/km2 = 2m+1/n i.e curves with (3,2) (5,2) (7,2) etc and (5,4) (6,4) (7,4) (9,4) etc. have a pole which is noticeable when listening. If kn1 < 0 then the curve is reversed and the poles go towards zero in this case. If km1 and km2 are zero silence is produced (a plain circ - same effect occurs with the tuple 2,2,2,2,2,1,1).', type: 'performance' }, { name: 'km2', description: 'positive integer > 0: note that the curves are not on all combinations of km1,km2 closed and have poles (closed in infinity) for example if kn1>0 and there exists an n,m in Z with 2*km1/km2 = 2m+1/n i.e curves with (3,2) (5,2) (7,2) etc and (5,4) (6,4) (7,4) (9,4) etc. have a pole which is noticeable when listening. If kn1 < 0 then the curve is reversed and the poles go towards zero in this case. If km1 and km2 are zero silence is produced (a plain circ - same effect occurs with the tuple 2,2,2,2,2,1,1).', type: 'performance' }, { name: 'kperiod', description: 'some km1 and km2 ratios may cause pitch shifts. With the kperiod parameter this can be fixed. If the ratio is 1 then the kperiod value should also be set to km1 to get the incoming pitch out.', type: 'performance' }, ], seeAlso: ['Wave Terrain Synthesis'] }, ]