missing ease with jit.anim.node for endless sensor value 0.-360.

michel8's icon
I missing the ease option with jit.anim.node for an endless sensor float value 0.-360. from a compass 9DOF. I like to damp/ smoot/ ease the value.
When I use a slide, the value jumps when it cross from 360. to 0. or the other way round. Unfortunately the quaternition will not work with jit.anim.drive, which have the nice ease option. I need the absolut yaw position in the 3D space!
May there is a math to get the circular to an big endless value? Or a othe way to smoot the value? ease alone will not work.
Thanks for help :)
Max Patch
Copy patch and select New From Clipboard in Max.
Rob Ramirez's icon

you could try using the list.ease object (from the Ease package in the Package Manager).
send the output of euler2quat to list.ease, and then to a jit.quat @normalize 1:

Max Patch
Copy patch and select New From Clipboard in Max.

michel8's icon

Hi Rob,
thanks for your fast repaly. Its working, but not like espectet. Maybe I didn't make it clear enough.
I looking for the effekt (damping) like using the slide, a damping when the float value change somewhere inside the full range of 0.-360..
Now with list.ease there is only a damping effect at the crosspoint from 360. to 0. or opposide, which works. (But also it change direction when using in_out_sine). But this is not what I'm searching for. Thanks for help 8]

michel8's icon

I sadly still don't find a solution for this!

Roman Thilenius's icon

dirty workaround: widen the range for thousand times in both directions (i.e. 360*-1000 to 360*1000), interpolate with slide or whatever, then go back to % 360.

michel8's icon

Hi Roman
I also tried this out. But there is no difference. The slide object bounce/spring when it jump/cross from 1360. to 1000 or opposite. Hmm.

Roman Thilenius's icon

ok i see (patch) now, it is a physical endless dial.

that makes it a bit more complicated to extend its range.

when you move that controller fast, will it always send out all numbers?

that tricky phase clock divider problem again. :/

Rob Ramirez's icon

I think roman's got the right idea. just set your counter to some very high number (or simply use accum, not sure what your actual patch is doing with the sensor data), the euler2quat will to the wrapping for you:

Max Patch
Copy patch and select New From Clipboard in Max.

Roman Thilenius's icon

i think he needed to put the slide between the encoding and decoding. (he doesnt have 100000, we need to make this)
euler2quat by wakefield seems to be offline.