< Back to IRCAM Forum

Unexpected interaction between p-rewrite and p-eop? in Patterns library

Hi everyone,

I’m seeing unexpected behavior when using p-rewrite with p-eop?. I want p-rewrite to output a full generation of items at once instead of concatenating generations based on the length in p-next.

For this i tried to construct a loop that would evaluate each element of p-rewrite until reaching an end-of-period trigger. I assumed that, like with p-cycle, p-rewrite would emit such a trigger after each generation ends. However, as shown in the patch below, it never does:

demo.omp (6.9 KB)

When I run the loop, it never ends because p-eop? never triggers. Am i doing something wrong? Is there a way to achieve what i want? Or should I find a way of calculating the length of a generation based solely on its rules?

Thanks!

Also, as far as i can tell, the :generations key does not affect the output at all, no matter what i try, I think I’m using it wrong or something