Csound Changelog

What's new in Csound 6.03.1

May 7, 2014
  • USER-LEVEL CHANGES:
  • New opcodes:
  • printks2: Prints a new value every time a control variable changes using a printf() style syntax.
  • mp3sr mp3bitrate and mp3nchnls to get information on mp3 files
  • EXPERIMENTAL: CUDA opcodes for partitioned convolution direct convolution and sliding phase vocoding; OpenCL opcode for additive synthesis
  • compilecsd to compile instruments from a standard CSD file
  • New Gen and Macros:
  • Orchestra:
  • The argument for i() is supposed to be a variable not an expression. This is now enforced. (bug #90)
  • Score:
  • New score opcode y sets the random seed (for ~) at read time
  • Options:
  • This was a bug in CsOptions; the last argument was missed being read (issue #296)
  • As command-line options expression-opt and no-expression-opt do nothing in Csound6 a warning is printed.
  • Modified Opcodes and Gens:
  • For ogg output it is possible to specify a VBR (variable bit rate) quality.
  • dssi4cs code has been extensively reworked to avoid potential memory faults.
  • Many array operations now available for i-arrays as well as k-arrays.
  • fillarray will work for string arrays
  • Displays of FFT (via dispfft) improved with scaling/zooming options
  • Signal flow graph opcodes are now working with a-rate array signals.
  • In alsa rt code the sample rate is taken from the device
  • Faust opcode system updated to latest Faust API.
  • Utilities:
  • fixed bug in lpanal
  • Frontends:
  • csound~:
  • Windows - csound~ now available for Windows
  • Emscripten:
  • This is now generally merged in to the code-base
  • General usage:
  • displays now switches graphs on, as expected
  • New command-line option --get-system-sr added to obtain the machine's sample rate.
  • New command-line option --devices[=in|out] gives a list of available audio devices and then exit
  • Bugs fixed:
  • fixed the bug when tables were replaced but the size did nt change
  • A number f bugs in --sample-accurate have been detected and
  • fixed. This includes pcdes ut, utn, and line.
  • A number f bugs in grain3 were fixed#
  • Bug in str_chanel culd cause a crash; fixed
  • Small bug in rtjack fixed
  • Errr in resize pcde crrected
  • Fixed an unlikely bug in atsa
  • Fixed rtauhal pause issue
  • Fixed bug in rtjack
  • A number f bugs/untidiness fixed in GEN23
  • Array bund checks fixed
  • strings channels were nt crrectly set fr dynamic-size
  • strings, nw fixed
  • memry allcatin fr string frmatting in printfsk was fixed,
  • stpping string truncatin.
  • strcat safe against verflw
  • errr in cmpilatin f arrays fixed (issue #293)
  • GetPvsChannel fixed against a crash
  • SYSTEM LEVEL CHANGES:
  • System changes:
  • turnoff opcode now checks that the instrument being affected is active
  • lenarray can accept any array type
  • the way of rounding a table number to an integer was changed and is now more as expected.
  • there is a new possible section in a csd file called which is like csFileB but with unencoded text.
  • UDO compilation now uses the type system. This means that UDOs now allow any array type to be used.
  • Improved orchestra parsing speeds with better algorithms
  • Internal changes:
  • The whole system has been checked by the Coverity static checker which identified a number of (mainly minor) problems. These have been reviewed and checked. In particular better use of printing and string copying should prevent overflows.
  • The type and variable system has been extensively rewritten; this allows better array and UDO support.
  • Alignment of variables got right in all cases array copying is now using the type system to copy values; fixes issues with copying string arrays, f-sigs, etc.
  • Always reset Csound when stopping to ensure state is clean; was not being reset when there was a compile error, so that next successful run would start with an invalid Csound engine (issue #305)
  • API:
  • possible to replace the whole memory allocator.
  • Added csoundCompileCsd to API and associated new compilecsd opcode
  • Protected csoundGetStringChannel against null and short strings and added a check for string size
  • A number of API functions have had char* changed to const char* which
  • reflect the usage
  • The performance engine now includes debugging capabilities to allow
  • interrupting rendering and providing introspection into the engine's state
  • and instrument variables. The following new functions are available by
  • including the csdebug.h header:
  • void csoundDebuggerInit (CSOUND *csound)
  • void csoundDebuggerClean (CSOUND *csound)
  • void csoundSetInstrumentBreakpoint (CSOUND *csound, MYFLT instr, int skip)
  • void csoundRemoveInstrumentBreakpoint (CSOUND *csound, MYFLT instr)
  • void csoundClearBreakpoints (CSOUND *csound)
  • void csoundSetBreakpointCallback (CSOUND *csound, breakpoint_cb_t bkpt_cb,
  • void *userdata)
  • void csoundDebugContinue (CSOUND *csound)
  • void csoundDebugStop (CSOUND *csound)
  • INSDS * csoundDebugGetInstrument (CSOUND *csound)

New in Csound 6.02.0 (Jan 8, 2014)

  • USER-LEVEL CHANGES:
  • New opcodes:
  • instance opcode schedules a new instrument instance, storing the instance handle
  • kill opcode stops a given instrument instance
  • strfromurl to set a string from a URL
  • New Gen and Macros: None
  • Orchestra:
  • If building supports it, a #include string can be a URL or a file
  • A space is again permitted between a function name and the opening bracket for all functions allowed in Csound5 (but not in general)
  • The Csound command can start with an empty CSD in daemon mode
  • (daemon daemon mode: do not exit if CSD/orchestra is not given, is empty or does not compile)
  • Score:
  • If building supports it, a #include string can be a URL or a file
  • Modified Opcodes and Gens:
  • Many filters generalised to allow k- or a-rate parameters. In particular it includes these: areson, atonex, butterworth filters, fofilter, lowres, lowresx, lpf18, mode, moogladder, moogvcf, reson, resonr, resonx, resonz, statevar, tonex
  • The maximum number of presets in sfont increased to 16384
  • cpsmidinn is now more accurate
  • max_k now behaves like the documentation. There were cases when it gave strange results.
  • The vst4cs opcodes have been re-factored, removing FLTK code, and updated build system to work for Csound 6.
  • In alwayson opcode changes for better handling of pfields, more reliable insert of the instrument instance for repeating or re-started score sections.
  • The signal flow graph opcodes have had replaced OpenMP multi-threading with pthreads, using one-time initialization of static structures.
  • Utilities: None
  • Frontends:
  • PNaCl is now supported as a platform, allowing Csound to run under the Chrome browser in all enabled operating systems.
  • General usage: Nothing to report
  • Bugs fixed:
  • adsynt2 opcode fixed
  • ftgentmp opcode fixed
  • dates opcode fixed
  • fixed a bug in pvsfilter
  • fixed stereo out in temposcal and mincer
  • pan2 opcode fixed
  • index overflow in randh and randi fixed
  • a number of fixes to CsoundVST, initialization, score handling, and MIDI driver initialization so works for Csound 6.
  • fixed pycalln for no inputs
  • fixed/revised setting and use of ksmps and kr in UDOs
  • fixed problem in sending a score event from max to csound vis csound~ (Ticket #58)
  • If itype in chn_k was set to 3 and values are set less than 1, Csound6 used to give an INIT Error. (Ticket #67)
  • A number of reported seg faults have been dealt with
  • xtratim opcode was using incorrect ekr value from csound instead of from instance; when used in conjunction with setksmps, was causing notes to have very long xtratim set and thus notes were effectively not getting turned off
  • SYSTEM LEVEL CHANGES:
  • System changes:
  • A server mode is now available, accepting input via UDP (with
  • --port option).
  • A longstanding bug in extract was detected and fixed. It does suggest that this facility is little used!
  • The way the external score generator was coded is substantially changed. In particular this should fix a very strange bug in Windows.
  • Fixed crashing bug with invalue channel callback due to wrong data object being pulled from csound host data.
  • Fixed bug in UDOs with no local ksmps where kcounter was being used incorrectly.
  • Better checking in channels.
  • (Experimental) If the environment variable CS_UDO_DIR is set then any files in the directory that have an .udo extension are automatically included at the start of the orchestra. This facility needs review to see if it is what is required.
  • (Experimental) There are new cuda GPGPU opcodes (source only): cudasynth (3 versions for additive synthesis, additive synthesis of fsigs and phase vocoder resynthesis) and cudanal (a GPGPU version of pvsanal).
  • Internal changes:
  • Many attempts at faster code.
  • Type inference and parsing still improving
  • API:
  • Fixed csoundSetStringChannel and csoundGetStringChannel to use
  • STRINGDAT structure.

New in Csound 6.00 RC 3 (Jun 14, 2013)

  • Many bug fixes and code improvements
  • New opcodes: faustgen, array
  • Added 0dbfs and nchnls override
  • Added delete tree to the API
  • Greatly improve array arithmetic operations
  • Removed limit on number of instances in parallel code
  • Fixed schedwhen for named instrs
  • Change to escape characters in score strings -- they do not happen
  • this is still subject to change)
  • Fixed dssi
  • Use thread-safe internal functions in compilaton etc
  • Thread-safe use of locales
  • String variables re-implemented

New in Csound 6.00 RC 1 (Apr 30, 2013)

  • Build system in cmake (and not scons as in Csound5).
  • The loadable opcodes are found in the directory named in the environment variables OPCODE6DIR64 or OPCODE6DIR (note the 6) so it can co-exist with Csound5
  • Note events can start and end in mid-kcycle. As this is an incompatible change it is only invoked with the command-line option --sample-accurate is specified. Not that this does not work for tied notes, and use of skipping initialisation has questionable use.
  • A number of table access opcodes have been rewritten but should behave the same. Similarly diskin and diskin2 now use the same code and so diskin should be more stable.
  • Compilation can be done at any stage, new instruments are added or replace old ones. Running instances of old instrument definitions are not affected. Only limitation is that instr0 is only compiled once, in the first compilation.
  • Two i-time opcodes for compilation: ires compileorc ifilename compiles an orchestra in ifilename (instr0 ignored)
  • ires compilestr Sinstruments compiles an orchestra defined in Sinstruments
  • ires is 0 if successful and non-0 if compilation failed.
  • The old parser is totally gone.
  • New syntax in csound6 includes +=, -=, *= and /= operators. Please use += and -= for accumulating reverbs as it gives better multicore behavior.
  • Multicore support is totally rewritten using a different algorithm for task-dispatch, which should use less memory and fewer locks.
  • Opcodes like add, sub, mul and div are no longer available in opcode format, only via + - * /
  • Any opcode that returns one answer and whose type is the same as the first argument can be used as a function. This incorporates all functions in CS5, but also functions of two arguments such as taninv2 and divz, and opcodes like oscil.
  • A statement can be broken across lines after a , = or arithmetic operation.
  • Arrays exist in multidimensional format. They are created (usually) with init opcode.
  • k1[] init 4
  • generates a k-rate 1-D array of length 4. Similarly a2[][] init 4,4
  • create a square 4x4 a-rate array.
  • Elements are used via indexing in [] such as k1[2] or a2[2][3]. One dimensional arrays replace tvars, and can be used in opcodes like maxtab, mintab and sumtab. Array setting can be done in left-hand side of opcodes, i.e.: aSigs[0] vco2 .1, 440 aSigs[1] vco2 .1, 880
  • The new realtime priority mode can be switched on with by passing the --realtime or setting the CSOUND_PARAMS field realtime_mode to 1.
  • This has the following effects:
  • all opcode audio file reading/writing is handled asynchronously by a separate thread
  • all init-pass operations are also performed asynchronously.
  • Functions for asynchronous audio file access have been added.
  • Analysis formats:
  • Hetro/adsyn analysis files can be machine byte-order independent if created with -X. Down side is a longer file and a little slower loading. The het_export utility will create the independent format from the old, and het_import is no longer necessary.
  • cvanal and lpanal will produce machine independent files if -X option is used. The convolve and lpread etc opcodes will accept either format. You are encouraged to use the machine independent form. Analysis files produced with -X can be used on other systems.
  • The number of strings that can be used in a score line is no longer just one. It is open ended.
  • Each instance of any instrument has a scratchpad of 4 values that persist; allows values to carry to next use of the instrument; hope it may be useful in legato etc.
  • If a table number is given as -1 then an internal sine wave equivalent to "f. 0 8192 10 1" is used. Attempts to write to this table will give unpredictable results, but is not policed. The 8192 can be change by command line option --sine-size=# where the # is rounded up to a power of two.
  • New API functions:
  • new configuration/parameter setting functions
  • PUBLIC int csoundSetOption(CSOUND *csound, char *option);
  • PUBLIC void csoundSetParams(CSOUND *csound, CSOUND_PARAMS *p);
  • PUBLIC void csoundGetParams(CSOUND *csound, CSOUND_PARAMS *p);
  • PUBLIC void csoundSetOutput(CSOUND *csound, char *name, char *type, char *format);
  • PUBLIC void csoundSetInput(CSOUND *csound, char *name);
  • PUBLIC void csoundSetMIDIInput(CSOUND *csound, char *name);
  • PUBLIC void csoundSetMIDIFileInput(CSOUND *csound, char *name);
  • PUBLIC void csoundSetMIDIOutput(CSOUND *csound, char *name);
  • PUBLIC void csoundSetMIDIFileOutput(CSOUND *csound, char *name);
  • new parsing/compilation functions
  • PUBLIC TREE *csoundParseOrc(CSOUND *csound, char *str);
  • PUBLIC int csoundCompileTree(CSOUND *csound, TREE *root);
  • PUBLIC int csoundCompileOrc(CSOUND *csound, char *str);
  • PUBLIC int csoundReadScore(CSOUND *csound, char *str);
  • PUBLIC int csoundCompileArgs(CSOUND *, int argc, char **argv);
  • new function for starting csound after first compilation
  • PUBLIC int csoundStart(CSOUND *csound);
  • new software bus threadsafe getters/setters
  • PUBLIC MYFLT csoundGetControlChannel(CSOUND *csound, const char *name);
  • PUBLIC void csoundSetControlChannel(CSOUND *csound, const char *name, MYFLT val);
  • PUBLIC void csoundGetAudioChannel(CSOUND *csound, const char *name, MYFLT *samples);
  • PUBLIC void csoundSetAudioChannel(CSOUND *csound, const char *name, MYFLT *samples);
  • PUBLIC void csoundSetStringChannel(CSOUND *csound, const char *name, char *string);
  • PUBLIC void csoundGetStringChannel(CSOUND *csound, const char *name, char *string);
  • new table threadsafe copy functions
  • PUBLIC void csoundTableCopyOut(CSOUND *csound, int table, MYFLT *dest);
  • PUBLIC void csoundTableCopyIn(CSOUND *csound, int table, MYFLT *src);
  • API has been made threadsafe so that performance and control can occur in separate threads (after a call to csoundStart() or csoundCompile()). Threadsafety is ensure by 1) use of atomic read/writing to control channels 2) spinlocks in audio and string channels 3) mutexes protecting compilation, score events and table access
  • Invalue/outvalue and channel callbacks and callback setters have been removed. csoundQueryInterface() has been removed
  • New internal functions in CSOUND:
  • void (*FlushCircularBuffer)(CSOUND *, void *);
  • flush circular buffer.
  • void *(*FileOpenAsync)(CSOUND *, void *, int, const char *, void *, const char *, int, int, int);
  • unsigned int (*ReadAsync)(CSOUND *, void *, MYFLT *, int);
  • unsigned int (*WriteAsync)(CSOUND *, void *, MYFLT *, int);
  • int (*FSeekAsync)(CSOUND *, void *, int, int);
  • async file access.
  • char *(*GetString)(CSOUND *, MYFLT);
  • Extract a string originating from a score-event argument.
  • functions removed:
  • void *(*FileOpen)(CSOUND *,
  • void*, int, const char*, void*, const char*);
  • The "private" parts of the API have been changed considerably. Also structures like EVTBLK have changed
  • The LINKAGE1/FLINKAGE1 macros are renamed as LINKAGE_BUILTIN/FLINKAGE_BUILTIN

New in Csound 5.18.02 (Sep 11, 2012)

  • New Opcodes:
  • log2 function to calculate logarithm base 2
  • platerev, a physical model from Stefan Bilbao
  • vbap opcode is a generalisation of the various fixed number of channels
  • vbapg opcode is like vbap except just calculates gains
  • pwd opcode to obtain the working directory
  • readf/readfi to read strings from a file
  • centroid opcode (like pvscent but acting on audio signals)
  • cosseg opcode, like linseg but with cosine interpolation
  • cossegb opcode, like linsegb but with cosine interpolation
  • cossegr opcode, like linsegr but with cosine interpolation
  • Score:
  • A score may be omitted totally
  • Modified Opcodes and Gens:
  • New features in partikkel
  • panning law for channelmasks can now be set using a function table (second optional arg to partikkel)
  • new support opcodes partikkelget and partikkelset, to access and modify the internal mask indices of partikkel
  • follow2 was reworked do the i-rate and k-rate calculations are the same
  • pvscent corrected as it returned half the correct value
  • vbaplsinit can create more than one speaker layout which vbap/vbapg can use. Also much better diagnostics on incorrect layouts
  • Utilities:
  • csbeats: internal fixes to remove crashing
  • Frontends:
  • CsoundAc has seen considerable developments
  • Bugs fixed:
  • dates could crash on 64bit architecture
  • Some multicore interlocks were wrong
  • Some files could be closed twice, leading to a crash
  • System Changes:
  • Changes to to allow spaces between words, and escaped characters.
  • Code changed so bison 2.6 can be used
  • fout and fin use a better buffering strategy, and so are faster
  • It is possible to specify just an orchestra with the --orc flag. Useful when a score is not needed
  • added a --ogg flag for easy use of ogg/vorbis output
  • It is assumed that libsndfile version 1.0.19 or later is available
  • Added alsaseq real-time midi (see below)
  • Internal:
  • Many! Some messages quietened, more defensive code etc
  • Code speeded up in many places; hopefully not many bugs introduced

New in Csound 5.17.0 (Apr 4, 2012)

  • New Opcodes:
  • cell opcode for cellular automata
  • New Gen and Macros:
  • Modified Opcodes and Gens:
  • active now will report total number of active or allocated
  • instruments if argument in zero.
  • stsend and strecv the TCP socket opcodes reworked to a logical design
  • DSSI system now will take up to 9 channels
  • FLsavesnap works with other widgets where imin > imax
  • Utilities
  • csbeats better documented and built by default
  • Some security holes in utilities fixed
  • Frontends
  • Bugs fixed:
  • unirand opcode at arate fixed
  • Locale fix for floating point literals in orchestra
  • transegr fixed
  • If a .sco file did not end in newline it could crash or loop
  • System Changes:
  • Score can now last longer (change to size of time variable)
  • An empty score gives a very long performance time (years and years)
  • Android code released
  • Changes to use of tmp files; now all are deleted at end of run
  • (previously some were left) and the environmnet variable
  • TMPDIR is used.
  • interaction between Comments, end of line and end of file fixed
  • Hexadecimal numbers now allowed in orchestra
  • Empty orchestra now not a crash
  • change to macro expansion inside a string
  • avoid infinite loop when eof in malformed score macro
  • fixed macroname-with-args diagnostics and memory leak
  • change to preprocessor: {{ }} inside "..." and better diagnostics
  • fix windows installer so it removes full $INSTDIR\bin from PATH
  • during uninstall
  • CsoundAC MusicModel class more usable by C++ programs
  • ftcps had been missed as a function
  • API:
  • Internal:
  • Many! Some messages quietened, code implrovements etc