Corona simulation challenge

Discussions about the BBC BASIC language, with particular reference to BB4W and BBCSDL
User avatar
hellomike
Posts: 192
Joined: Sat 09 Jun 2018, 09:47
Location: Amsterdam

Re: Corona simulation challenge

Post by hellomike »

But with the POINT() or TINT() approach, I think there is no need for an inner FOR J% loop which speeds things up again.

Anyhow thanks for all the advise. The challenge was of course already accomplished by your smart solution.
RichardRussell

Re: Corona simulation challenge

Post by RichardRussell »

hellomike wrote: Wed 18 Mar 2020, 19:11 But with the POINT() or TINT() approach, I think there is no need for an inner FOR J% loop which speeds things up again.
You underestimate how slow POINT() and TINT() can be in BBCSDL, at least on some of the supported platforms (don't use Windows as a guide, it is not typical). This is what the SDL documentation says: "WARNING: This is a very slow operation, and should not be used frequently", you are suggesting calling it 200 times per frame!