Forums > Gen

gen~ phase accumulator problem

August 1, 2013 | 1:01 pm

Hello,
I’ve just begun to work on gen~, so probably my question is not so brilliant. I was looking to the example gen~.pulsar and I can’t really understand the role of the object counter to accumulate the phase. As the object receive no signal, but only a param, I can’t grasp why the result It’s a number that ramp between 0 and 1 (..the phase!!); I would expect a constant value from that calculation…Probably there’s something very fundamental of gen~ that I’m not able to understand

thanks

<code>

– Pasted Max Patch, click to expand. –

</code>


August 1, 2013 | 4:34 pm

The first inlet of the counter object takes the number to be added per sample.

So if you send it 0.1, every sample 0.1 will be added to the count.
The first argument limits this so that it wraps between 0. and 1.


August 2, 2013 | 12:33 am

thanks for the answer, but my problem It’s about the fact that counter is receiving a parameter, that should be a constant. Because, reasoning as a max-er, the envelop is generated after the counter. So, about what you have said to me, where are the samples that made the counter to increment ?

thanks


August 2, 2013 | 2:51 am

"where are the samples that made the counter to increment ?"

they are always there, incrementing away. the gen~ graph is ‘always on’, constantly incrementing at 1 sample at a time. the moment counter receives any non-zero into it’s first inlet, the incrementing will start. also, you have given counter an argument ’1′, which means it will wrap whatever the increment value is by 0. -> 1. .

your counter is constantly incrementing whatever your param constant is, at a rate of 1 sample @samplerate.

is that what you are wondering? (it seems your patch works fine).


Viewing 4 posts - 1 through 4 (of 4 total)