Pixels to hexagons
- retrotails
- Party member
- Posts: 212
- Joined: Wed Apr 18, 2012 12:37 am
Pixels to hexagons
Hard coded hexagon shapes for speed and laziness.
Grid is stretched to fit the original aspect ratio.
Pixels are mapped 1-to-1 so there's no conversion. While it'd be easy with a canvas, I was only curious to see how sprite art looked.
Limited to images with 65536 pixels total (256x256) but you can disable it in the code.
The way hexagons are rendered one by one is just for looks, zoom or switch modes to render it instantly.
Controls:
Mouse wheel/Arrows: Browse items in the menu and zoom the image
Left click/Enter: Select the highlighted item
Right click/Escape: Return to menu, only Escape can quit.
1-4 keys: Change drawing mode
Re: Pixels to hexagons
Very interesting, thanks for sharing!
Who is online
Users browsing this forum: No registered users and 3 guests