bitmap, load and save. lazarus / 39-Graphics ---------------------------------------------------------------------- marmin · 2005-03-17 23:21 Problem!   form1.canvas.brush.color:= clBlack;   BitMap1 := TBitMap.create;   Bitmap1.Loadfromfile('test1.bmp');     bitmap1.canvas.moveto(1,1); bitmap1.canvas.lineto(4,4);   bitmap1.savetofile('test2.bmp'); gives'Acces Violation' run-time error , when writing. If I omit the pixel edit , things work perfectly. Could this be anything to do with a DDB? help. ---------------------------------------------------------------------- Lightning · 2005-03-18 11:01 What version of Laz/FPC are you using ? ---------------------------------------------------------------------- marmin · 2005-03-18 19:48 ohoh.. This is a Lazarus bug. I have just tested the same code in Delphi 6 and it's working fine. ---------------------------------------------------------------------- marmin · 2005-03-19 03:34 ah i d-loaded the latest snapshot and it's fixed ! nice work. cuz I was working on a nice Lazarus Icon Editor- bitmaps still give strange color conversion results. - what is the format of an Icon for Linux? - how can I convert tcolor to tfpcolor? ---------------------------------------------------------------------- Nisbo · 2005-03-19 13:14 mmmm sorry but it doesnt work on my site Image1.Picture.Bitmap.SaveToFile('TestBitmap.bmp'); TestBitmap.bmp is a black picture ---------------------------------------------------------------------- Nisbo · 2005-03-21 15:45 no idea ? Bitmap --> SaveToFile buggy ? ---------------------------------------------------------------------- marmin · 2005-03-21 18:35 I don't think it's the savetofile. (I'm working in win32). The problem occurs when doing a canvas operation, like rectangle. Saving the win32 bitmap gives strange color results. xpm files editing, loading and saving, however, work.