The Alternative Csound Reference Manual
Previous |  | Next

# xscans

xscans -- Fast scanned synthesis waveform and the wavetable generator.

## Description

Experimental version of scans. Allows much larger matrices and is faster and smaller but removes some (unused?) flexibility. If liked, it will replace the older opcode as it is syntax compatible but extended.

## Syntax

ar xscans kamp, kfreq, ifntraj, id [, iorder]

## Initialization

ifntraj -- table containing the scanning trajectory. This is a series of numbers that contains addresses of masses. The order of these addresses is used as the scan path. It should not contain values greater than the number of masses, or negative numbers. See the introduction to the scanned synthesis section.

id -- If positive, the ID of the opcode. This will be used to point the scanning opcode to the proper waveform maker. If this value is negative, the absolute of this value is the wavetable on which to write the waveshape. That wavetable can be used later from an other opcode to generate sound. The initial contents of this table will be destroyed.

iorder (optional, default=0) -- order of interpolation used internally. It can take any value in the range 1 to 4, and defaults to 4, which is quartic interpolation. The setting of 2 is quadratic and 1 is linear. The higher numbers are slower, but not necessarily better.

## Performance

kamp -- output amplitude. Note that the resulting amplitude is also dependent on instantaneous value in the wavetable. This number is effectively the scaling factor of the wavetable.

kfreq -- frequency of the scan rate

## Matrix Format

The new matrix format is a list of connections, one per line linking point x to point y. There is no weight given to the link; it is assumed to be unity. The list is proceeded by the line <MATRIX> and ends with a </MATRIX> line

For example, a circular string of 8 would be coded as

    <MATRIX>
    0 1
    1 0
    1 2
    2 1
    2 3
    3 2
    3 4
    4 3
    4 5
    5 4
    5 6
    6 5
    6 7
    7 6
    0 7
    </MATRIX>

## Examples

For an example, see the documentation on scans.

## See Also

scans, xscanu

Previous | Home | Next
xscansmap | Up | xscanu