PDA

View Full Version : Photoshop bitmaps and Delphi 6 bug



Legolas
26-06-2005, 06:30 PM
Hi all!
Some days ago I tried to load a bitmap made with photoshop in a TImage, but I got a "stream load error". Ok, I tried to do the same thing with Graphics32 and GraphicEx, but no way. At this point I googled a bit and I found that it is a bug in graphics.pas that prevents to load bitmaps made with recent versions of photoshop. Someone tried to patch this? How?

Paulius
26-06-2005, 07:31 PM
I'm just guessing, 'cause I can't afford Photoshop, perhaps you're using some weird format, like with an alpha channel or something, normally bitmaps should only be palleted or 24 bit

Legolas
26-06-2005, 11:35 PM
I'm just guessing, 'cause I can't afford Photoshop, perhaps you're using some weird format, like with an alpha channel or something, normally bitmaps should only be palleted or 24 bit

I can't afford photoshop too; I used a bitmap from a friend of mine. :)
Not weird formats at all. I have opened the "strange" bitmap with gimp and saved again with different name: this new bitmap, with same resolution, color, depth and so on, loads nicely into tImage :shock:

Legolas
27-06-2005, 12:04 AM
Updates... I found this:
http://qc.borland.com/wc/qcmain.aspx?d=8398
It is a photoshop bug, that adds 2 bytes at the end of the bmp so Delphi can't load it.
Now I think: this photoshop bug is known since Delphi3, and today Delphi 2005 still can't handle it. At the same time adobe does not have fixed this bug at all. Why?!? They are trying to drive me crazy?? :scratch: