Welcome, Guest. Please login or register.

Author Topic: amiga.library  (Read 2575 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline motorollinTopic starter

  • Hero Member
  • *****
  • Join Date: Nov 2005
  • Posts: 8669
    • Show all replies
amiga.library
« on: September 12, 2006, 08:08:06 PM »
I had a thought today, while I was writing some shell scripts to automate launching classic games on my Pegasos.

It would be really cool if the core of UAE could be made into "amiga.library". There would then be "aga.library" and "ecs.library" depending on the graphics requirements of the game, and "68000.library"-"68060.library" for emulating different processors. These extra libraries would in effect be modules of amiga.library.

When a classic game is started, MorphOS' 68k emulation would kick in. If the emulation detected the custom chips were going to be used, it would automatically redirect this to amiga.library. amiga.library would be able to tell which graphics library (aga/ecs) and which processor library (68000-68060) to use.

Basically, the game would still be running in UAE. But instead of mucking about with UAE config files and shell scripts to launch the game, it would be taken care of automatically by MorphOS and amiga.library.

I don't know if this kind of thing is feasible, or even desirable. It was just a crazy idea I had :-)

--
moto
Code: [Select]
10  IT\'S THE FINAL COUNTDOWN
20  FOR C = 1 TO 2
30     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NAAAA
40     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NA-NA-NAAAAA
50  NEXT C
60  NA-NA-NAAAA
70  NA-NA NA-NA-NA-NA-NAAAA NAAA-NAAAAAAAAAAA
80  GOTO 10
 

Offline motorollinTopic starter

  • Hero Member
  • *****
  • Join Date: Nov 2005
  • Posts: 8669
    • Show all replies
Re: amiga.library
« Reply #1 on: September 12, 2006, 08:11:59 PM »
Yes, it would use leirbag's 8MB chip ram hack :lol:

--
moto
Code: [Select]
10  IT\'S THE FINAL COUNTDOWN
20  FOR C = 1 TO 2
30     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NAAAA
40     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NA-NA-NAAAAA
50  NEXT C
60  NA-NA-NAAAA
70  NA-NA NA-NA-NA-NA-NAAAA NAAA-NAAAAAAAAAAA
80  GOTO 10
 

Offline motorollinTopic starter

  • Hero Member
  • *****
  • Join Date: Nov 2005
  • Posts: 8669
    • Show all replies
Re: amiga.library
« Reply #2 on: September 12, 2006, 08:49:13 PM »
Quote
Piru wrote:
Quote
When a classic game is started, MorphOS' 68k emulation would kick in. If the emulation detected the custom chips were going to be used, it would automatically redirect this to amiga.library.

This is where it fails. To detect such access, the application needs to be started. Once custom chip access would be detected, the application would need to be frozen (Emulation can't know how to quit it in the middle of execution). So you would end up with stuck executable that could for example hold critical OS semaphore, and lock up the whole system.

Would it make any difference if the amiga.library was started before the 68k app?

Quote
Piru wrote:
Another problem is that there is no way for the emulation to know how the application was started. In fact, the emulation doesn't even know which application some code belongs to (well you could look into seglists, but lot of stuff use custom decrunchers and such which AllocMem the destination buffer). The MorphOS 68K emulation is totally transparent, there is no difference in PPC and 68K applications. Regardless, even if the emulation could idenfity the seglist, it still wouldn't know how to launch it with UAE.

Hmmm, tooltype maybe? If the icon has the tooltype "classic" then it uses amiga.library.

Quote
Piru wrote:
However, it's very possible to have adf doubleclick to launch uae (trivial with new Ambient). That laucher could for example have UAE config database for various adfs, maybe identified with MD5SUM or filename.

Well, have written shell scripts to automate launching of UAE. But you still have to duplicate the script and modify it with the correct path every time you get a new game.

Quote
Piru wrote:
Oh, and 68040.library and 68060.library names conflict with system libraries (MorphOS refuses to OpenLibrary libraries with these names to avoid compatibility issues).

I did wonder that. Well, it's simple: use 680x0emu.library.

--
moto
Code: [Select]
10  IT\'S THE FINAL COUNTDOWN
20  FOR C = 1 TO 2
30     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NAAAA
40     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NA-NA-NAAAAA
50  NEXT C
60  NA-NA-NAAAA
70  NA-NA NA-NA-NA-NA-NAAAA NAAA-NAAAAAAAAAAA
80  GOTO 10
 

Offline motorollinTopic starter

  • Hero Member
  • *****
  • Join Date: Nov 2005
  • Posts: 8669
    • Show all replies
Re: amiga.library
« Reply #3 on: September 12, 2006, 09:48:05 PM »
Ok, so it was a bad idea :-)

--
moto
Code: [Select]
10  IT\'S THE FINAL COUNTDOWN
20  FOR C = 1 TO 2
30     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NAAAA
40     DA-NA-NAAAA-NAAAA DA-NA-NA-NA-NA-NA-NAAAAA
50  NEXT C
60  NA-NA-NAAAA
70  NA-NA NA-NA-NA-NA-NAAAA NAAA-NAAAAAAAAAAA
80  GOTO 10