defold (official)
defold/extension-qrcode
A small native extension that encodes and decodes QR codes, using quirc for
decoding. It registers a qrcode Lua module with qrcode.scan, which reads
the text from an image buffer, and qrcode.generate, which returns a QR code
image buffer and its side length.
Lua API not typed — upstream ships no .script_api, so resolve skips it.
- GitHub: defold/extension-qrcode — pinned to
1.1(released while Defold 1.2.128 was current)- Pick a release from defold/extension-qrcode releases and add its Source code (zip) URL (or a packaged
.zipasset, if the library ships one) togame.projectunder[project]dependencies, then Fetch Libraries in the Defold editor. - See the included example app, which scans camera images and creates QR codes; it depends on a camera extension that supports only macOS, iOS and Android.
- Pick a release from defold/extension-qrcode releases and add its Source code (zip) URL (or a packaged
Engine APIs
Both functions work on buffer objects: scan expects a
first stream of UINT8 * 3 texels, and generate returns a data stream of
UINT8 * 1.