php - Saving jpg to png increases size -
this question has answer here:
i use following code save format of image png
:
$crawl_outfile = 'webss_' . uniqid() . '.png'; imagepng(imagecreatefromstring(file_get_contents($src)),$crawl_outfile);
and increases size of 290 kb 1.7 mb. cannot understand reason. there way(parameter) smaller image ?
jpeg lossy compression format (some detail in image lost), png not. therefore, png larger in file size.
png efficient @ compressing things, large areas of same color. jpeg better @ compressing photos.
Comments
Post a Comment