I found a bug in the loop itself. Sometimes it only did one second of "update"+"draw" calls and then only "draw" calls. I think it has something to do with the timestamps. If you use raf in the start (as is done in the raf examples as well), then the timestamps are all managed by raf and the problem seems to be solved.
I found a bug in the loop itself. Sometimes it only did one second of "update"+"draw" calls and then only "draw" calls. I think it has something to do with the timestamps. If you use raf in the start (as is done in the raf examples as well), then the timestamps are all managed by raf and the problem seems to be solved.