↧
User-defined Functions: How to Make a User-defined Function
Take the following example: ''' Music with A and B sections ''' from earsketch import * # initialize Reaper init() setTempo(120) # Create an A section fitMedia(Y01_GUITAR_1, 1, 1, 5) # guitar...
View ArticleUser-defined Functions: What are User-defined Functions?
fitMedia(), setTempo(), init(), play(), and range() are all examples of functions. These are functions provided and defined by EarSketch. But you can also create your own functions. User-defined...
View ArticleVariable Scoping and Return Values
In the previous section, we encountered a script that created a short composition consisting of an A section followed by a B section, and then the return of the A section. Here is that code: ''' Music...
View Article