Csound Csound-dev Csound-tekno Search About

[Csnd] I Statement Control and Modulation

Date2011-07-27 20:27
FromAustin Stone
Subject[Csnd] I Statement Control and Modulation
Hi all!

I am trying to create a sample looper that can read between different points of a sample. I have a large 30" + file that has repeated vocal phrases.

Is there an opcode that reads from different sample points using control signals? I have only seen samplers that use I-rate variables, such as loscil, diskin2 and a Joachim Heintz udo BufPlay1. But they are getting me where I really need to be.

I don't want to use p-field substitutions such as +, ~, or > because I would rather have playback at a fixed amount of time, or instances or repetition.

I have started to experiment with macros to contain each sample read point, but how can I oscillate through each point at a fixed or random rate?

Is there a way to have control signals in the orchestra target macros for play back? Would they be able to reach into the score to do this?

Thanks for your comments!

Austin

Date2011-07-27 20:55
FromVictor Lazzarini
SubjectRe: [Csnd] I Statement Control and Modulation
One suggestion is to have a simple sample playback instrument, with  
say a table reader and a phasor or a line generator, then
have another controller instrument that will trigger it (using event,  
schedule, scoreline, etc) at different starting points. The
controlling instrument will give you the flexibility to do modulate  
the playback start, length, etc, as you wish.

Other opcodes that might be useful are syncgrain, syncloop and  
flooper2. Oeyvind's partikkel might also be what you need, but it  
takes sometime to master.

Victor
On 27 Jul 2011, at 20:27, Austin Stone wrote:

> Hi all!
>
> I am trying to create a sample looper that can read between  
> different points of a sample. I have a large 30" + file that has  
> repeated vocal phrases.
>
> Is there an opcode that reads from different sample points using  
> control signals? I have only seen samplers that use I-rate  
> variables, such as loscil, diskin2 and a Joachim Heintz udo  
> BufPlay1. But they are getting me where I really need to be.
>
> I don't want to use p-field substitutions such as +, ~, or > because  
> I would rather have playback at a fixed amount of time, or instances  
> or repetition.
>
> I have started to experiment with macros to contain each sample read  
> point, but how can I oscillate through each point at a fixed or  
> random rate?
>
> Is there a way to have control signals in the orchestra target  
> macros for play back? Would they be able to reach into the score to  
> do this?
>
> Thanks for your comments!
>
> Austin

Dr Victor Lazzarini
Senior Lecturer
Dept. of Music
NUI Maynooth Ireland
tel.: +353 1 708 3545
Victor dot Lazzarini AT nuim dot ie





Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-07-28 10:26
Fromjoachim heintz
SubjectRe: [Csnd] I Statement Control and Modulation
hi -
what do you exactly mean by "reading from different sample points using
control
signals"? can you give an example?
in general, you have access to a i-variable at k-time via the reinit
opcode. there are examples and decriptions here:
http://en.flossmanuals.net/csound/ch016_a-initialization-and-performance-pass/
best -
	joachim

Am 27.07.2011 21:27, schrieb Austin Stone:
> Hi all!
> 
> I am trying to create a sample looper that can read between different
> points of a sample. I have a large 30" + file that has repeated vocal
> phrases.
> 
> Is there an opcode that reads from different sample points using control
> signals? I have only seen samplers that use I-rate variables, such as
> loscil, diskin2 and a Joachim Heintz udo BufPlay1. But they are getting
> me where I really need to be.
> 
> I don't want to use p-field substitutions such as +, ~, or > because I
> would rather have playback at a fixed amount of time, or instances or
> repetition.
> 
> I have started to experiment with macros to contain each sample read
> point, but how can I oscillate through each point at a fixed or random rate?
> 
> Is there a way to have control signals in the orchestra target macros
> for play back? Would they be able to reach into the score to do this?
> 
> Thanks for your comments!
> 
> Austin


Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-07-28 20:27
FromAustin Stone
SubjectRe: [Csnd] I Statement Control and Modulation
I am still working out the wording of the project, so please be patient if there is any confusion in what exactly I am trying to do.

I have a long sample of various vocal takes, and I would like to Csound to cycle or randomly shuffle through each take. Ideally I can state the end and start times for each take and have csound play through different point with in the sample.

I can't figure out how to choose start and end points, and then have the instrument select a new start and end point only after the selection has finished.

For instance:
selection 1 is st 0" and e 2"
selection 2 is st 34" and e 37"
selection 3 is st 100" and e 101.5"

I want to randomly choose a selection and play it, when it is finished I would randomly play another selection.
This would go on for a duration set in the score, let's say 20" of playback.

I have gotten close with PlayBuf1, using randh to switch between selection times, but I cannot feed back the selection duration into the frequency of randh at this time.

Is there a way to make a feed back loop? Have not been successful with goto statements :(

@Victor
I'm not sure if syncgrain, syncloop, flooper2, partikkel is getting me where I need to be in terms of playing each selection in the sample?
But the table reader looks very promising, would you mind elaborating? Any examples?



On Thu, Jul 28, 2011 at 5:26 AM, joachim heintz <jh@joachimheintz.de> wrote:
hi -
what do you exactly mean by "reading from different sample points using
control
signals"? can you give an example?
in general, you have access to a i-variable at k-time via the reinit
opcode. there are examples and decriptions here:
http://en.flossmanuals.net/csound/ch016_a-initialization-and-performance-pass/
best -
       joachim

Am 27.07.2011 21:27, schrieb Austin Stone:
> Hi all!
>
> I am trying to create a sample looper that can read between different
> points of a sample. I have a large 30" + file that has repeated vocal
> phrases.
>
> Is there an opcode that reads from different sample points using control
> signals? I have only seen samplers that use I-rate variables, such as
> loscil, diskin2 and a Joachim Heintz udo BufPlay1. But they are getting
> me where I really need to be.
>
> I don't want to use p-field substitutions such as +, ~, or > because I
> would rather have playback at a fixed amount of time, or instances or
> repetition.
>
> I have started to experiment with macros to contain each sample read
> point, but how can I oscillate through each point at a fixed or random rate?
>
> Is there a way to have control signals in the orchestra target macros
> for play back? Would they be able to reach into the score to do this?
>
> Thanks for your comments!
>
> Austin


Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"



Date2011-07-29 09:44
Fromjoachim heintz
SubjectRe: [Csnd] I Statement Control and Modulation
i do understand better now, and i think what you want to do is certainly
possible, and it is not a question about the opcodes (you can do it even
with soundin), but about the structure of your program.

i would use two instruments; one for triggering, and one for playing the
snippets. actually you could do it within one instrument, but splitting
the task gives you much more flexibility. for instance, you can play as
many snippets at the same time as you like, and regardless your general
time has ended, your subinstrument will finish its snippet without
producing a click.

see a code example below - i hope this helps.

	joachim





sr = 44100
ksmps = 32
nchnls = 2
0dbfs = 1

;all possible start- and endpoints
gimarkers ftgen 0, 0, -6, -2, 0, 1.1, 2.5, 3.7, 5.1, 6.3

instr 1 ;trigger instrument
inmarker tableng gimarkers ;number of markers
loop:
indx random 0, inmarker-1 ;index for starting point
istart tab_i indx, gimarkers ;start time
iend tab_i indx+1, gimarkers ;end time
idur = iend-istart ;duration
    timout 0, idur, do
    reinit loop
do:
    event_i "i", 2, 0, idur, istart ;call instr 2
endin

instr 2 ;playing the sections
iskip = p4
aL, aR soundin "myfile.wav", iskip
outs aL, aR
endin



i 1 0 100




Am 28.07.2011 21:27, schrieb Austin Stone:
> I am still working out the wording of the project, so please be patient
> if there is any confusion in what exactly I am trying to do.
> 
> I have a long sample of various vocal takes, and I would like to Csound
> to cycle or randomly shuffle through each take. Ideally I can state the
> end and start times for each take and have csound play through different
> point with in the sample.
> 
> I can't figure out how to choose start and end points, and then have the
> instrument select a new start and end point only after the selection has
> finished.
> 
> For instance:
> selection 1 is st 0" and e 2"
> selection 2 is st 34" and e 37"
> selection 3 is st 100" and e 101.5"
> 
> I want to randomly choose a selection and play it, when it is finished I
> would randomly play another selection.
> This would go on for a duration set in the score, let's say 20" of playback.
> 
> I have gotten close with PlayBuf1
> , using
> randh to switch between selection times, but I cannot feed back the
> selection duration into the frequency of randh at this time.
> 
> Is there a way to make a feed back loop? Have not been successful with
> goto statements :(
> 
> @Victor
> I'm not sure if syncgrain, syncloop, flooper2, partikkel is getting me
> where I need to be in terms of playing each selection in the sample?
> But the table reader looks very promising, would you mind elaborating?
> Any examples?
> 
> 
> 
> On Thu, Jul 28, 2011 at 5:26 AM, joachim heintz  > wrote:
> 
>     hi -
>     what do you exactly mean by "reading from different sample points using
>     control
>     signals"? can you give an example?
>     in general, you have access to a i-variable at k-time via the reinit
>     opcode. there are examples and decriptions here:
>     http://en.flossmanuals.net/csound/ch016_a-initialization-and-performance-pass/
>     best -
>            joachim
> 
>     Am 27.07.2011 21 :27, schrieb Austin Stone:
>     > Hi all!
>     >
>     > I am trying to create a sample looper that can read between different
>     > points of a sample. I have a large 30" + file that has repeated vocal
>     > phrases.
>     >
>     > Is there an opcode that reads from different sample points using
>     control
>     > signals? I have only seen samplers that use I-rate variables, such as
>     > loscil, diskin2 and a Joachim Heintz udo BufPlay1. But they are
>     getting
>     > me where I really need to be.
>     >
>     > I don't want to use p-field substitutions such as +, ~, or > because I
>     > would rather have playback at a fixed amount of time, or instances or
>     > repetition.
>     >
>     > I have started to experiment with macros to contain each sample read
>     > point, but how can I oscillate through each point at a fixed or
>     random rate?
>     >
>     > Is there a way to have control signals in the orchestra target macros
>     > for play back? Would they be able to reach into the score to do this?
>     >
>     > Thanks for your comments!
>     >
>     > Austin
> 
> 
>     Send bugs reports to the Sourceforge bug tracker
>              
>      https://sourceforge.net/tracker/?group_id=81968&atid=564599
>     
>     Discussions of bugs and features can be posted here
>     To unsubscribe, send email sympa@lists.bath.ac.uk
>      with body "unsubscribe csound"
> 
> 


Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-07-30 02:26
FromJim Aikin
Subject[Csnd] Re: I Statement Control and Modulation
It might be easier to start by snipping the audio file apart into separate
files, with one take per file. You can do this easily using Audacity. Then
your audio playback instrument could choose a file at random from the list
and proceed with playback.

--Jim Aikin

--
View this message in context: http://csound.1045644.n5.nabble.com/I-Statement-Control-and-Modulation-tp4640036p4648790.html
Sent from the Csound - General mailing list archive at Nabble.com.


Send bugs reports to the Sourceforge bug tracker
            https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"

Date2011-07-31 22:24
FromAustin Stone
SubjectRe: [Csnd] Re: I Statement Control and Modulation
@Joachim
This is exactly what I was looking for, thank you so much! I ended up adding another table to make the precise end times.

The next step is to get an array to feed in the start and end times.

@Jim
I have thought about making each file separately, but the entire project will be 30+ minutes and it will be easier to have fewer files with a text document indexing everything. Thanks for the interest!

Here is what I have developed from Joachim's previous example:

<CsoundSynthesizer>

<CsOptions>

</CsOptions>

<CsInstruments>

sr = 44100

ksmps = 32

nchnls = 2

0dbfs = 1

;all possible startpoints

gimarkerstart ftgen 0, 0, -6, -2, 0, 2.9, 5.7, 34, 37.9, 41.8

;the corresponding endpoints (really duration in the example)

gimarkerend ftgen 0, 0, -6, -2, 1, 1, 1, 2, 2, 2

instr 1 ;trigger instrument

inmarker tableng gimarkerstart ;number of markers


ioutmarker tableng gimarkerend ;number of end point markers


loop:

indx random 0, inmarker-1 ;index for starting point

istart tab_i indx, gimarkerstart ;start time

iend tab_i indx, gimarkerend ;end time

idur = iend ;duration, not really using endpoints

timout 0, idur, do

reinit loop

do:

event_i "i", 2, 0, idur, istart ;call instr 2

endin

instr 2 ;playing the sections

iskip = p4

a1 soundin "MYSONG.aif", iskip

outs a1, a1

endin

</CsInstruments>

<CsScore>

i 1 0 100

</CsScore>

</CsoundSynthesizer>



On Fri, Jul 29, 2011 at 9:26 PM, Jim Aikin <midiguru23@sbcglobal.net> wrote:
It might be easier to start by snipping the audio file apart into separate
files, with one take per file. You can do this easily using Audacity. Then
your audio playback instrument could choose a file at random from the list
and proceed with playback.

--Jim Aikin

--
View this message in context: http://csound.1045644.n5.nabble.com/I-Statement-Control-and-Modulation-tp4640036p4648790.html
Sent from the Csound - General mailing list archive at Nabble.com.


Send bugs reports to the Sourceforge bug tracker
           https://sourceforge.net/tracker/?group_id=81968&atid=564599
Discussions of bugs and features can be posted here
To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe csound"