Skip to content

Instantly share code, notes, and snippets.

@fabienhinault
Created September 14, 2016 15:07
Show Gist options
  • Save fabienhinault/da137604a2b253fead47b456368916c8 to your computer and use it in GitHub Desktop.
Save fabienhinault/da137604a2b253fead47b456368916c8 to your computer and use it in GitHub Desktop.
/drawQrPath
{
newpath
%...qr path from http://goqr.me/
31 32 moveto
32 32 lineto
32 33 lineto
31 33 lineto
31 32 lineto
32 32 moveto
33 32 lineto
33 33 lineto
32 33 lineto
32 32 lineto
closepath
} def
/drawQrPage {
15 15 565 812 rectclip
15 15 translate
-565 mul exch -812 mul translate
565 4 mul 33 div dup scale
0 0 0 setrgbcolor
drawQrPath
fill
showpage
}
def
0 1 2 {
/a exch def
0 1 3 {
/b exch def
a b drawQrPage
} for
} for
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment