[fpc-pascal] fpimage BMP and X11 implementation

Graeme Geldenhuys graemeg.lists at gmail.com
Tue Jul 3 09:35:32 CEST 2007


Hi,

I'm trying to implement fpimage support in the fpGUI widget framework.
 I'm really confused at the moment. :)   The following queries apply
to X11 (xlib) only. My GDI (windows) support will come later.

My current BMP image implementation (which doesn't use the fpimage
unit) has an internal TXImage. One for the Mask and one for the Image
Data.

Now creating a descendant of TFPCustomImage, I know I need to
implement the following two methods.

    procedure SetInternalPixel(x, y: integer; Value: integer); override;
    function  GetInternalPixel(x, y: integer): integer; override;

1) Those are the only abstract methods. So where am I supposed to
create the instance of TXImage and assign it the internal data? When
am I supposed to assign the internal data?

2) Am I supposed to descend from TFPCustomImage or TFPMemoryImage?
What's the difference?


Regards,
   - Graeme -



More information about the fpc-pascal mailing list