|
3 registered members (NewbieZorro, TipmyPip, 1 invisible),
19,045
guests, and 8
spiders. |
Key:
Admin,
Global Mod,
Mod
|
|
|
Script Execution & Screen Refresh Time
#24260
03/17/04 05:58
03/17/04 05:58
|
Joined: Dec 2003
Posts: 61 Funkytown, USA
feature_creature
OP
Junior Member
|
OP
Junior Member
Joined: Dec 2003
Posts: 61
Funkytown, USA
|
I was working on some physics stuff and I kept running my work in windowed mode -- my script execution time stays at about 1.3-9 ms depending on how many entities I've got spawned and so on -- I'm fine with this rate. The screen refresh time is listed as 0.0-0.1 ms in windowed mode.
When I run the same thing in fullscreen mode -- my script execution time jumps to 13-14 ms but does not change depending on the number of entities I've got spawned. The window refresh time is 0.0 in fullscreen mode here.
Then I noticed something strange (maybe someone else has as well), as I tried to pin down which function was taking all the time, I commented out the most time consuming function and suddenly my script execution time went to nearly zero, but my screen refresh time went to 12-13 ms in full screen mode. In windowed mode my script execution time went to 0, but my screen refresh time went to .7 seconds.
Is it possible that the engine is putting screen refresh time into the bucket for script execution? It seems that it makes it awfully hard to debug if it is...
Any help or insight would be greatly appreciated.
Curious, but not overwhelmed...demlehwrevo ton tub ,suoiruC
|
|
|
Re: Script Execution & Screen Refresh Time
[Re: feature_creature]
#24261
03/19/04 10:12
03/19/04 10:12
|
Joined: Dec 2003
Posts: 61 Funkytown, USA
feature_creature
OP
Junior Member
|
OP
Junior Member
Joined: Dec 2003
Posts: 61
Funkytown, USA
|
Bump.
I'm thinking that there may be a bug in the timing system but before I commit to that I want to know if I'm missing something.
Thanks, Creature
Curious, but not overwhelmed...demlehwrevo ton tub ,suoiruC
|
|
|
Re: Script Execution & Screen Refresh Time
[Re: Templar]
#24263
03/26/04 13:09
03/26/04 13:09
|
Joined: Dec 2003
Posts: 61 Funkytown, USA
feature_creature
OP
Junior Member
|
OP
Junior Member
Joined: Dec 2003
Posts: 61
Funkytown, USA
|
Nada!
Here is my guess about what is going on.
Screen refresh is happening largely in the video hardware while the script execution is happening on the cpu: so you have some parallel processing going on and it is difficult to time these separately. So, I'm guessing that whichever routine returns first gets to be nearly 0, while the other when gets the rest of the time. This would be necessary if all the debug times have to add up to the actual time between frames -- if you time parallel processes the total time would come out too high.
Yeah -- I think parallel processing explains it but the manual should probably explain this when it describes the debug output.
Curious, but not overwhelmed...demlehwrevo ton tub ,suoiruC
|
|
|
|
|
|