I've gotten around to pondering over demo timing (demos ala scene.org, not game demos) and I was wondering if anyone had any good links on where to find information about how people do the timing in their demos.
Obviously I can think of a few simple ways, but I was wondering if there was any better way of doing it than just keeping track of the number of seconds or music ticks elapsed and passing it through to the effects.
Anyway..
Jx
Demo Timing
Started by jinx, Apr 24 2004 04:56 PM
3 replies to this topic
#1
Posted 24 April 2004 - 04:56 PM
I am extraordinarily patient, provided I get my own way in the end.
#2
Posted 24 April 2004 - 11:38 PM
cut your framerate...
If Prolog is the answer, what is the question ?
#3
Posted 25 April 2004 - 09:38 AM
The best way to do it is to use time-based movement. At least that's what I did in my two demos. Basically for each frame, you find out how many milliseconds have passed since last time and multiply any constants by that. Say object A moves 10 units per second. You'd figure out how many units it moves per milliseconds (0.01 in this case) and do TimePassed * 0.01f. That way if the demo slows down, and it takes 2 milliseconds instead of 1 to render each frame, then you move twice as far per frame, so it all cancels out.
baldurk
He who knows not and knows that he knows not is ignorant. Teach him.
He who knows not and knows not that he knows not is a fool. Shun him.
He who knows not and knows that he knows not is ignorant. Teach him.
He who knows not and knows not that he knows not is a fool. Shun him.
#4
Posted 25 April 2004 - 09:46 AM
which at times can still produce jittery results. the best thing is to fix the framerate to 30 or 60 fps and do what baldurk suggested
If Prolog is the answer, what is the question ?
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












