Vertex attribute values provided via NV097_SET_VERTEX_DATA2S are
apparently two 16-bit signed integers, packed into 32 bits, which are
then to be directly mapped to floating point values in the range
[-32768.0, 32767.0].
Halo:CE uses this format to provide texture (u,v) coordinates for
render-to-texture techniques, including weapon scope, dynamic shadows,
and radar beacon--all of which are now working as expected with this
patch.
The recent fixes to xid.c (32bf810) didn't make it to xid-sdl.c. This
patch ports over those changes. In the future, the parts common to both
xid.c and xid-sdl.c should be factored out so this doesn't happen again.
Original work done by Jannik Vogel (aka JayFoxRox) on Jul 5th, 2018.
This is the refresh interval used when the user is actively providing
input (moving the mouse around) vs idle. Since this refresh event is
used to create vsync, this can cause some games which use vsync for
timekeeping to advance faster when moving the mouse around or using the
keyboard. For example, in the Halo:CE main menu, when moving the mouse
around the background animation will run a little faster.
Marking all pages as always dirty has some really bad consequences for
the current NV2A emulation. The lesser of two evils for now is to leave
the pages as-is. Eventually this will be replaced by proper dirty page
tracking once HAXM supports it.
QEMU core will call this handler when a RAM block is removed (no
surprises there), but it does _not_ check to see if this handler is
non-NULL. Add a dummy handler for now.
If gpa is exactly the start address of one slot, the
old code fails to find the slot. Change to use one byte
range to find slot.
Change-Id: I169ec8f759bb211a5ea7c693c5d99f27576c2e93
Signed-off-by: Tao Wu <lepton@google.com>