Csound Csound-dev Csound-tekno Search About

[Csnd] Line opcode rise after end.

Date2008-09-10 12:40
From"Sounddesign@MAIL.RU"
Subject[Csnd] Line opcode rise after end.
Hi! I am trying to use line as DR envelope, but something goes
wrong. It's "return" after rising zero. Here is a CSD...

Thanks.






sr=44100
kr=4410
ksmps=10
nchnls=1

instr 1
kamp    line 1,0.5,0
aout    oscil 16384*kamp,p4*kamp,1
        out aout

endin


; Table #1, a sine wave.
f 1 0 16384 10 1

; Play Instrument #1 for 2 seconds.
i 1 0 1 300
i 1 1 1 400
i 1 2 1 500
e







Date2008-09-10 12:56
From"Jeff Taylor"
Subject[Csnd] Re: Line opcode rise after end.
AttachmentsNone  None  

Date2008-09-10 13:23
Fromluis jure
Subject[Csnd] Re: Re: Line opcode rise after end.
on 2008-09-10 at 06:56 Jeff Taylor wrote:

>kamp    line 1,0.5,0,1, 0

one detail: the opcode should read "linseg", not "line". line accepts
only one segment. 

BTW, if you use linseg, there's no need for the extra segment. i think
i remember (and a simple test seems to confirm it), that linseg changed
its behavior some time ago, and it does keep the last value if the note
is longer than the total duration of the envelope. checking the manual
i see that it has not been updated, though, and the original note is
still there.

unless i'm mistaken, the manual should be updated, and the behavior of
linseg better explained.

best,

lj