Note that there are some explanatory texts on larger screens.

plurals
  1. POConverting vector-contoured regions (borders) to a raster map (pixel grid)
    primarykey
    data
    text
    <p>I have a map that is cut up into a number of regions by borders (contours) like countries on a world map. Each region has a certain surface-cover class <em>S</em> (e.g. 0 for water, 0.03 for grass...). The borders are defined by:</p> <ul> <li>what value of <em>S</em> is on either side of it (0.03 on one side, 0.0 on the other, in the example below)</li> <li>how many points the border is made of (<em>n</em>=7 in example below), and </li> <li><em>n</em> coordinate pairs (<em>x</em>, <em>y</em>). </li> </ul> <p>This is one example. </p> <pre><code>0.0300 0.0000 7 2660607.5 6332685.5 2660565.0 6332690.5 2660541.5 6332794.5 2660621.7 6332860.5 2660673.8 6332770.5 2660669.0 6332709.5 2660607.5 6332685.5 </code></pre> <p>I want to make a raster map in which each pixel has the value of <em>S</em> corresponding to the region in which the center of the pixel falls. </p> <p>Note that the borders represent <em>step</em> changes in <em>S</em>. The various values of <em>S</em> represent discrete classes (e.g. grass or water), and are not values that can be averaged (i.e. no wet grass!). </p> <p>Also note that not all borders are closed loops like the example above. This is a bit like country borders: e.g. the US-Canada border isn't a closed loop, but rather a line joining up at each end with two other borders: the Canada-ocean and the US-ocean "borders". (Closed-loop borders <a href="http://en.wikipedia.org/wiki/Lesotho" rel="nofollow noreferrer">do exist</a> nevertheless!)</p> <p>Can anyone point me to an algorithm that can do this? I don't want to reinvent the wheel! </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload