ptachoire / php-dmtx
Datamatrix r/w based on libdmtx <http://www.libdmtx.org/>
Installs: 60 779
Dependents: 0
Suggesters: 1
Security: 0
Stars: 18
Watchers: 2
Forks: 7
Open Issues: 0
Requires
- symfony/options-resolver: ~3.4||~4.0||~5.0||~6.0
- symfony/process: ~3.4||~4.0||~5.0||~6.0
Requires (Dev)
- phpunit/phpunit: ^10.0
This package is not auto-updated.
Last update: 2024-12-19 23:37:57 UTC
README
Datamatrix reader/writer based on libdmtx.
⚠️ The installation of dmtx-utils is required to use the lib.
Install
composer require "ptachoire/php-dmtx:*"
Usage
use Dmtx\Writer; $writer = new Writer(); //encode message into file $writer->encode('this is a message') ->saveAs('/tmp/image.png'); //encode message and output image echo $writer->encode('this is a message') ->dump();
use Dmtx\Reader; $reader = new Reader(); //decode message from data $reader->decode($encoded_value); //decode message from file echo $reader->decodeFile('/tmp/image.png');
Test
composer install ./vendor/bin/phpunit
Credits
Project structure inspired by Negotiation by willdurand.
License
php-dmtx is released under the MIT License. See the bundled LICENSE file for details.