outline for chrono-proportional score
Date | 2017-01-22 15:18 | ||
From | Andrea Strappa | ||
Subject | outline for chrono-proportional score | ||
hi list,
I attach a csd file that I elaborated for drawing
in series of png file the whole sound outline, also very long, of whole sound
processing.
Unfortunately there is't now (I suppose) a way for
saving multiple files named with progressive integer numbers
(gicount).
And I can save only last png file
processed.
Any idea?
Will be a good point on the agenda for next Csound
release?
All the best.
Andrea S.
<CsoundSynthesizer> <CsOptions> ;-n -odac ;-o image_prova_13.wav </CsOptions> <CsInstruments> sr=44100 ksmps=1 nchnls=1 0dbfs=1 gasig init 0
giimagew = 1000 ;image width in pixel giimageh = 100 ;image high in pixel gimage1 imagecreate giimagew, giimageh gicount init 0 ;saved images counter instr 1 ;out process example
ifreq = cpspch(9.00) iexpfun ftgen 1, 0, 16384, 5, 1, 8196, .1, 8196, 1 kintvl oscil 1, .25, 1 asig mpulse 1, kintvl gasig reson asig, ifreq, 20 out gasig * .07 endin instr 2 ;draw outline
iimgsec = p4 ;secs for every image, refresh time reset: timout 0, iimgsec, draw schedule 3, 0, 1 reinit reset draw: kx line 0, iimgsec, 1 ;iimgsec = HOW MANY SECONDS IN A PNG FILE ay follow gasig, .001 ;instr out profile imagesetpixel gimage1, kx, 1-ay, 1, 1, 1 endin instr 3 ;save file
gicount = gicount + 1 print gicount imagesave gimage1, "C:\Andrea\csound\prove_varie\image_prova_13.png" ;for multiple images, it is necessary an opcode for naming file with numeric progression ;is it lacking an opcode that convert integer to string? imagefree gimage1 gimage1 imagecreate giimagew, giimageh endin </CsInstruments> <CsScore>
f0 z ;indefinited performance duration to ensure 'schedule' activation i1 0 6 ;p4 = ifreq i2 0 9 3 ;p4 = iimgsec. Remember to set p3 = 'iimgsec' + p3 of out instr ;i3 is an instrument activated by 'schedule' e </CsScore> </CsoundSynthesizer>
|
Date | 2017-01-22 15:37 | ||
From | Victor Lazzarini | ||
Subject | Re: outline for chrono-proportional score | ||
you can use sprintf for file name strings
Victor Lazzarini Dean of Arts, Celtic Studies, and Philosophy
Maynooth University
Ireland
|