Hmm,
from my mail logs it looks like this never made it to the list or to
Josu.
Sorry,
Hartmut
---------- Forwarded Message ----------
Subject: Re: PowerPC
Date: Fri, 30 Jul 1999 20:27:22 +0200
From: Hartmut Schirmer <hartmut.schirmer(a)arcormail.de>
On Fri, 30 Jul 1999, Josu Onandia wrote:
>Hi All,
>
>I suscribed to this list a month ago, and I don't see a lot of mouvement on
>the list, so I wonder if GRX is actually being used. If so, perhaps someone
>can help me.
>
>I'm evaluating the possibility of porting GRX to a PowerPC, precisely to a
>MPC823, which has its own on-chip graphics system. I don't need all the
>possibilities of GRX, with a 8 bits per pixel frame, and off-screen bitmaps
>of 1 bit per pixel will be enough.
>
>Any help or suggestion would be very appreciate.
Well,
first tweak grx20.h and add
#define GRX_VERSION_GCC_MPC823 -1
// Replace GCC by your compilers name, if your stuff gets included
// a unique positiv number will be assigned by the GRX maintainers
Now add
#if defined(__GNUC__) && defined(???) // Add the right stuff here
#define GRX_VERSION GRX_VERSION_GCC_MPC823
#endif
Check the definition of GrColor a few lines later
Now tweak src/include/libgrx.h for your system. If you checked all
setting up to
/*
* global library data structures
*/
everything should be fine
Now try to set up a makefile and leave out the fdrivers, vdrivers,
setup and mouse subdirs.
If the highlevel parts of GRX compile, try to compile the setup dir.
If youŽre still lucky, continue with the ram8.c driver from the
fdrivers subdir and the vdrivers/vtable.c file.
If everything worked well, you now have a GRX that can do 256 Color
graphics in memory. I donŽt think teherŽs currently a test that will
check rhis setup. Would be nice if you could submit one ...
That was the easy part. YouŽll have to add support the the vdrivers
subdir so GRX knows how to setup graphics on your system. When done,
add a driver in fdrivers for readpixel and drawpixel. The rest of the
functionality can be taken from src/fdrivers/generic at first
Try to compile the test subdir and check if things work well.
Continue by adding more functions to the frame driver, adding more
color modes, mouse and keyboard-support, ...
Good luck,
Hartmut
PS: At first, second and third view, you shouldnŽt try to figure out
what all those macros inside of GRX do --- ItŽs a really big mess but
very flexible for optimizing GRX. readpixel/drawpixel should work fine
with the usual peek and poke macros from mempeek.h