Matthias wrote 28 lines
ok.
The LCL will support device/platform dependent graphics.
Do you mean gtk/gtk2/qt/win32/... specific?
I think, speed is very important and so we need the possibility to load graphics with less mappings/conversions as possible. For instance an image should not be loaded with calls to SetPixel.
Of course not.
And I guess, we can't simply emulate the VCL and their win32 bitmaps.
I think it would make sense to have a TDIB (device independent bitmap) that stores images as RGB(+Alpha) arrays with 24bit depth and a DPI setting to start with.
This could later be extented to support 1bit, 8bit and other depths. Palette formats are not so important these days.
The TDIB would go in the FCL as well as low level image file format implentations like BMP, XPM, PNG, JPG, TIFF, GIF, ... whatever.
It would be nice to be able to plug-in image format implementations so that for example one could have PNG via libpng or via native Pascal implementation.
They should descent from a common abstract image class like TGraphic. This would require TGraphic to be moved to the FCL.
All image format implementations must be able to assign from/to the TDIB format performing conversion if necessary.
Maybe for the LCL TDIB could be integrated with TBitmapImage in order to be able to share DIB's amoung several components?
Device dependent bitmaps are only useful to save memory and provide for fast GUI redrawing on non-true-color-displays, aren't they?
-Stefan
____________________________________________________________________________ Jetzt bei WEB.DE FreeMail anmelden = 1qm Regenwald schuetzen! Helfen Sie mit! Nutzen Sie den Serien-Testsieger. http://user.web.de/Regenwald
