Well, there is an OpenSim.ini parameter for setting the minimum time
that a timer can ask for, and the default is 0.5 seconds.
So if you didn't change that, and you are trying to time 0.1s intervals,
you should always be off by a huge amount, your results look better than
that!
As a scripter who wants to write code that is portable around the
metaverse, I have to assume that 99.999 percent of the systems out there
have the default setting and therefore I should never count on a timer
going faster than once every 0.5 seconds.
Then there are other fundamental limits like the 11 times a second
heartbeat of OpenSim. This makes me suspect that if I want accurate
times, I have to time everything in increments of 0.0909090909 seconds.
AND THEN there is llSleep, which should be able to accurately time
things shorter than 1/11th of a second, but it does so by locking up one
of the script threads. That is a whole 'nother can of worms....
On 3/19/2016 4:43 PM, Jeff Kelley wrote:
I always thought that llSetTimerEvent was grossly inaccurate when
working with fast timer (~ 0.1s) and this opinion is shared among
scripters.
That's only true on MONO.
I recently had a try on Windows. The difference is shocking.
Typical Linux figures :
[13:49] Primitive: 99.913000
[13:49] Primitive: 100.266000
[13:49] Primitive: 100.483000
[13:49] Primitive: 99.974000
[13:49] Primitive: 100.312000
[13:49] Primitive: 100.013000
[13:49] Primitive: 134.192000
[13:49] Primitive: 100.383000
[13:49] Primitive: 100.304000
Admit it, that's just crap.
Windows :
[13:44] Primitive: 100.000200
[13:44] Primitive: 100.000100
[13:44] Primitive: 100.000100
[13:44] Primitive: 100.000200
[13:44] Primitive: 100.000100
[13:44] Primitive: 100.000200
[13:44] Primitive: 100.000100
[13:44] Primitive: 100.000100
[13:44] Primitive: 100.000200
That's a near-perfect clock.
Times in milliseconds.
MinTimerInterval = 0.05
Is there anything we can do to make MONO less crappy?
-- Jeff
_______________________________________________
Opensim-dev mailing list
[email protected]
http://opensimulator.org/cgi-bin/mailman/listinfo/opensim-dev
_______________________________________________
Opensim-dev mailing list
[email protected]
http://opensimulator.org/cgi-bin/mailman/listinfo/opensim-dev