Welcome, Guest. Please login or register.

Author Topic: ScummVM v1.3.1 (current version) ported to 68k RTG  (Read 6001 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Crumb

  • Hero Member
  • *****
  • Join Date: Mar 2002
  • Posts: 1786
  • Country: 00
    • Show all replies
    • http://cuaz.sourceforge.net
Re: ScummVM v1.3.1 (current version) ported to 68k RTG
« on: August 24, 2011, 07:55:01 AM »
Hey!

Using CGX API is quite easy too, you won't have to rewrite much stuff:

I have some old code:

Locking the bitmap:
lockResult=(APTR)LockBitMapTags(myScreen->ViewPort.RasInfo->BitMap,LBMI _BASEADDRESS, &baseScreenAddress,TAG_DONE);

Unlocking it:
UnLockBitMap(lockResult);

Remember to lock and unlock it each frame, if you keep the BitMap locked you could run into problems if CGX or P96 decides to move bitmaps from gfx ram to fast ram :-)

that's all :-)

PS: if you have to perform a memcpy of the whole screen it would be better and more compatible to use WritePixelArray(). If you can give scumm a pointer to the gfx ram and it writes the gfx directly then it will show the advantage.

PS2: I think you should simply advise adding buffers, e.g.:
addbuffers WORK: 2000
and big files will load without problems, just like in ADoom.
« Last Edit: August 24, 2011, 08:03:47 AM by Crumb »
The only spanish amiga news web page/club: Club de Usuarios de Amiga de Zaragoza (CUAZ)
 

Offline Crumb

  • Hero Member
  • *****
  • Join Date: Mar 2002
  • Posts: 1786
  • Country: 00
    • Show all replies
    • http://cuaz.sourceforge.net
Re: ScummVM v1.3.1 (current version) ported to 68k RTG
« Reply #1 on: August 24, 2011, 09:48:55 PM »
Quote from: buzz;656031
I used guifgx in the past when porting hivelytracker, so that it worked on aga and gfxcard machines (the os4 version was originally p96). I wonder how that would work with scummvm, in regards to performance. might be quite ok at least the library seems to be quick anyway from my tests. (written by a demo scener ;-) )


For demoscene purposes it's not really needed either. You only need the base address of the bitmap for stuff that uses the same pixel format. If you don't want to take care of pixel conversions you use WritePixelArray() and that's all. CGX API provides what you may need.
The only spanish amiga news web page/club: Club de Usuarios de Amiga de Zaragoza (CUAZ)
 

Offline Crumb

  • Hero Member
  • *****
  • Join Date: Mar 2002
  • Posts: 1786
  • Country: 00
    • Show all replies
    • http://cuaz.sourceforge.net
Re: ScummVM v1.3.1 (current version) ported to 68k RTG
« Reply #2 on: August 25, 2011, 08:19:00 AM »
Quote from: NovaCoder;656048
The main thing holding me back with adding CGX is that I don't have a system to test it with.   This makes development very difficult and is why I can't add direct chunky 256 color support to ScummVM ECS.

CGX code works on both Picasso96 integrated cgx emulation and CGX. You can also add an ASL requester that only shows CGX modes (using a hook) more or less like Picasso96 screenmode requester. BTW, there's a CGX driver for AGA perhaps it helps to test too.

Anyway... I guess you could support both AGA and RTG in the same release, you would only have to choose CGX or AGA routines depending on the opened screen
« Last Edit: August 25, 2011, 08:22:45 AM by Crumb »
The only spanish amiga news web page/club: Club de Usuarios de Amiga de Zaragoza (CUAZ)