Post AxDAQd0A4vWxe2BPKy by andrewt@mathstodon.xyz
 (DIR) More posts by andrewt@mathstodon.xyz
 (DIR) Post #AxDAQXChdNztfC0L3I by divbyzero@mathstodon.xyz
       2025-08-13T13:58:00Z
       
       0 likes, 0 repeats
       
       Yesterday at the MoMath MOVES conference, Erik Demaine discussed QR codes and showed examples of how to incorporate images into them so they are still scannable. I had to give it a try. This QR code should take you to my website. More details: The second image is the QR code I started with (I used this page to create it https://www.nayuki.io/page/qr-code-generator-library). Certain "finder patterns" must be in the code—the nested squares and a row and column of alternating pixels. The rest are black and white pixels encoding the text. But for these, all that matters is whether the center of the pixel is black or white. So, if you shrink the black and white pixels by a factor of three, say, you can use the rest of the area however you want. I used Photoshop to turn my profile photo into a black-and-white pixellated image of the correct size. Then, I placed the QR code on top of it.
       
 (DIR) Post #AxDAQYTOumwrbGpBia by edemaine@mathstodon.xyz
       2025-08-15T02:58:38Z
       
       0 likes, 0 repeats
       
       @divbyzero Nice! You might be interested in the software I developed for this: https://erikdemaine.org/prints/QR/layers/Also our examples are here: https://erikdemaine.org/prints/QR/
       
 (DIR) Post #AxDAQZHNuwvm6ID6cy by divbyzero@mathstodon.xyz
       2025-08-15T11:41:48Z
       
       0 likes, 0 repeats
       
       @edemaine Thanks! I made mine "by hand"—Adobe Illustrator + Photoshop.
       
 (DIR) Post #AxDAQZwrQk6kAvcEHA by andrewt@mathstodon.xyz
       2025-08-15T11:49:44Z
       
       0 likes, 0 repeats
       
       @divbyzero @edemaine If each cell of the QR code is a 9x9 block of image pixels and only the centre one matters for scanning, it feels like we should be able to error-diffuse around the others and get a really good looking image?
       
 (DIR) Post #AxDAQathtxBB7R9E00 by andrewt@mathstodon.xyz
       2025-08-15T13:26:12Z
       
       0 likes, 0 repeats
       
       @divbyzero @edemaine it works!!the images is still kind of messed up but if i was spending real time on this i'd handle the fixed points first and i think i could clean up quite a bit of noise that way
       
 (DIR) Post #AxDAQbfv0hkBWxhj96 by andrewt@mathstodon.xyz
       2025-08-15T13:28:11Z
       
       0 likes, 0 repeats
       
       @divbyzero @edemaine weirdly this is the second time i've solved the problem of "what if error diffusion but the central point of each 3x3 subgrid was constrained", the last time being when @standupmaths was looking to build a double-sided picture out of rubiks cubes
       
 (DIR) Post #AxDAQcTC3V9vzml4wy by andrewt@mathstodon.xyz
       2025-08-15T15:56:12Z
       
       0 likes, 0 repeats
       
       @divbyzero @edemaine I had a go at improving the error diffusion and I *think* it's an improvement but honestly it's made less difference than I expected
       
 (DIR) Post #AxDAQd0A4vWxe2BPKy by andrewt@mathstodon.xyz
       2025-08-16T00:29:34Z
       
       0 likes, 2 repeats
       
       @divbyzero @edemaine ok I did a bug fix and added gamma correction and can confirm: this works really wellall of these scan just fine on my phoneanyway the code is at https://codeberg.org/andrew-t/dithered-qr-codes but it's not good code, it's something i threw together in an hour or so and then tidied up like 15%
       
 (DIR) Post #AxDAQexkmqnDj94VrU by divbyzero@mathstodon.xyz
       2025-08-13T16:43:38Z
       
       0 likes, 0 repeats
       
       Just playing around. Here are a couple more that I think I like better.
       
 (DIR) Post #AxDAfu8kdk5n8uU8hc by jae@darkdork.dev
       2025-08-16T01:07:33.246506Z
       
       1 likes, 0 repeats
       
       @andrewt @divbyzero @edemaine this is the coolest thing ive seen in 2025. i don't know js i write more go but have been wanting to do something similar in the terminal. well done.