script:
Code: Select all
$int_im = new Imagick($base_file_path);
$int_im->scaleImage(1000,1000,true);
$int_im->setImageFormat('png');
$int_im->writeImage($int_file_path);
(by the way, this conversion i made on another win machine with not the latest IM and as for Linux i also tried to do conversion on another CentOs server and results are the same as before)
pngcheck output:
win ver:
Code: Select all
> d:\pngcheck\pngcheck.exe -v D:\OpenServer\domains\localhost\win.png
File: D:\OpenServer\domains\localhost\win.png (1159827 bytes)
chunk IHDR at offset 0x0000c, length 13
1000 x 625 image, 24-bit RGB, non-interlaced
chunk cHRM at offset 0x00025, length 32
White x = 0.3127 y = 0.329, Red x = 0.64 y = 0.33
Green x = 0.3 y = 0.6, Blue x = 0.15 y = 0.06
chunk bKGD at offset 0x00051, length 6
red = 0x00ff, green = 0x00ff, blue = 0x00ff
chunk pHYs at offset 0x00063, length 9: 3779x3779 pixels/meter (96 dpi)
chunk tIME at offset 0x00078, length 7: 18 Aug 2017 20:51:20 UTC
chunk zTXt at offset 0x0008b, length 435, keyword: Raw profile type exif
chunk zTXt at offset 0x0024a, length 873, keyword: Raw profile type xmp
chunk IDAT at offset 0x005bf, length 32768
zlib: deflated, 32K window, maximum compression
chunk IDAT at offset 0x085cb, length 32768
chunk IDAT at offset 0x105d7, length 32768
chunk IDAT at offset 0x185e3, length 32768
chunk IDAT at offset 0x205ef, length 32768
chunk IDAT at offset 0x285fb, length 32768
chunk IDAT at offset 0x30607, length 32768
chunk IDAT at offset 0x38613, length 32768
chunk IDAT at offset 0x4061f, length 32768
chunk IDAT at offset 0x4862b, length 32768
chunk IDAT at offset 0x50637, length 32768
chunk IDAT at offset 0x58643, length 32768
chunk IDAT at offset 0x6064f, length 32768
chunk IDAT at offset 0x6865b, length 32768
chunk IDAT at offset 0x70667, length 32768
chunk IDAT at offset 0x78673, length 32768
chunk IDAT at offset 0x8067f, length 32768
chunk IDAT at offset 0x8868b, length 32768
chunk IDAT at offset 0x90697, length 32768
chunk IDAT at offset 0x986a3, length 32768
chunk IDAT at offset 0xa06af, length 32768
chunk IDAT at offset 0xa86bb, length 32768
chunk IDAT at offset 0xb06c7, length 32768
chunk IDAT at offset 0xb86d3, length 32768
chunk IDAT at offset 0xc06df, length 32768
chunk IDAT at offset 0xc86eb, length 32768
chunk IDAT at offset 0xd06f7, length 32768
chunk IDAT at offset 0xd8703, length 32768
chunk IDAT at offset 0xe070f, length 32768
chunk IDAT at offset 0xe871b, length 32768
chunk IDAT at offset 0xf0727, length 32768
chunk IDAT at offset 0xf8733, length 32768
chunk IDAT at offset 0x10073f, length 32768
chunk IDAT at offset 0x10874b, length 32768
chunk IDAT at offset 0x110757, length 32768
chunk IDAT at offset 0x118763, length 9993
chunk tEXt at offset 0x11ae78, length 65, keyword: comment
chunk tEXt at offset 0x11aec5, length 37, keyword: date:create
chunk tEXt at offset 0x11aef6, length 37, keyword: date:modify
chunk tEXt at offset 0x11af27, length 46, keyword: exif:Artist
chunk tEXt at offset 0x11af61, length 35, keyword: exif:Copyright
chunk tEXt at offset 0x11af90, length 20, keyword: exif:ExifOffset
chunk tEXt at offset 0x11afb0, length 42, keyword: exif:ImageDescription
chunk tEXt at offset 0x11afe6, length 30, keyword: exif:Make
chunk tEXt at offset 0x11b010, length 31, keyword: exif:Model
chunk zTXt at offset 0x11b03b, length 107, keyword: exif:WinXP-Author
chunk zTXt at offset 0x11b0b2, length 85, keyword: exif:WinXP-Comments
chunk zTXt at offset 0x11b113, length 109, keyword: exif:WinXP-Keywords
chunk zTXt at offset 0x11b18c, length 84, keyword: exif:WinXP-Subject
chunk zTXt at offset 0x11b1ec, length 82, keyword: exif:WinXP-Title
chunk zTXt at offset 0x11b24a, length 53, keyword: unknown
chunk IEND at offset 0x11b28b, length 0
No errors detected in D:\OpenServer\domains\localhost\win.png (59 chunks, 38.1% compression).
centos ver:
Code: Select all
> d:\pngcheck\pngcheck.exe -v D:\OpenServer\domains\localhost\cent.png
File: D:\OpenServer\domains\localhost\cent.png (1570201 bytes)
chunk IHDR at offset 0x0000c, length 13
1000 x 625 image, 24-bit RGB, non-interlaced
chunk gAMA at offset 0x00025, length 4: 0.45455
chunk sRGB at offset 0x00035, length 1
rendering intent = perceptual
chunk cHRM at offset 0x00042, length 32
White x = 0.3127 y = 0.329, Red x = 0.64 y = 0.33
Green x = 0.3 y = 0.6, Blue x = 0.15 y = 0.06
chunk bKGD at offset 0x0006e, length 6
red = 0x00ff, green = 0x00ff, blue = 0x00ff
chunk pHYs at offset 0x00080, length 9: 3779x3779 pixels/meter (96 dpi)
chunk IDAT at offset 0x00095, length 32768
zlib: deflated, 32K window, maximum compression
chunk IDAT at offset 0x080a1, length 32768
chunk IDAT at offset 0x100ad, length 32768
chunk IDAT at offset 0x180b9, length 32768
chunk IDAT at offset 0x200c5, length 32768
chunk IDAT at offset 0x280d1, length 32768
chunk IDAT at offset 0x300dd, length 32768
chunk IDAT at offset 0x380e9, length 32768
chunk IDAT at offset 0x400f5, length 32768
chunk IDAT at offset 0x48101, length 32768
chunk IDAT at offset 0x5010d, length 32768
chunk IDAT at offset 0x58119, length 32768
chunk IDAT at offset 0x60125, length 32768
chunk IDAT at offset 0x68131, length 32768
chunk IDAT at offset 0x7013d, length 32768
chunk IDAT at offset 0x78149, length 32768
chunk IDAT at offset 0x80155, length 32768
chunk IDAT at offset 0x88161, length 32768
chunk IDAT at offset 0x9016d, length 32768
chunk IDAT at offset 0x98179, length 32768
chunk IDAT at offset 0xa0185, length 32768
chunk IDAT at offset 0xa8191, length 32768
chunk IDAT at offset 0xb019d, length 32768
chunk IDAT at offset 0xb81a9, length 32768
chunk IDAT at offset 0xc01b5, length 32768
chunk IDAT at offset 0xc81c1, length 32768
chunk IDAT at offset 0xd01cd, length 32768
chunk IDAT at offset 0xd81d9, length 32768
chunk IDAT at offset 0xe01e5, length 32768
chunk IDAT at offset 0xe81f1, length 32768
chunk IDAT at offset 0xf01fd, length 32768
chunk IDAT at offset 0xf8209, length 32768
chunk IDAT at offset 0x100215, length 32768
chunk IDAT at offset 0x108221, length 32768
chunk IDAT at offset 0x11022d, length 32768
chunk IDAT at offset 0x118239, length 32768
chunk IDAT at offset 0x120245, length 32768
chunk IDAT at offset 0x128251, length 32768
chunk IDAT at offset 0x13025d, length 32768
chunk IDAT at offset 0x138269, length 32768
chunk IDAT at offset 0x140275, length 32768
chunk IDAT at offset 0x148281, length 32768
chunk IDAT at offset 0x15028d, length 32768
chunk IDAT at offset 0x158299, length 32768
chunk IDAT at offset 0x1602a5, length 32768
chunk IDAT at offset 0x1682b1, length 32768
chunk IDAT at offset 0x1702bd, length 32768
chunk IDAT at offset 0x1782c9, length 29084
chunk tEXt at offset 0x17f471, length 65, keyword: comment
chunk tEXt at offset 0x17f4be, length 37, keyword: date:create
chunk tEXt at offset 0x17f4ef, length 37, keyword: date:modify
chunk tEXt at offset 0x17f520, length 17, keyword: jpeg:colorspace
chunk tEXt at offset 0x17f53d, length 32, keyword: jpeg:sampling-factor
chunk tEXt at offset 0x17f569, length 8, keyword: rdf:Alt
chunk tEXt at offset 0x17f57d, length 8, keyword: rdf:Bag
chunk IEND at offset 0x17f591, length 0
No errors detected in D:\OpenServer\domains\localhost\cent.png (62 chunks, 16.3% compression).
different compressions.
fmw42, thanks, i know about png compressions and that they differ from jpeg but none works for me, all compression variants produced no result.
from yum repo it says that libpng is the latest
Code: Select all
convert -list format (centos):
JPEG* JPEG rw- Joint Photographic Experts Group JFIF format (62)
JPG* JPEG rw- Joint Photographic Experts Group JFIF format (62)
PNG* PNG rw- Portable Network Graphics (libpng 1.5.13)
PNG24* PNG rw- opaque 24-bit RGB (zlib 1.2.7)