ftfree
Prev | Orchestra Opcodes and Operators | Next

## ftfree

ftfree — Deletes function table.

## Description

Deletes function table.

## Syntax

    ftfree ifno, iwhen

## Initialization

ifno -- the number of the table to be deleted

iwhen -- if zero the table is deleted at init time; otherwise the table number is registered for being deleted at note deactivation.

| Note
If the table is deleted at init time it is possible that an earlier opcode that uses the table will fail or crash on a performance cycle. It is the user's responsibility to avoid this error.

## Examples

Here is an example of the ftfree opcode. It uses the file ftfree.csd.

Example 388. Example of the ftfree opcode.

See the sections Real-time Audio and Command Line Flags for more information on using command line flags.

    <CsoundSynthesizer>
    <CsOptions>
    ; Select audio/midi flags here according to platform
    -odac      ;;;realtime audio out
    ;-iadc    ;;;uncomment -iadc if realtime audio input is needed too
    ; For Non-realtime ouput leave only the line below:
    ; -o ftfree.wav -W ;;; for file output any platform
    </CsOptions>
    <CsInstruments>

    sr = 44100
    ksmps = 32
    nchnls = 2
    0dbfs  = 1

    gitempTable ftgen 0, 0, 65537, 10, 1

    instr 1

    aout oscili .5, 440, gitempTable
         outs aout, aout

    ;free temp table at deinit time
    ftfree gitempTable, 1
    print  gitempTable

    endin
    </CsInstruments>
    <CsScore>
    f 0 5

    i 1 0 .1
    i 1 3 1

    e
    </CsScore>
    </CsoundSynthesizer>

    instr 1:  gitempTable = 101.000
    B  0.000 ..  3.000 T  3.000 TT  3.000 M:  0.50000  0.50000
    INIT ERROR in instr 1: Invalid ftable no. 101.000000
    instr 1:  gitempTable = 101.000
    Error deleting ftable 101
    	  B  3.000 - note deleted.  i1 had 1 init errors
    B  3.000 ..  5.000 T  5.000 TT  5.000 M:  0.00000  0.00000

## Credits

Authors: Steven Yi, Istvan Varga
2005

Prev | Up | Next
ftexists | Home | ftgen