From 9a0db7feeedf514fbf4d9b1970c9bd2311b40d8c Mon Sep 17 00:00:00 2001 From: smiley Date: Tue, 29 Mar 2022 15:23:21 +0200 Subject: [PATCH] :octocat: +GDImage internal upscaling documentation https://github.com/chillerlan/php-qrcode/discussions/122 --- src/QROptionsTrait.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/QROptionsTrait.php b/src/QROptionsTrait.php index 16e9e8b8b..7c5e8f824 100644 --- a/src/QROptionsTrait.php +++ b/src/QROptionsTrait.php @@ -163,7 +163,14 @@ trait QROptionsTrait{ /** * specify whether to draw the modules as filled circles * + * a note for GDImage output: + * + * if QROptions::$scale is less or equal than 20, the image will be upscaled internally, then the modules will be drawn + * using imagefilledellipse() and then scaled back to the expected size using IMG_BICUBIC which in turn produces + * unexpected outcomes in combination with transparency - to avoid this, set scale to a value greater than 20. + * * @see https://github.com/chillerlan/php-qrcode/issues/23 + * @see https://github.com/chillerlan/php-qrcode/discussions/122 */ protected bool $drawCircularModules = false;