pulled a tick out of girlfriend
underestimated the weight of a 5 year old on your back when swimming in the sea
implemented polyblep to remove aliasing from my cheap sawtooth osc
(it works really well!)
I don't think you have any UB there, as unsigned overflow is defined to wrap, but you do have an overflow (which will roughen the sound) which can be fixed I think by doing `u32 t = phase / ((dphase + 65535) >> 16)`.
-
-
i think my if t<65536 side steps it but your rounding down trick is much nicer, thanks!
-
Ah right, my analysis was wrong that it would overflow, but agree rounding is better because it avoids the branch. Glad to help!
- 1 more reply
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.