Still, diskin2 should do what you want, it is the skiptime option:
a1[, a2[, ... aN]] **diskin2** ifilcod[, kpitch[, iskiptim \ ...
So you could use in your instrument
iSkipTime = p4
aSignal diskin2 "file.wav", 1, iSkipTime
or use soundin that has the skiptime right after filename if you don't need anything else from diskin:
ar1[, ar2[, ar3[, ... a24]]] **soundin** ifilcod [, iskptim] [, iformat] \
Kontakt David Bellows (<email@example.com>) kirjutas kuupäeval T, 24. august 2021 kell 08:41:
I do very simple things in Csound and as such struggle when going past
playing back a sine wave, for example.
Here’s what I’m hoping to do.
I have a .wav file that is 60 seconds long. I want to be able to have
a Csound score that will play back parts of that .wav file starting at
arbitrary points of time within the wav file. Here is what some code
might look like:
i 1 0 5 45
i 1 5 10 20
So from seconds 0 to 5, Csound would play back the .wav file starting
at 45 seconds of the wave file. And then for the next five seconds
play back the .wav file starting at the 20th second of the wav file.
If I can further control the amplitude of the playback in the score
section then that would be of huge help also.
I tried diskin2 but I don’t think it has this capability, or at least
I couldn’t figure it out.
I am running Csound 6.16 on Ubuntu 21.04.
Csound mailing list
Send bugs reports to
Discussions of bugs and features can be posted here
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here