From the original SynthMaker forum (2004–2014), with its members’ names and dates.
Tzarls ·
How about a primitive to set a global variable/global array of floats that can be accesed from within the code component? Such a primitive would have a string input (for variable name), an int input (number of values),a float array input and a trigger input (for setting the values in the float array input). And no apparent outputs.
The global array/variable should be readable/writable from any piece of code with the usual "x = var[n]" or "var[n] = 100" This would make sharing of values from code to code easier, and with fewer streamins - streamouts when trying to move lage amount of data. The format of the variable naming could use a special character to make it different from normal floats or arrays. Something like "$var[n]".
MegaHurtz ·
Better yet any array thats declared in code becomes an array in the programs overhead.
And can be used in any peice of code by using its name.
any array that needs to be different (stock array) can be identified with a pseudo random name
or instance.
infuzion ·
Urmm, Tzarls I think you might need to start to learn C++/C#.
Tzarls ·
That´s exactly what I´ve been doing these last few weeks. I´m about to start my experiments with the VST SDK, but still believe that SM is a very powerfull tool and could be even better with just a few additions.
Disco_Steve ·
C# for audio ARRRRRRRRRRR
C++
C++
C++
yes writing code in sharp is like sexy on silk, but the pain of C++ is FAR overcome by the speed of running of the compiled code.
Tzarls ·
C++ is what I´ve been reading about. What frightens me the most is the GUI part, the audio part is pretty straightforward as far as I´ve been able to understand. Like, receive a block of code, do something to it, write the resulting values to the appropriate locations in memory.
Still, I´d like to see this gloabal array feature implemented sometime. And to answer to MegaHurtz post, I´d prefer it to have the array declaring as an independent primitive for many reasons. First, it would make easier to keep track of the used/declared arrays. Second, the way you suggest requires that the code declaring the array must be run before any other block of code calls the array´s values. With the global array primitive, that wouldn´t´t be an issue, because the array would be initialized with the schematic, before any code block is run.
MegaHurtz ·
really there is no cpu stall prob..
becouse you declare an array... done.
and the you read/write at samplerate.
But a prim is alright too.. There is the option to save and load
without having to set flags and parse strings.
^^ although "malc n jeorge"" I would like to do that 😍
But then again, ill go and have a stab at nasm.
trogluddite ·
Tzarls wrote: C++ is what I´ve been reading about. What frightens me the most is the GUI part,
Same here; I don't mind doing a bit of coding for DSP, but SM makes the user interface stuff so straightforward - and the green triggering system is so nice and intuitive.
If we could just have the mythical 'memin' data type in code/asm working, that would be a huge step forward - to share sample/delay buffers between code/asm primitives.
Tzarls ·
What don´t like about the memin feature is the use of wires and directionality of data. Memin would be an input, but if you wanted to use it for sharing data across many modules, then it should be also used as an output, which is weird. A global array would be wireless by definition, and could be read/written even faster than samplerate (I mean, you could use a loop to read many values during the same sample).
Wrote something here? To have a post removed or your name hidden, write to [email protected].