In this post I was asking how to program a map of a Risk-like game.
Now that the map is pretty coded, both client and server-side, I'd like to finally draw the map.
I'll try to keep least broad as possible in this question, and also avoid XY problem.
So, my X problem is that I need an interactive map, based on (irregular) polygons.
Now, since this question would be really broad (there is a heavy number of possible solutions and libraries for a skilled programmer), this is how I imagined my Y solution:
Since the polygons have to be 10, touch-interactive, filled with plain color, I think that OpenGL ES should go fine for me. I'm also attracted by Path and Point classes, but the problem is that
The map should be displayed for lot of different screen sizes, but at the same time it should keep its ratio, instead of appearing more large or more little in the Activity.
The polygons have to be drawn to fit each others.
Every polygon should be touchable and the event should differ from the others. Also their color could change depending of the situation.
I don't know if Path and Point classes would fit for this. My intent is more game-like than generic, so I think I'll stick with OpenGL ES solution.
The problem is that I don't understand
- How can I map the polygons vertex and dimension for different screen sizes?
(considering we're talking about 10 polygons, there is a kind of environnment for doing this?)
- Should I use triangulation or not? I've done lot of research but this point wasn't clear to me.
I followed Android Open GL tutorial, but it only shows simple polygons and alone, I'd need 10 with lot of vertexes and above all that can fit each others.
How can I do this?
EDIT: I also tried to follow this tutorial. This is an image taken from that one:
To me instead, it's more little and near top-left corner. This is another trouble I'd like to avoid (as I said in point 1 above): my polygons should always fit the screen (and this is also why I want to use OpenGL ES).