#ifndeforchestra#ifndefOrchestra Syntax:Macros#ifndef#ifndef
Conditional reading of code.
Description
Macros are textual replacements which are made in the orchestra as it is being read. The orchestra macro system in Csound is a very simple one, and uses the characters # and $ to define and call macros. This can save typing, and can lead to a coherent structure and consistent style. This is similar to, but independent of, the macro system in the score language.
If the specified macro is not defined then #ifndef can
incorporate text into an orchestra upto the next
#end.
Syntax#ifndef NAME....#else....#endPerformance
Note that the #ifndef can be nested, like in the C preprocessor language.
Examples
Here is a simple example of the conditional.
Simple example of the #ifndef form.#define final ##
instr 1
#ifndef final
print "calling oscil"
#end
a1 oscil 32000,440,1
out a1endinSee alsoOrchestra MacrosCreditsAuthor: &namejohn;University of Bath/Codemist Ltd.Bath, UKApril 2005New in Csound5 (and 4.23f13)