Looper duration attribute can't exceed the duration of the file ?

26 views
Skip to first unread message

dennis

unread,
Sep 15, 2021, 10:26:19 AM9/15/21
to pyo-discuss
Hi,

I was playing around with the Looper method, I loaded a few tekno kicks inside, but I can't set the duration of the loop longer than the file length. For instance, I have a kick with 0.38s duration, I'd like to loop it on 0.5s,  but the dur attribute automatically set the max duration  to the duration of the file. Is there a way to correct that or maybe I have to add some blank to my file...?

Thanks, Dennis.

barmin

unread,
Sep 15, 2021, 12:18:16 PM9/15/21
to pyo-d...@googlegroups.com
Maybe use a Pattern object to trigger the playback of the sound instead of a Looper object?

Just my 2¢...

Matthieu

Le 15.09.21 à 16:26, dennis a écrit :

Olivier Bélanger

unread,
Sep 15, 2021, 1:46:39 PM9/15/21
to pyo-d...@googlegroups.com
Hi,

You certainly can do that! This snippet starts the playback every 2 seconds:

t = SndTable(SNDS_PATH+"/transparent.aif")
l = Looper(t, dur=2).out()
l.appendFadeTime(True)

Olivier


--
You received this message because you are subscribed to the Google Groups "pyo-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyo-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pyo-discuss/87d36c32-48eb-46df-9c1f-93ba8e808757n%40googlegroups.com.

dennis

unread,
Sep 16, 2021, 5:24:42 PM9/16/21
to pyo-discuss
Thank you, this works but only without the ctrl panel. When I call the ctrl panel it trigs it a first shot with the indicated time, but right after the loop time goes back to the file length (also the max vale of the dur parameter in the ctrl panel is equal to the file length).

Olivier Bélanger

unread,
Sep 17, 2021, 5:55:27 AM9/17/21
to pyo-d...@googlegroups.com
The maximum of the dur slider in the ctrl panel defaults to the table's duration just because that sounds to be a logical value, but you can override it easily when calling the ctrl() method. Updated example:

t = SndTable(SNDS_PATH+"/transparent.aif")
l = Looper(t, dur=2).out()
l.appendFadeTime(True)
l.ctrl(
    [
        SLMap(0.5, 2.0, "lin", "pitch", 1.0),
        SLMap(0.01, 10.0, "log", "dur", t.getDur())
    ]
)

Olivier


dennis

unread,
Sep 18, 2021, 3:36:31 PM9/18/21
to pyo-discuss
Thanks Olivier, I see I should have checked the tableprocess.py file to get this information.
Reply all
Reply to author
Forward
0 new messages