BMP Writing Performance

Eddie Cottongim cottonsqueak at earthlink.net
Tue Apr 1 17:47:32 UTC 2003


I noticed that BMP writing is a bit slow. On my system, it took ~10,100ms to
write an 800x600 24 bit image.

So I played with it, and was able to get it to around 1500ms by using
ByteArrays. (The bottleneck in the original version is endian conversion -
nextLittleEndianNumber: is quite slow compared to doing shifts and masks
yourself).

1500 ms is good enough for me, but it can certainly go faster as a plugin. I
see that BMP reading has a plugin already, and its very fast. Should I add a
plugin method for writing? Personally, I'd rather see less plugins than
more, all things being equal. Hopefully, in the long run, a robust vector
library (ByteArray etc) would be a better alternative for many plugin
candiates.

Eddie




More information about the Squeak-dev mailing list