Ian wrote:I see we are running VBL first and I agree it shouldn't matter if it's at the start or at the end.
But what triggers 'vbl'? The IRQ that gets called? Because calling it after 'VBL' doesn't seem to make any difference
It would be interesting to find out what the correct VBL time actually is. Maybe the guys that did the model2 project would know, I am sure the value is similar for that, given they both use the crazy 57.5 fps.
The IRQ is the primary way that the game gets notified of VBL.
Now I'm confused. I don't quite understand why the games care at all about the duration of the VBL because as you say, we assert the IRQ at the beginning and there isn't really anything that informs the games of start-of-frame/end-of-VBL. The VBL bit would certainly serve that purpose. If you raise the bit at the start of VBL and then lower it when VBL is over, you don't see any improvement in behavior?
One thing we are doing is raising all of the other interrupts at the *end* of VBL. Maybe one of them is being used to drive timing somehow in certain games. However, I seem to recall that most of these are unused. Magical Truck may use some of them. I think I posted about that several months ago.
I've been getting more involved with HoloLens stuff to the point that I have no spare time for anything else it seems. But I need to dig in and examine how the games perform frame timing. I'm not sure where to start because the main game loop can be intimidatingly large but I figure I should perhaps disassemble a few of the games' interrupt handlers and see if any of them do anything interesting. I think we've gotten the farthest with scudplus before. Maybe I'll start poking around next week again.