Skip to content

Q: How best to avoid icc colour profile issues? #82

@derklempner

Description

@derklempner

Hi,

Thanks for all the work on this great library. I am slowly learning how to use it.

When converting colourspace to 'b-w' to threshold an image, I sometimes get an error when calling $image->writeToFile()

e.g.
profile 'icc': 1000000h: invalid rendering intent in console and in PHP error log PHP Fatal error: Uncaught Jcupitt\Vips\Exception: vips2png: unable to write...

The only way so far I have managed to get around this one is calling strip in cli.
vips copy in.jpg out.jpg[strip]

How does one achieve the [strip] equivalent / ignore all colour profile info in PHP?

PHP 7.2.8 / Vips library version 8.7.3 / php-vips 1.0.4

Cheers

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions