StripImage also delete ICC image profile by default.
The resulting images seem to lose a lot of color information and look "flat" compared to their non-stripped versions.
Consider keeping the ICC profile (which causes richer colors) while removing all other EXIF data:
1. Extract the ICC profile
2. Strip EXIF data and image profile
3. Add the ICC profile back
The code is:
<?php
$profiles = $img->getImageProfiles("icc", true);
$img->stripImage();
if(!empty($profiles))
$img->profileImage("icc", $profiles['icc']);
?>
PHP.mk документација
Imagick::stripImage
Почист и полокален преглед на PHP референцата, со задржана структура од PHP.net и подобра читливост за примери, секции и белешки.
Патека
imagick.stripimage.php
Локална патека за оваа страница.
Извор
php.net/manual/en
Оригиналниот HTML се реупотребува и локално се стилизира.
Режим
Прокси + превод во позадина
Кодовите, табелите и белешките остануваат читливи во истиот тек.
Референца
imagick.stripimage.php
Imagick::stripImage
Референца за `imagick.stripimage.php` со подобрена типографија и навигација.
Imagick::stripImage
(PECL imagick 2, PECL imagick 3)
Imagick::stripImage — Отстранува профили и коментари од сликата
Параметри
Оваа функција нема параметри.
Вратени вредности
Патеката до PHP скриптата што треба да се провери. true на успешен исход.
Errors/Exceptions
Фрла ImagickException при грешка.
Белешки од корисници 3 белешки
Max Eremin ¶
пред 9 години
g dot a dot karthikeyan at gmail dot com ¶
12 години пред
Please note that striping off the exif information without handling the orientation information available in the exif will lead to wrong orientation of the image