SPList:
Filter:
SPList (extension) | SPList

SPList
ExtensionExtension

a collection of Periods for waveset synthesis

Description

SPlist is a set of classes for non-realtime-soundfile-transformation.

For the most reliable and well tested analysis of a sound file you need to have the programm "splistanalyst" installed. In the moment I make the assumption that "splistanalyst" would be only installed on linux.

Now sound-file analysis files can also be created from within supercollider but the process is not well tested.

SPList is like a List operating on its own content, it is not creating a new copy.

Many methods work in the same way as methods of Collection and List work I do not document them here.

The SPL.sc file contains extensions to splist which provide specific use cases they are not documented here for now.

Class Methods

.new

creates a new empty SPList. Usually not used by hand.

Bund methods

These are the four bund methods that generate a single value from the values of a type in a SPList.

avr

average of all values in a SPList.

sum

sum of all values in a SPList.

small

smallest of all values in a SPList.

big

biggest of all values in a SPList.

Arguments:

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

Returns:

a Float

subavr

subsum

subsmall

subbig

When the elements of a SPList are SPLists it might be desirable to calculate their values with a different function than the top layer. The bund function for the containing SPLists is given as argument.

Arguments:

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

bund

If the SPList contains SPLists bund defines how they are calculated together. Choose either of the following Symbol: \avr, \sum, \small, \big

Returns:

a Float

Clumping methods

grainThreshNeg

Clumps all periods together starting from the point when a threshhold is crossed towards a lower value of a type until it happens again.

grainThreshPos

Clumps all periods together starting from the point when a threshhold is crossed towards a higher value of a type until it happens again.

grainThreshSplit

Clumps all periods together between crossings of a threshhold (in both directions).

Arguments:

threshhold

Threshhold value

type

type of analysed data either of the following Symbol: \amp,\rms,\freq,\length,\sec,\peaks,\delta

bund

If the SPList contains SPLists bund defines how they are calculated together. Choose either of the following Symbol: \avr, \sum, \small, \big

Returns:

(describe returnvalue here)

grainMax

Clumps all periods together between two maxima of a value of a type.

grainMin

Clumps all periods together between two minima of a value of a type.

Arguments:

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

bund

If the SPList contains SPLists bund defines how they are calculated together. Choose either of the following Symbol: \avr, \sum, \small, \big

Split methods (alternative to Clumping methods)

Split methods split a SPList into two parts (and put these two parts as suplist into the SPList)

splitHalf

Split a list in the middle of the SPList.

splitAfter

Split after Nth element of a SPList.

splitBefore

Split before Nth element of a SPList.

Arguments:

at

Integer position.

splitNextMax

Split at next local maximum of a value of a type.

splitNextMin

Split at next local minmum of a value of a type.

Arguments:

area

This argument describes the number of list elements around the middle of a SPList that are taken into consideration.

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

bund

If the SPList contains SPLists bund defines how they are calculated together. Choose either of the following Symbol: \avr, \sum, \small, \big

splitN

Recursive split method. splits SPList N times in two parts.

// RECURSE SPLIT FUNCTIONS // teile deep mal in 2 teile (also 2.pow(deep)) // mithilfe der angegebenen splitfunktion und ihrer argumente // wird die splitposition bestimmt (describe method here)

Arguments:

deep

How often sthe split function should be performed.

sfunc

Symbol of a split function

... args

arguments of a split funtion: \splitHalf \splitAfter \splitBefore \splitNextMin \splitNextMax

Transformations

loop

Repeats each element of the SPList n times.

internalloop

Repeats the whole content of a SPList.

internalloopcopy

Repeats the whole content of a SPList and create deep copies for each instance.

Arguments:

n

number of repetition in addition to the existing one.

env

Applies a SPEnv Envelope on a SPList.

Arguments:

envelope

Needs a SPEnv object.

interleave

interleaves two SPLists

Arguments:

anSPList

a SPList

cutend

Boolean true: the shorter SPList should define the length of the total new list false: the shorter file gets looped.

sortBy

The usual way to sort a SPList is by this method. A SPList is sorted acording to the values of a type.

Arguments:

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

bund

If the SPList contains SPLists bund defines how they are calculated together. Choose either of the following Symbol: \avr, \sum, \small, \big

reverse

reverse the splist

Export and Playback

play

Play back a SPList. Writes a sound file and plays it back.

Arguments:

spf

Function that transforms the start pos of each element of a SPList on the top level.

spfd

Function that transforms the start pos of each element of a SPList on the lower levels.

write

Writes a sound file.

Arguments:

nrtServerOptions

a instance of NRTServerOptions.

spf

Function that transforms the start pos of each element of a SPList on the top level.

spfd

Function that transforms the start pos of each element of a SPList on the lower levels.

Helper methods

nodecount

Returns the number of Periods.

Returns:

a Integer

parent

returns the parent of a SPList.

Returns:

a SPList

flat

Make SPList flat again. Remove all clumping of SPLists.

length

Length in samples of a SPList

howDeep

returns how deep the SPList structure is.

performOnPeriod

Perform a method on the Periods within a SPList

Arguments:

method

method key

... args

argument of the method

Returns:

a Integer

appendSPList

Append a SPList to this SPList

Arguments:

anSPList

deepCopy

Creates a deepCopy of a SPList. This is necessary when different transformations on the same source material should be applied.

Returns:

a SPList

reset

Attempts to bring a SPList into its original shape. But it can not recreate deleted Periods.

flatSub

Some kind of wheiered flattening method

flattenSub

another strange flatten method

print

Print values of a specific type of the SPList. (should make use of bund method)

Arguments:

type

type of analysed data: \amp,\rms,\freq,\length,\sec,\peaks,\delta

doDeep

apply a do on all levels of a SPList structure.

Arguments:

function

The first argument is the current splist. The second argument is the value of deepness.

Examples

Complex methods

No time right now to document.

grainEnv

(describe method here)

Arguments:

levels

(describe argument here)

times

(describe argument here)

curves

(describe argument here)

releaseNode

(describe argument here)

loopNode

(describe argument here)

Returns:

(describe returnvalue here)

pitchShift

(describe method here)

Arguments:

fx

(describe argument here)

... args

(describe argument here)

Returns:

(describe returnvalue here)

timeStretchRand

(describe method here)

Arguments:

newtime

(describe argument here)

Returns:

(describe returnvalue here)

timeStretch

(describe method here)

Arguments:

newtime

(describe argument here)

Returns:

(describe returnvalue here)

pitchShiftLoop

(describe method here)

Arguments:

fx

(describe argument here)

... args

(describe argument here)

Returns:

(describe returnvalue here)

transposeCurve

(describe method here)

Arguments:

p1

(describe argument here)

p2

(describe argument here)

p3

(describe argument here)

Returns:

(describe returnvalue here)