Re: requestAnimationFrame time and DOMHighResTimestamp

On Mon, May 14, 2012 at 6:17 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:

> On 5/14/12 6:04 PM, James Robinson wrote:
>
>> I think the best thing to do is to fetch the
>> window.performance.now() for each document in the list
>>
>
> Before firing any callbacks, or before firing the callbacks for that
> document?  Given your proposed optimization, sounds like the former?


Yes, the former.  Otherwise the time delta between different documents will
be variable based on how long the callbacks in earlier documents takes to
run and animations will be jumpier than they otherwise would.

- James


>
>  D'oh.  I even complained to Nat in person about how this was broken, but
>> didn't actually fix it.  I'll just fix this - since the sample only has
>> one frame, it's not really impacted by (1).
>>
>
> Yep.
>
> -Boris
>

Received on Tuesday, 15 May 2012 01:55:54 UTC