-
avenir
@porres In Pd 0.56, l' [random]oggetto può ora ricevere un numero nell'ingresso sinistro per impostare l'intervallo e generare immediatamente un valore in uscita, mentre l'ingresso destro imposta l'intervallo senza attivare l'output. Accetta anche un seedmessaggio per riprodurre la stessa sequenza. Potresti chiarire se questo significa che il comportamento di base [random](che produce sempre valori compresi tra 0 e N–1) è invariato e che dobbiamo comunque spostare e scalare l'output se vogliamo un intervallo diverso (ad esempio 13–26)?
-
avenir
Thanks for the replies, guys — actually, I managed to do what I needed. I'm sharing the patch with you.
In the end, the result of the samples/ms conversion expression is used to send timing data via r/s in order to retrigger the metro in the main patch.
In Pd, you can load envelopes into wavetablenv~ — I added a couple of sources: an oscillator for the low end, one for the highs, and an else chaos generator.
It seems to work and it’s pretty fun. Let me know if you get a chance to play around with it! -
avenir
Hi everyone,
I'm working on a system to automatically generate a vline~ message list starting from a custom envelope shape stored in an array, originally extracted from a .wav file.
I want to build a dynamic vline~ list like this: 0, 1 93.753, 1 0 187.506
But instead of typing values manually, I'd like to generate it automatically based on the shape of an envelope loaded from a waveform (array).
I already convert the array index to milliseconds using: [expr ($f1 / 44100) * 1000]
And I can manually draw or extract the envelope into an array — but I’m struggling to automate the construction of the vline~ list so it correctly represents:- attacks
- holds
- releases
- plateaus (ecc)
at the moment i Load a .wav file containing an envelope shape, Store it into an array. Detect meaningful breakpoints (e.g. slope changes, thresholds) and Use those to automatically create a proper vline~ sequence.
here the patch and one env wav file
impose-envelope-wavetable-analog.pd
strike-1_6.wavIs there a way to extract breakpoints or slope changes from an array to build a proper vline~ message?
Has anyone implemented something similar (using an envelope from a .wav as a wavetable)?
Would “wavetable envelope” be a good term for this? Is there a better one in Pd terminology?Thanks in advance if anyone has ideas or guidance.
Even partial thoughts or pointers would help a lot!I almost forgot: At the moment, I’m using GPT to convert the vline~ list into the format 0, 1 93.753, 1 0 187.506 (just an example), starting from a total duration in milliseconds — in this case, 2176 ms. This naturally results in very complex lists, like something along these lines:
0, 1 100, 0.6 400 100, 0.3 2000 500, 0.15 3000 2500, 0 10491 5500I’d really like to find a way to resolve this and automate the process, but since I’m still a beginner, I wonder if I’m just making things unnecessarily complicated?
Emiliano
-
avenir
@atux said:
Nice patch.
Just one question: what is the easiest way to make the previous .wav file not stop when the next file starts? That way you would have some overlapping sounds (at most in a certain time interval all the files could play at the same time).
Thanks,Hey, thanks for the kind words!
I'm still pretty new to Pure Data myself, so I don’t have a full solution yet but I totally see what you mean about overlapping sounds.From what I understand, one way to achieve that would be to use multiple [readsf~ 2] objects, one for each potential overlapping sound, and cycle through them. So instead of always opening the next file on the same player, each random file could be routed to a different [readsf~], letting the previous one finish naturally.
If anyone here has a cleaner approach or example, I'd love to learn from it too!
-
avenir
@whale-av Hi David,
just a few thoughts — I noticed it works well with folders containing (maybe only .wav files?) small-sized files. I found this patch on the forum which seems slightly more efficient.How it works:
On the left, you can use the "Open Dir" bang to select the folder, and then use the large bang to randomly play each individual file. I just added a scope and a metro to automate the playback process, but this one seems to work more reliably.It would be great if your patch could also handle larger directories and different file types.
P.S. I found this kind of patch especially useful as a sound explorer, feeding it Ableton project folders — and the wow effect is guaranteed when navigating through the "Processed" and "Freeze" folders!
-
avenir
@whale-av Hi David,
First of all, thank you for sharing the cart-5-vanilla patch — the folder selection and track listing work perfectly.
However, I'm encountering a problem with the Start_Random function.
When I click "Play single", it opens a file dialog correctly and plays the selected file using [readsf~].
But when I click "Start_Random", it only prints the randomly selected filename in the console and updates the tracklist display, but no audio is played.