Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2004:
[Freeciv-Dev] Re: (PR#7287) Extended Topologies
Home

[Freeciv-Dev] Re: (PR#7287) Extended Topologies

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: mburda@xxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#7287) Extended Topologies
From: "rwetmore@xxxxxxxxxxxx" <rwetmore@xxxxxxxxxxxx>
Date: Tue, 24 Feb 2004 07:42:46 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=7287 >


I know you haven't worked this one out yet and have a bit of a mental
block with hexagons, but it is not really that difficult and it works
with all the tile grid types. I have no idea what operations you are
trying that require some arbitrary number of vertices :-).


Remembering that distance movement in Freeciv means that squares are
really equidistant from a common centre, each hemisphere looks like
this.  You roll over the edge to the backside hemisphere at each edge.
One could pull up on 1 to make a pyramid shape and thus get an
eight-sided die by combining the two hemispheres.

       4 4 4 4 4 4 4
       4 3 3 3 3 3 4
       4 3 2 2 2 3 4
       4 3 2 1 2 3 4
       4 3 2 2 2 3 4
       4 3 3 3 3 3 4
       4 4 4 4 4 4 4

For a hexmap things are perhaps easier to see, as this is commonly
used in gaming for displaying circular maps. Again if you pulled up
on 1, you get a six sided pyramid, and joining both hemispheres
gives you a 12-sided die shape, though not the usual one with
pentacle faces.

         4 4 4 4
        4 3 3 3 4
       4 3 2 2 3 4
      4 3 2 1 2 3 4
       4 3 2 2 3 4
        4 3 3 3 4
         4 4 4 4


If you take the triangle cut running from the centre (1) out to any
point and its neighbour along a side, and fold it out into a star you
get the same sort of thing as the initial quincunx cuts to show the
backside hemisphere across its equatorial connection. But of course
you don't join up the edges by stretching things in the ways that
cause all the qunicunx distortions - just leave them as a star.


Note there is limited scrollability with the above cases, in that one
can really only rotate about the poles and pretty much only by a few
fixed angles. Also as one crosses the equator in the canvas view, the
corners have singularities that are messy to display, especially if
you try to represent all relationships in the other hemisphere other
than as star tips. When the canvas flips to make the other hemisphere
the primary one, the centre hex and star tips change places.


Cheers,
RossW
=====


Jason Short wrote:
> <URL: http://rt.freeciv.org/Ticket/Display.html?id=7287 >
> 
> rwetmore@xxxxxxxxxxxx wrote:
> 
> 
>>I actually like the idea of taking any map grid that one can view
>>as having concentric rings (emanating from a pole). If you take two
>>of these and stick them back to back together along the equator you
>>get pretty much the model you describe below. Works for square, hex
>>and many other tile shapes.
> 
> 
> No, it doesn't work for hexagons.  It will only work for triangles and 
> squares because only these have an even number of tiles meeting at each 
> corner.  And for triangles it would really suck.
> 
> Consider
>     _______
>    /G     H\
>   /         \
> /L         I\_______
> \           /?     ?\
>   \         /         \
>    \K_____J/?         ?\
>    /A     B\           /
>   /         \         /
> /F         C\?_____?/
> \           /
>   \         /
>    \E_____D/

Note this isn't a very useful way to view things. The hemispheres are
distinct, and thus if you were to make star tips along ji and bc they
are overlapping and thus confusing since the centre of ?????? is the
north pole in one case and the south pole in the other. But if you divide
GHIJLK up into 6 wedges, then the JI wedge fits at BC, the BI wedge fits
at DC, the GH wedge fits at ED etc. and all the tips are south poles if
ABCDEF is the north hemisphere. Similarly if you divide up ABCDEF and
spread the wedges around GHJKLI. In this case the star tips are north
poles.

> where ABCDEF and GHIJKL are the two hexagons you are putting 
> back-to-back.  If you're going to tile the map, what values are you 
> going to put in the ? places above?  Answer: none are possible.
> 
> Note that if you do this with a square you'll get a quincuncial-2 topology.
> 
> jason

Cheers,
RossW
=====




[Prev in Thread] Current Thread [Next in Thread]