Function reencodeImage
Used to re-econodes an image to a specified image format - creates a copy of the file at the same location as fileName. - the file would have the format preferred_format if possible, otherwise the default format is jpeg. - the function makes sure that all non-essential image contents are disposed.
Package: SMF
Copyright: 2020 Simple Machines and individual contributors
License: BSD
Author: Simple Machines https://www.simplemachines.org
Located at Sources/Subs-Graphics.php
Copyright: 2020 Simple Machines and individual contributors
License: BSD
Author: Simple Machines https://www.simplemachines.org
Located at Sources/Subs-Graphics.php
string |
$fileName |
The path to the file |
integer |
$preferred_format = 0 |
The preferred format - 0 to automatically determine, 1 for gif, 2 for jpg, 3 for png, 6 for bmp and 15 for wbmp |
boolean
|
Whether the reencoding was successful |