module Goban::PNGExporter
Overview
Helper module to generate PNG image for the QR Code object. Requires stumpy_png
as a dependency.
Included Modules
- StumpyPNG
Extended Modules
Defined in:
goban/exporters/png.crInstance Method Summary
-
#export(qr : AbstractQR, path : String | IO, mod_size : Int, blank_mods : Int)
Generates a PNG image with the given module size and blank modules, and exportes to the given path.
-
#export(qr : AbstractQR, path : String | IO, target_width : Int)
Generates a PNG image with the given target size and exports to the given path.
Instance Method Detail
def export(qr : AbstractQR, path : String | IO, mod_size : Int, blank_mods : Int)
#
Generates a PNG image with the given module size and blank modules, and exportes to the given path.
mod_size
refers to the number of pixels used for each module in the QR Code symbol,
and blank_mods
is the size of the white border around the symbol.
def export(qr : AbstractQR, path : String | IO, target_width : Int)
#
Generates a PNG image with the given target size and exports to the given path. Note that the size of the resulting image may not be equal to the target size specified.