diff options
author | Christian Hesse <mail@eworm.de> | 2013-07-09 21:32:51 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2013-07-09 21:32:51 +0200 |
commit | d0b6d52bc46a054ecff777f9ed226faca48c0551 (patch) | |
tree | 2cdcd72bf18be03f98187b3aa767d7714a39118e | |
parent | 34209651d4570cf717be4f9d7b28b22b06c2ded5 (diff) | |
download | cqrlogo-d0b6d52bc46a054ecff777f9ed226faca48c0551.tar.gz cqrlogo-d0b6d52bc46a054ecff777f9ed226faca48c0551.tar.zst |
use best compression level
-rw-r--r-- | cqrlogo.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -12,6 +12,7 @@ #include <regex.h> #include <png.h> +#include <zlib.h> #include <qrencode.h> #include "config.h" @@ -42,6 +43,8 @@ int generate_png (struct bitmap_t *bitmap, char *http_referer) { png_set_IHDR (png_ptr, info_ptr, bitmap->width, bitmap->height, depth, PNG_COLOR_TYPE_GRAY, PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_DEFAULT, PNG_FILTER_TYPE_DEFAULT); + png_set_compression_level(png_ptr, Z_BEST_COMPRESSION); + #ifdef PNG_TEXT_SUPPORTED png_text text[3]; |