Sin and Cos Slow?

Blitz3D Forums/Blitz3D Beginners Area/Sin and Cos Slow?

The Forum Archive is locked. These are the original blitzbasic.com forums, kept so their posts can still be read and searched. No new topics, replies or edits can be made here. To join the conversation, head over to the Blitz3D+ forums.

Use a lookup table like soja said.

Try this:
dim sintable#(360)

for x = 1 to 360
sintable(x) = sin(x)
next

then, later in your code, use sintable(60) instead of sin(60). It ends up being much faster.


-Later