New topic: Threaded animation with timer
<http://forums.realsoftware.com/viewtopic.php?t=34257> Page 1 of 1 [ 3 posts ] Previous topic | Next topic Author Message atarikid Post subject: Threaded animation with timerPosted: Sun Jun 13, 2010 7:06 am Joined: Wed Feb 04, 2009 1:43 pm Posts: 232 I use a simple timer to animate a canvas. I tried to do this in a thread but it doesn't seems to work correct. I mean, the animations starts but as soon as there is a heavy calculation involved, the animation starts to stutter. I need a animation which is always running smoothly. Any ideas? EDIT: I have to rephrase my question. It seems I cannot get a timer to work in a thread. The timer fails to even start. Top rbasic20091005153 Post subject: Re: Threaded animation with timerPosted: Sun Jun 13, 2010 7:33 am Joined: Sat Apr 04, 2009 5:10 pm Posts: 944 Basically, you are suggesting that we take a wild guess to pick a needle in a hay stack as you provide no code. How are you rotating pictures? With Case or with... I have no clue. How does Thread come in? I have no clue. _________________ Mac OS X 10.5.8/REALBasic 2008 R5.1 ~ REALBasic 2009 R4 -------------------------------------------------- Please don't use my topics in order to advertise your plug-ins. Watch out for European spammers who try to sell plug-ins you don't even need. Top atarikid Post subject: Re: Threaded animation with timerPosted: Sun Jun 13, 2010 11:14 am Joined: Wed Feb 04, 2009 1:43 pm Posts: 232 Initially I had to include some code. But my questions was kinda simple and understandable without code. Question : "How to use a Timer in a thread?" Make a thread class. Inside this class you define a timer. The problem is you cannot start the timer. It just doesnot trigger any events. But I know he answer now : It cannot be done. Not with the default Timer that is. However, with NSTimerMBS it is possible! I have managed to get it working in the end. Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 3 posts ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
