Skip to content

Instantly share code, notes, and snippets.

@nst
Last active February 25, 2025 18:23
Show Gist options
  • Save nst/696c31566a283588b7933415b3bd6aae to your computer and use it in GitHub Desktop.
Save nst/696c31566a283588b7933415b3bd6aae to your computer and use it in GitHub Desktop.
%!PS
% Postscript implementation of Georg Nees "Schotter"
% Nicolas Seriot, 2022-09-20
% https://collections.vam.ac.uk/item/O221321/schotter-print-nees-georg
% golfed version
% /S 28 def 100 770 translate /j{rand r mod 2 mul r sub}def
% 1 1 12{1 1 24{/r exch def gsave dup S mul r S mul neg translate
% j rotate j j S S rectstroke grestore}for}for showpage
/COLS 12 def
/ROWS 24 def
/SIZE 28 def
100 770 translate
1 -1 scale
/jig { rand r mod 2 mul r sub 1 add } def
1 1 COLS {
/c exch def
1 1 ROWS {
/r exch def
gsave
c SIZE mul r SIZE mul translate
jig rotate
jig jig SIZE SIZE rectstroke
grestore
} for
} for
showpage
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment