michaeltroger / greenpass-android

Green Pass PDF Wallet Android App
https://play.google.com/store/apps/details?id=com.michaeltroger.gruenerpass
GNU General Public License v3.0
73 stars 3 forks source link

Aztec Code on digital ticket from Deutsche Bahn not extracted #153

Closed Lucas-Sichardt closed 10 months ago

Lucas-Sichardt commented 1 year ago

Hello and thank you for this great idea of a very useful tool dealing with de-facto standard ticket format.

I tried to import a train ticket by Deutsche Bahn, which has a QRCode on the right bottom corner (international ticket) instead of the usual QRCode on the right top corner. Unfortinately the QRCode is not shown in big above the PDF - seems not to be recognized by the app...

Best regards

Lucas

michaeltroger commented 1 year ago

Hi Lucas! Thx for the feedback. To my knowledge the Deutsche Bahn Ticket unfortunately doesn't use a QR code but rather a so called Aztec code. I got this feature request before and tried implementing it, however it turned out to be more challenging than making the QR code recognition work. It's still on my wish list for features though.

For reference: https://en.m.wikipedia.org/wiki/Aztec_Code

Lucas-Sichardt commented 1 year ago

Hello Michael,

thanks for your sudden reply. It's funny how you can just learn things better by chance. I did never recognize a difference in that codes but of course there is one. I also just learned that Deutsche Bahn uses (used?) a modified version of the aztec code with a different center section...

Of course it would be nice, if the app could recognize that code too. But I just had another idea: It will probably occur from time to time that the app will not recognize some special code of some special ticket/certificate. But perhaps some user uses that specific thing all the time (abo of some special tickets). Perhaps it is possible to implement a feature that allows users to define named patterns (e. g. "Deutsche Bahn") where the user defined pattern includes the geometrics/position of the rectangle area the desired code is located in. And when importing PDFs the user would just select the corresponding pattern...

What do you think? Would be an universal workaround...

Best regards,

Lucas -- Lucas Sichardt @.*** http://lucas.sichardt.net

(Diese E-Mail habe ich von einem Mobiltelefon aus geschickt; eine eventuell erhöhte Häufigkeit von dadurch bedingten Tippfehlern bitte ich zu entschuldigen.)

Am 4. Juli 2023 22:40:00 MESZ schrieb Michael Troger @.***>:

Hi Lucas! Thx for the feedback. To my knowledge the Deutsche Bahn Ticket unfortunately doesn't use a QR code but rather a so called Aztec code. I got this feature request before and tried implementing it, however it turned out to be more challenging than making the QR code recognition work. It's still on my wish list for features though.

For reference: https://en.m.wikipedia.org/wiki/Aztec_Code

-- Reply to this email directly or view it on GitHub: https://github.com/michaeltroger/greenpass-android/issues/153#issuecomment-1620723901 You are receiving this because you authored the thread.

Message ID: @.***>

michaeltroger commented 10 months ago

Thx for the suggestion, definitely worth a thought! A nice UX is important to me as well though, so I ideally I don't want to ask users for choosing a pattern for every PDF they import. It would be great if it would be possible to auto detect the document type (e.g. Deutsche Bahn) and applying that pattern automatically. Anyhow I will keep your idea in mind, but will close this specific ticket since there is already one for Aztec recognition https://github.com/michaeltroger/greenpass-android/issues/32