Skip to content

Commit

Permalink
Make warp mode controllable by Amiga code.
Browse files Browse the repository at this point in the history
  • Loading branch information
cahirwpz committed Jan 2, 2025
1 parent afc13d1 commit ab8f198
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 1 deletion.
32 changes: 32 additions & 0 deletions patches/fs-uae/uaelib-warpmode.diff
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
Index: demoscene-toolchain/submodules/fs-uae/src/uaelib.cpp
===================================================================
--- demoscene-toolchain.orig/submodules/fs-uae/src/uaelib.cpp
+++ demoscene-toolchain/submodules/fs-uae/src/uaelib.cpp
@@ -27,6 +27,7 @@
#include "gensound.h"
#include "picasso96.h"
#include "filesys.h"
+#include "inputdevice.h"

/*
* Returns UAE Version
@@ -329,6 +330,11 @@ static uae_u32 emulib_Minimize (void)
return 0; // OSDEP_minimize_uae();
}

+static uae_u32 emulib_WarpMode(uae_u32 mode) {
+ warpmode(mode ? 1 : 0);
+ return 1;
+}
+
static int native_dos_op(TrapContext *ctx, uae_u32 mode, uae_u32 p1, uae_u32 p2, uae_u32 p3)
{
TCHAR tmp[MAX_DPATH];
@@ -373,6 +379,7 @@ static uae_u32 uaelib_demux_common(TrapC
case 15: return emulib_Debug();

case 40: return emulib_Log(ARG1);
+ case 41: return emulib_WarpMode(ARG1);

case 68: return emulib_Minimize();
case 69: return emulib_ExecuteNativeCode();
3 changes: 2 additions & 1 deletion patches/series
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
ld-extra-chip-sections.patch
gcc-2.95.3-amigahunk-fix.patch
gcc-2.95.3-bss-section.patch
gdb-line-addr-fix.patch
fs-uae/break-on-illegal.diff
fs-uae/break-on-sigint.diff
fs-uae/break-at-start.diff
Expand All @@ -12,4 +13,4 @@ fs-uae/uaelib-log.diff
fs-uae/data-path-macos.diff
fs-uae/silence-logs.diff
fs-uae/debug-msg-fix.diff
gdb-line-addr-fix.patch
fs-uae/uaelib-warpmode.diff

0 comments on commit ab8f198

Please sign in to comment.