I have been trying to generate a tone (444 hz, 1000 hz, etc) and then play it in Android. My first searches gave me this stack overflow question. While this works great given a duration, I would prefer to make the duration infinite (loop-able).
First I used only use integer values for the tone, because this would mean that I could use 1 second and it should loop properly. However there are still some frequencies that don't loop right.
Second I thought I could only calculate 1 period of the sine wave, and then loop that. However I found out that is not a viable approach
How can I, given any frequency, generate a tone that I can loop?