endroid / qr-code

QR Code Generator
https://endroid.nl
MIT License
4.33k stars 721 forks source link

Background color and margin for logo #427

Closed billdagou closed 7 months ago

billdagou commented 7 months ago

Hi Jeroen,

Is it possible to provide the abilities to set the bg color and the margin for logo?

Thanks.

endroid commented 7 months ago

@billdagou for the logo unfortunately this is not possible. That functionality will purely be kept to adding an image in-place as-is so if you need that you would need to add some pre-processing yourself or make sure the logo already has the correct margin or background color. You could use the $result->getMatrix() for this purpose to do the necessary calculations.