Author | Topic: Problem saving PNG files on Windows XP | |
---|---|---|
Andreas Gehrs-Pahl View the complete thread for this message in: | Problem saving PNG files on Windows XP on Thu, 19 Feb 2015 09:50:54 -0500 Till, Saving bitmaps in the PNG format (in 2.0.570) on Windows XP will create invalid files that are missing most of the information, possibly because pixels are saved as being transparent? This works fine on Windows 7, though. The attached images were created with a simple routine to copy the active dialog to the clipboard, and getting the bitmap from there, basically using: oBitmap := oClipBoard:GetBuffer(XBPCLPBRD_BITMAP) They were then saved with 1.9.355 and with 2.0.570 using basically: oBitmap:SaveFile(cFileName, XBPBMP_FORMAT_PNG, nCompression) Changing the Compression value has no effect on this particular issue, and saving in BMP or JGP formats will result in normal files without the issue. I believe the problem started with 2.0.502, but I can't verify that right now. In 1.9.355 there was a problem with saving PNGs on Windows XP with a compression ratio greater than about 50% -- or the default value (-1) -- resulting in (empty) PNG files that were just 77-bytes long, but this seems to have been fixed in 2.0. Also, saving images in GIF format isn't working in either version and on any OS, always resulting in basically empty GIF87a files. I didn't find any existing PDRs for those issues. If you need more details or a working demo program, please let me know. Thanks, Andreas Andreas Gehrs-Pahl Absolute Software, LLC phone: (989) 723-9927 email: Andreas.GP@Charter.net web: http://www.Aerospace-History.net Images.zip |