1
makerow[a_, w_] := Table[Join[Table[0, {x, y - 1}], Table[1, {x, a}], Table[0, {x, (w - a) - (y - 1)}]], {y, w - (a - 1)}];
makerowgrid[k_, w2_, h2_] := Table[Join[Table[Table[0, {x, w2}], {x, y - 1}], {makerow[k,w2][[z]]},Table[Table[0, {x, w2}], {x, h2 - y}]], {y, h2}, {z,Length[makerow[k, w2]]}];
gameWidth = 6;
gameHeight = 5;
gameBiggestPiece = 3;
gameSmallestPiece = 2;
myset = Flatten[Table[makerowgrid[x, gameWidth, gameHeight], {x, gameSmallestPiece,gameBiggestPiece}], 1];
mysetT = Map[Transpose,Flatten[Table[makerowgrid[x, gameHeight, gameWidth], {x,gameSmallestPiece,gameBiggestPiece}], 1], {2}];
myout = Flatten[Map[ArrayPlot, Join[myset, mysetT], {2}], 1]
Export["games.pdf", myout]

I have a temporary workaround from another post on this forum open the pdf in notepad++ find and replace all instances of "/interpolate true" change to "/interpolate false" without "". Now my next question would be how to force this setting from mathematica directly as part of the PDF export arguments?

acacia
  • 389
  • 1
  • 9
  • "how to force this setting from mathematica" You should contact Wolfram Research directly and request this feature. I don't think it is possible. – Szabolcs Oct 25 '20 at 11:07

0 Answers0