Sometimes to get modulo 1 and handle negative modulo I've been doing something like float p = (p+1234)%1; I thought it was a quick and fun way to do it in the context of creative coding. It turns out that this can be really bad for precision. So for that animation I was using double instead of float to get smooth movement but now I'm back to float with p = ((p%1)+1)%1;
Etienne Jacob
in reply to Etienne Jacob • • •I thought it was a quick and fun way to do it in the context of creative coding. It turns out that this can be really bad for precision. So for that animation I was using double instead of float to get smooth movement but now I'm back to float with p = ((p%1)+1)%1;
Etienne Jacob
Unknown parent • • •Wilfried Klaebe
in reply to Etienne Jacob • • •mesmerizing...
@bleuje
AutodidaktJΓΆrg
in reply to Etienne Jacob • • •ππππππ
in reply to Etienne Jacob • • •Medea Vanamonde π³οΈββ§οΈ
in reply to Etienne Jacob • • •@josh
Hivemind Carrier Wave
steve cooley
in reply to Etienne Jacob • • •binchicken
in reply to Etienne Jacob • • •Joschi :3
in reply to Etienne Jacob • • •Ard The Rich
in reply to Etienne Jacob • • •- <5 (0 votes)
- <10 (0 votes)
- more (0 votes)
- Don't know (watchdog reset) (0 votes)
Poll end: 2 months ago