Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re^5: GD colorAllocate not changing colour

by Discipulus (Abbot)
on May 16, 2021 at 17:37 UTC ( #11132669=note: print w/replies, xml ) Need Help??


in reply to Re^4: GD colorAllocate not changing colour
in thread GD colorAllocate not changing colour

Please note that once a file is loaded inside a GD object, is no more a jpg nor a png: it is loaded into an internal GD format and it is up to you to write it to disk in the desired format.

Also note that saving to png allows you to specify a compression in the range:

> 0-9, where 0 means no compression (largest files, highest quality) and 9 means maximum compression (smallest files, worst quality). A compression level of -1 uses the default compression level selected when zlib was compiled on your system, and is the same as calling png() with no argument.

L*

There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

Replies are listed 'Best First'.
Re^6: GD colorAllocate not changing colour
by Bod (Deacon) on May 16, 2021 at 17:47 UTC
    A compression level of -1 uses the default compression level selected when zlib was compiled on your system, and is the same as calling png() with no argument.

    Oh! That's useful...
    So it would always be sensible to include a compression level unless you happened to be the one who did the installation.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11132669]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (4)
As of 2021-09-24 10:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?