Writing a GEN plugin (64 bit) Hi, After reading Victor’s tutorial: http://csounds.com/articles/Extensions_to_Csound.pdf and building the example under 3.3.2 "plugin function tables", csound tells m

Hi,

After reading Victor’s tutorial:
http://csounds.com/articles/Extensions_to_Csound.pdf
and building the example under 3.3.2 “plugin function tables”,
csound tells me that the GEN number 44 is unknown (see test.csd below).
Is there a way of getting feedback when a GEN plugin was loaded and
which number it has?
The tutorial says that there are 43 internal GEN routines and GEN
plugins are numbered according to their loading order but according to
the manual the highest GEN number is 52. I tried out 53 but that didn’t
work either.
I am sure that the new shared library is in the right place.

Georg

C code and test.csd as follows:

///////////////// GEN plugin ///////////////////////////
#define USE_DOUBLE 1
#include “csdl.h”
#include <math.h>
void tanhtable(CSOUND *csound, FUNC *ftp, FGDATA *ff)
{
/* the function table */
MYFLT* fp = ftp->ftable;
/* f-statement p5, the range */
MYFLT range = ff->e.p[5];
/* step is range/tablesize */
double step = (double)
range/(ff->e.p[3]);
int i;
double x;
/* table-filling loop */
for(i=0, x=FL(0.0); i<ff->e.p[3];
i++,x+=step)
*fp++ = (MYFLT)tanh(x);
}

static NGFENS localfgens[] = {
{ “tanh”, (void(*)(void))tanhtable},
{ NULL, NULL}
};

#define S sizeof
static OENTRY *localops = NULL;
FLINKAGE

;———– test.csd ——————-
; dumps the content of an f table to
; the file “test.txt”

<CSoundSynthesizer>

<CsOptions>
-odac
</CsOptions>
<CsInstruments>
sr=44100
ksmps=1
nchnls=1

gisize init 32
gitest ftgen 1,0,gisize,44,2
;gitest ftgen 1,0,gisize,10,1
; tabnum ftgen ifn, itime, isize, igen, arg1 …. argn

instr 1

kndx init 0

if (kndx<gisize) then
        kres tab kndx, gitest
        fprintks “table.txt”, “%2.2f\n”, kres
        kndx = kndx+1
endif

endin

</CsInstruments>

<CsScore>

i1 0.0 1

e

</CsScore>
</CSoundSynthesizer>

Send bugs reports to this list.
To unsubscribe, send email to csound-unsubscribe@lists.bath.ac.uk

New piece: Aurora (for Kraig Grady)

Hi all,

I have just published a new piece called “Aurora (for Kraig Grady)”. It’s a short one, just over 3 minutes.  It was written in Csound using blue and Scala.  All source code is available for download, along with OGG and MP3 renderings, at

http://mysterybear.net/article/24/aurora-for-kraig-grady

As always, comments are welcome.

– Dave Seidel
http://mysterybear.net


Send bugs reports to this list.
To unsubscribe, send email to csound-unsubscribe@lists.bath.ac.uk

blue – 0.117.0

Hi All,

I’d like to announce a new release of blue available at:

http://www.csounds.com/stevenyi/blue

New features, updates, and bug fixes are listed in the change log below.

Thanks and enjoy!
steven

[CHANGE LOG]

Notes for 0.117.0<
[released 2007.08.27]

Steven Yi———————————————————————–

blue

    [new] – Add ability to randomize BlueSynthBuilder, ObjectBuilder, and
            Effects; to randomize, set randomizable on any of the following
            widgets(this is set to randomizable by default):

            -Horizontal Slider
            -Horizontal Slider Bank
            -Knob
            -Vertical Slider
            -Vertical Slider Bank
            -XY Controller

            then in UI editor, when set to non-edit mode, right click to show
            popup menu and choose “Randomize”

    [new] – added -u commandline option to pass in a directory to use to store
            blue’s configuration settings; by default blue used USER_HOME/.blue
            but this option was added so users can explicitly choose where to
            store settings (i.e. if you’re going to run blue from a USB flash
            drive you can set your configuration dir to somewhere on the usb
            drive)

    [updated] – Upgraded to Jython 2.2

    [updated] – Removed -p commandline option as it wasn’t very useful anymore
            (historically it was used to show which .blueConfig.xml to use, but
            this was before configuration settings were change to use a
            directory to store settings

    [updated] – Tracker – Shortcuts modified to be more like other trackers:

            -Insert key now adds a blank note and pushes down other notes

            -Entering a note with keyboard mode will now automatically select
            the next row after entering a note

            -BackSpace key will delete the current note and move all following
            notes up one row

            -Delete key will delete the current note and select the next row

    [updated/fix] – when blue loads, if any of the libraries are not loadable
            (Instruments, UDO, Script, Effects libraries), blue will now give an
            error message to fix or remove the corrupt file and exit out; this
            is done so that no overwriting of existing libraries or backup files

            (Thanks to Mark Van Peteghem for the bug report)

    [updated/fix] – Changed behavior when selecting SoundLayers, when focus is
            lost then selection will be deselected (prior behavior was that
            once a soundLayer was selected, the last one would always be
            selected unless one was removed or project files changed, which
            would just leave the selection always there which was distracting)

    [fix] – fixed mixer generation problem when Send signals were not being
            assessed correctly and branches of code were incorrectly optimized
            out

    [fix] – fixed problem when viewing in Score Navigator where complete text
            was being drawn even when past length of bar; fix was to set clip
            rect when drawing bars in preview mode

    [fix] – SoundLayer top row buttons should now look same size

    [fix] – Memory Leak – Some BSB Widget UI items did not remove themselves
            as propertyChangeListeners to BSB data classes

    [fix] – when opening dialog for render to disk when no filename given in
            project properties, set default to $HOME/output.wav for first time
            use (was defaulting to whatever last file was opened in any dialog)

manual

    [updated] – Updated keyboard shortcuts for Tracker

    [updated] – Added documentation about widget randomization to
            BlueSynthBuilder entry, as well as link to info from mixer section
            on working with effects

Dave Seidel———————————————————————

blue

    [fix] – parsing of Scala SCL files was broken for scales generated without
            comments