GetDIBits vs. Scanline vs. Pixels[] in Delphi Bitmaps
I've been always wanting to sit down one day and solve this problem; test the speed of manipulating pixels on a Bitmap using the three options: - the convenient but understandably slow Pixels[], - the "interesting" Scanline property and - the Windows API GetDIBits and SetDIBits. I have been traditionally using Pixels for quick work and the Get/SetDIBits for low-level pixel manipulation such as the filters used in ToolBox . Never really used the Scanline property in anger, I was always thinking, DIBits "had" to be quicker. Little I knew... I have been experimenting with two tools that I've written and never released to the public domain. The first is the BMPCreator which I wrote in order to create 256-level grayscale bitmaps, the other is the IconCreator which uses a grayscale bitmap and applies color maps to it, giving you the ability to create different colored versions of the same icon (like in my database visualization tool VirtualTreeNavigator ). Yesterd...
Comments