While watching Minecraft videos, I often find designs that I would like to replicate, but no world download is provided with the video. Other times, I would like to do a render with Chunky from a screenshot only. I sometimes decide to painstakingly replicate large builds block-for-block using a video or screenshot.
I think it would be interesting to develop a program to do this automatically.
One possible approach I came up with:
I haven't started on anything yet; I just wanted to post this concept here and get your feedback.
I think it would be interesting to develop a program to do this automatically.
One possible approach I came up with:
- 1. Figure out which pixels belong to the UI and should be ignored (Hotbar, inventory, F3, status effects, etc.)
2. Determine rotation and position relative to the block grid
3. If a video or set of screenshots is being used, determine if a block boundary has been passed since the last screenshot.
4. Generate a list of block positions to scan, ordered from closest to farthest, that are within the FOV
5. For each block position, take each potentially visible face and figure out which pixels would be visible if it were the only block in the world
6. Rotate/skew a copy of those pixels so that they form a square shape
7. Determine if there is a "correct" section of this face visible (not blocked by a closer block)
8. If so, determine which block it is most likely to be based on the textures
9. Add that block to the schematic
I haven't started on anything yet; I just wanted to post this concept here and get your feedback.