Thursday, April 7, 2011

Maybe

Cairo, maybe.

http://cairographics.org/samples/image/

So I have this map data and player/NPC/mob data. I pass this to my drawing function that uses Cairo.

In my drawing function I have a pre-defined tile set. Probably in .png with alpha channels (so that my player/mobs can be put anywhere). The drawing function sets up a space of map_height * map_width and then scans through the map data going from top left to bottom right. Each tile gets scaled and translated to the appropriate spot and then the display is revealed.

Hm. I might be able to bang out a quick proof of concept.

EDIT: The patterns stuff here: http://zetcode.com/tutorials/cairographicstutorial/shapesfills/

looks interesting..

No comments:

Post a Comment