Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Galfar

Pages: [1] 2 3 4 ... 25
Could you please upload your test BMP file here?

Thanks for the report, I'll have a look at this.

Bugs And Other Insects / Re: Can't load jpeg image
« on: 21 January 2019, 17:45:19 »
I also have this problem as well.

Please try the latest version from the repository.

Help & Questions / Re: fpc compiler warnings in png decoder
« on: 21 January 2019, 14:50:39 »
"if entropy^.restarts_to_go >0 then" in imjdhuff.pas is safe.
I had it in Imaging branch used in my Deskew tool for years and probably
forgot to merge it to the main branch.

I also did tests with "ptr2int = ptruInt" for zlib and everything was fine
so I pushed both changes to the repository.

Help & Questions / Re: fpc compiler warnings in png decoder
« on: 2 December 2018, 02:23:44 »

I think best would be to try PtrUInt and check if there are any problems (loading and saving PNGs is where zlib is ued in Imaging).
Keep in mind that the comment is maybe 20 years old now from the times of Delphi v3 or something like that.

Quick google search found some updated zlib -> Pascal translation where"ptr2int = NativeUInt"  and in FPC "NativeUInt = PtrUInt".
Also when I look where ptr2int is used and to the original C code, it looks it's really just used to do pointer arithmetics in
old Delphi versions.

Thanks for the report.
I've just pushed the fix to the repository.
Nice "unusual" files to add to my test image suite :)

Bugs And Other Insects / Re: Premultiply and Unpremultiply
« on: 30 November 2018, 23:42:30 »
Thanks, that's indeed a bug.
Just pushed your fix to the repo.

Help & Questions / Re: Convert png with transparency to a bitmap
« on: 30 November 2018, 23:37:21 »
Well, if you want to replace just one color (classic color keying) then you can use ReplaceColor function from Imaging.pas unit.
I somehow assumed that by transparency you mean full alpha channel.

Thanks for the report, just pushed your fix to the repo.

Bugs And Other Insects / Re: RotateImage crash with certain angles
« on: 10 August 2018, 01:49:35 »

I've just tested your sample (0->360 degrees) and I've had no crashes
(Lazarus 1.8.4 on Win10, Imaging latest rev. from May 2018, just empty new LCL app).

What versions exactly did you use? Maybe some compiler settings are affecting this?

I'm going to update the website with current status in coming days.

Imaging has has repo on Github for some time now:

Could you check with the latest version of Imaging? There was a rework of the Lazarus packages in March 2018.

Thanks for the tip, looks pretty nice.

Help & Questions / Re: Convert png with transparency to a bitmap
« on: 6 February 2018, 03:10:03 »
If I understand it correctly, you need to create one image and fill it with your desired background color. Then load your PNG to another image and draw it over the first image with alpha blending. Finally, save the result to a bitmap. 

It's not very different but the the end result does not work yet :( There are crashes that I have not yet figured out.

What works fine in MacOS now is dynamic linking to libtiff like in Linux. It's not enabled by default though
since I guess not many Mac users have libtiff installed (contrary to Linux situation).

Pages: [1] 2 3 4 ... 25