SndTable

SndTable(path, chnl=None)

Load data from a soundfile into a function table.

If `chnl` is None, the table will contain as many table streams as necessary to read all channels of the loaded sound.

Parent class : PyoTableObject

Parameters:

    path : string
        Full path name of the sound.
    chnl : int, optional
        Channel number to read in. The default (None) reads all channels.

Methods:

    setSound(path) : Load a new sound in the table.
    getDur() : Return the duration of the sound in seconds.
    getRate() : Return the frequency in cps at which the sound will be 
        read at its original pitch.

Attributes:

    sound : Sound path loaded in the table.

Examples:

    >>> s = Server().boot()
    >>> s.start()
    >>> snd_path = SNDS_PATH + '/transparent.aif'
    >>> t = SndTable(snd_path)
    >>> a = Osc(table=t, freq=t.getRate(), mul=.5).out()