- fixed possible crash in driver_window dtor (image data would be freed twice,
once by XDestroyImage() and once in driver_base dtor)
- fixed compilation problems with banked memory
- fixed typos
to "true". This uses the BSD socket API, so it's fairly portable (currently
only imeplemented under Unix, though). This works by sending raw Ethernet
packets as UDP packets to a fixed port number ("udpport", default is 6066),
using IP broadcasts to simulate Ethernet broad- and multicasts. Currently
only tested with AppleTalk.
- ADBMouseMoved(), ADBMouseDown/Up() and ADBKeyDown/Up() trigger the ADB
interrupt
- ADB mutex is only used for mouse movement (the only input state where it
matters)
- adb.cpp: toggling relative mouse mode resets mouse_x/y
- PrimeTime(0) schedules a timer task with 0 delay time; this is still not
the correct implementation, but it makes MacSyndicate work...
- Unix: pthreads are preferred to POSIX.4 timers for 60Hz ticks because the
timers drift badly under Linux and the thread can compensate for drifting
well enough
- Unix: moved GetTicks_usec() and Delay_usec() to timer_unix.cpp
- video_x.cpp: X mouse acceleration is disabled in relative mouse mode because
MacOS does its own acceleration
- video_x.cpp: palette[].pixel and palette[].flags are always preset
- video_x.cpp: decoupled X event handling from 60Hz video refresh cycle by
using select() with a timeout on the X fd
of the internal structures used for the VOSF system
- use vm_acquire()/vm_release() for VOSF buffers and hope the_buffer is
allocated above RAM address space (temporary workaround for 64-bit
addressing systems)
- don't free() screen buffers in driver_base dtor
- don't free() memory mapped buffers in driver_base dtor
order. No host memory region used for Mac emulation (ScratchMem, RAM, ROM,
frame buffer) shall be allocated below the RAM space. Actually, MEMBaseDiff
should be set to the min(above-mentioned address spaces).
==> Temporary fix for 64-bit addressing systems (e.g. Linux/ia64)
of MacOS before 7.6:
- Apple mode IDs are now allocated contiguously from 0x80 (the video_*.cpp
module must call video_init_depth_list() after adding all modes)
- if the video driver didn't receive a GetVideoParameters call, it patches
ScrnBase and the main GDevice upon a video mode switch (otherwise MacOS
will continue to use the old frame buffer base)
- the rowBytes values in the video parameters slot resources are correct
for all bit depths
implemented under Unix
- adb.cpp uses mutexes for thread-safe mouse handling
- video_x.cpp: pressing Ctrl-F5 in windowed mode switches to a "grabbed"
relative mouse mode, useful for some games
- video_x.cpp: fixed some bugs relating to the hotkeys (key releases are no
longer treated as hotkeys)
linked list
- color depth switching updates slot ROM
- video_x.cpp always supports 1-bit window modes
- timer_create()/clock_gettime() are pulled from librt if present
However, vm_init() and vm_exit() are called in main_unix.cpp to ensure proper
initialization of the internal zero_fd descriptor, if needed. i.e. no
anonymous mapping for mmap()-based memory allocation.
resolutions are 512x384, 640x480, 800x600, 1024x768 and 1280x1024 (the prefs
editor has to be updated to reflect this). The resolution selected in the
prefs editor is used as the default, but it can be changed in the Monitors
control panel. So far only tested with direct addressing.
contains all supported depths, default mode is stored in XPRAM upon startup,
and added video_switch_to_mode() call (currently unimplemented in all drivers)
- added uniform virtual memory allocation
(supports mmap(), vm_allocate(), or fallbacks to malloc()/free())
- cleaned up memory allocation in main_unix.cpp