[screensaver] use several PNG to create an animation
Phibonacci
Membre
Hello,
I'm trying to use a gif to create a screensaver, just for fun.
I created 35png extract from that gif.
I, somehow, succed but it's getting slower and slower for each new image printed.
I'm using xcode with cocoa.
catsaver.m : http://pastebin.com/raw.php?i=PjBqNvRV
catsaver.h : http://pastebin.com/raw.php?i=bTBgSi8h
I first thought the screen resolution was responsible but it appears that even a low resolution make it laggy at a point.
I hope my english is ok, otherwise just tell me.
Connectez-vous ou Inscrivez-vous pour répondre.
Réponses
Not surprising! Each time you call "animateOneFrame", you add a new NSImageView again and again...
Add your NSImageView in initWithFrame and in animateOneFrame you just need to update its image.
Thanks for you answer, I knew the issue was something like that.
Could you show me a way to update the view instead of overloading it ?
Edit :
I guess I found it even so I have a warning for this IBOutlet declared like that.
Je ne savais pas que Fibonacci était Anglais. Je pensais qu'il était Italien!!
Phibonacci... du coup ça pourrait même être grec...
Non non, un italien, un matheux qui avait de la suite dans les idées!