x404.co.uk
http://www.x404.co.uk/forum/

Boom! New algorithm!
http://www.x404.co.uk/forum/viewtopic.php?f=4&t=17250
Page 1 of 1

Author:  Fogmeister [ Tue Sep 18, 2012 10:17 pm ]
Post subject:  Boom! New algorithm!

Woop!

Well tonight was productive! I wrote a new drawing algorithm for my Game of Life app!

http://itunes.apple.com/gb/app/game-of- ... 39315?mt=8

The bottle-neck in the current version is how fast (or should I say slow) the drawing algorithm is when the screen is almost full and very random. I knew hat to do to fix it about 3 months ago but I didn't know how to implement what I knew to do. Well, tonight I figured it out.

It takes the performance (of a full and random screen) from about 2-3 FPS to about 60 FPS :D

Very pleased. Now there is one more feature to add before my next release!

Author:  finlay666 [ Fri Sep 21, 2012 12:58 pm ]
Post subject:  Re: Boom! New algorithm!

As far as algorithms go I found a very elegant (although slow) system for Fibonacci calculations in C#

http://paste2.org/p/2236575

Code:
public IEnumerable<int> Fibs {
   get {
      yield return 1;
      yield return 1;

      foreach (var n in Fibs.Zip (Fibs.Skip (1), (x, y) => x + y))
         yield return n;
   }
}

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/