3 ms·
On a modded Minecraft server, I wanted to use an opencomputers 3d printer to print out pngs from the internet. It had a pallette system that let you choose colo
by bpchaps 8y ago
On a modded Minecraft server, I wanted to use an opencomputers 3d printer to print out pngs from the internet. It had a pallette system that let you choose colors at specified dimensions, but I wanted to constrain myself to only use colors that not only existed on existing blocks, but also in the same position.
1. Had to build a Minecraft computer and figure out its interface. The computer came with git and curl commands, so that's how I downloaded files.
2. Every block had to be pulled apart and every pixel had to be mapped to it's voxelspace dimensions.
3. Some blocks had extra logic which caused random transparent pixels to show up, so I had to find and exclude those from samples (flowers were the biggest contributor). This was a bulk of the work, because there was no simple way to find which blocks had extra logic. I even pulled out jad to find any sort of useful pattern, but there really wasn't any.
4. Had to do some k-map stuffs to find the closest color to each pixel from all images.
5. Create a file for each block, which all had to include the original block's color for that specified dimension.
6. Import each file one by one because the computer had limited diskspace.
7. Place each block manually.
It ended up working surprisingly well and could be scaled to any size. Problem was, even looking at a printed block used a LOT of resources at both server and client side. So I scrapped the project.
Fun stuff, especially with that being the first sort of image processing work I've ever done.