Re: Graphic Images

Subject: Re: Graphic Images
From: Dom Lachowicz (
Date: Thu Apr 19 2001 - 18:24:29 CDT

>Why do you think I did fix it :-)
>BTW, gr_UnixGnomeImage should not inherit from gr_UnixImage but from
>gr_Image (or an abstract class should be in beetween), and
>gr_UnixGraphics should not be aware of each of these class, reporting
>the drawing to the image class....
>(it currently calls itself drawing routines which is NOT a good idea

I'll reply to the rest of these statements/comments in a bit, but this one
above is just horribly wrong.

class GR_UnixGnomeImage : public GR_RasterImage

There are a few #ifdefs in GR_UnixGraphics to specifically handle GdkPixbuf
vs. PNG images. As it currently stands, the GR_Graphics class *must* know
about UnixImage vs. UnixGnomeImage, because the createImage() and
drawImage() routines lie there... We're not advanced to the point where we
can say something like the following:

GR_Image * foo = new GR_Image(filename);

In this case, everything could be done entirely XP. But now, we depend on
being able to basically extract RGB(A) buffers from images and paste them
onto drawables in *every* graphics impl, not just Unix. Until we go entirely
XP here (which I doubt that we'll ever do), Graphics _must_ know about
Image's implementation, which is perfectly fine here because *Graphics' role
is a creator/manager/renderer of a specific subclass of GR_Image.

This code is not broken.


Get your FREE download of MSN Explorer at

This archive was generated by hypermail 2b25 : Thu Apr 19 2001 - 18:24:36 CDT