Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2003:
[Freeciv-Dev] Re: (PR#3936) introducing native coordinates
Home

[Freeciv-Dev] Re: (PR#3936) introducing native coordinates

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: jdorje@xxxxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#3936) introducing native coordinates
From: "Gregory Berkolaiko" <Gregory.Berkolaiko@xxxxxxxxxxxx>
Date: Sat, 5 Apr 2003 05:10:49 -0800
Reply-to: rt@xxxxxxxxxxxxxx

On Fri, 4 Apr 2003, Jason Short wrote:

> This is a significant design issue, and should be closely scrutinized. 
> I'd encourage everyone to at least read this patch.
> 
> Native coordinates (sometimes called "compressed" coordinates in the
> past) are a concept Ross came up with to make isometric (and other
> non-standard) maps easier to deal with.  They save around 50% memory
> (and on disk, in savegames) for map storage over "standard" map
> coordinates and make topology operations *much* simpler.  Other
> coordinate systems may share one of these properties, but none have
> both.  In the process, they invalidate the need for "regular" map positions.
> 
> The patch introduces native_to_map_pos and map_to_native_pos macros into
> map.h, along with one very simple user.  I've also written an

I assume this macros will change drastically when iso-rect is implemented?
Otherwise, they seem a bit pointless...

> explanation of the coordinate systems for doc/HACKING.  I'd like
> feedback on this explanation, particularly from people who don't already
> know what "native coordinates" are.

Nice explanation (I didn't know you terminology before).
Suggestions:
1. You might mention that "natural" coordinate system is obtained by 
sparsing the rectangular one.
2. Can you give the index notation along with "X" sketches?
I mean when you compare

      X X X              X
       X X X    to      XXX
      X X X              XXX
                          XX
you wonder which X went to which X. But in 
        0 1 2            0
         3 4 5          631
        6 7 8            742
                          85
it is more clear (provided I got it right).

G.




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