Creating composite ambigrams from Chinese characters in Voxelverse

TriHexSet.gif

Okay guys, I really think you’re hassling me on this one little issue but here is a fix:

PadIm[bitmap_, len_, delta_] :=  With[{FixWidth = Join[
  Table[0, {i, Floor[delta[[2]]/2]}],
       #, Table[0, {i, Ceiling[delta[[2]]/2]}]] & /@ bitmap},
  Join[Table[0, {i, Ceiling[delta[[1]]/2]}, {j, len}],
   FixWidth, Table[0, {i, Floor[delta[[1]]/2]}, {j, len}]]]

RastToBitmap[im_, len_] := With[{ rect = Transpose[
        DeleteCases[Transpose[DeleteCases[
        Map[Mod[Round[Mean[#]] + 1, 2] &, ImageData[im], {2}],
        {0 ..}]], {0 ..}]]},   PadIm[rect, len, {len, len} - Dimensions[rect]]]

xuanxue = "玄学";
FullForm /@ Characters[xuanxue]
Image[RastToBitmap[Rasterize[#], 15], ImageSize -> 15*10] & /@ 
 Characters[xuanxue]
Image[RastToBitmap[Rasterize[Style[#, Large]], 18], 
   ImageSize -> 18*10] & /@ Characters[xuanxue]

Some other functions need also to be changed for variable sized input. Rather than posting essentially the same code again, I have attached a test notebook with a complete implementation. Meanwhile, output data files for frames of the animation above can be found at github. Nomenclature has changed, with introduction of revised “Trigram” function.

Maybe the hassle will be worth something though. Considering how many CJK ideographs there are, plus the crypto market’s hyper+hyper++ trending rn, it could be possible soon to launch the richest set of NFTs ever minted, ha ha. Just imagine if we generalize Autoglyphs to 3D, then ReplacePart trigrams into one of 8 corners. Hopefully block sizes are big enough, IDK just yet, lol. Then again, maybe not.

Trigrams.nb (49.8 KB)

1 Like