[fpc-pascal] FPImage and GetDataLineStart

Marco van de Voort marcov at stack.nl
Thu Apr 21 11:41:27 CEST 2011


In our previous episode, Sven Barth said:
> Am 20.04.2011 22:20, schrieb Leonardo M. Ram?:
> > Hi, I need to write a function that replaces TLazIntfImage by using fpImage, and I can't find an alternative to GetDataLineStart. How can I replace it?.
> 
> Maybe I get your intention wrong, but TLazIntfImage is already using 
> fpImage and it derives from a TFPCustomImage itself.

True, but TFPCustomImage is abstact wrt memory layout and doens't provide
row level access, only pixel level access.

Only TFPMemoryImage adds the memory access, but IIRC only 64-bit pixels.
(16-bit RGBA)

While these abstractions make it easy to make fp/fcl-image somewhat
complete, they are also very memory hungry and slow.

IIRC I accelerated loading/saving simple 8-bit BMP images 20 to 50 times in
my work code.




More information about the fpc-pascal mailing list