mirror of
https://github.com/chillerlan/php-qrcode.git
synced 2026-08-17 21:01:38 +00:00
26 lines
602 B
PHP
26 lines
602 B
PHP
<?php
|
|
/**
|
|
* reader.php
|
|
*
|
|
* @created 25.04.2022
|
|
* @author smiley <smiley@chillerlan.net>
|
|
* @copyright 2022 smiley
|
|
* @license MIT
|
|
*/
|
|
|
|
use chillerlan\QRCode\{QRCode, QROptions};
|
|
|
|
require_once __DIR__.'/../vendor/autoload.php';
|
|
|
|
// please excuse the IDE yelling https://youtrack.jetbrains.com/issue/WI-66549
|
|
$options = new QROptions;
|
|
$options->readerUseImagickIfAvailable = false;
|
|
$options->readerGrayscale = true;
|
|
$options->readerIncreaseContrast = true;
|
|
|
|
$result = (new QRCode($options))->readFromFile(__DIR__.'/../.github/images/example_image.png');
|
|
|
|
var_dump($result);
|
|
|
|
exit;
|