[Gdal-dev] Question about gdal_rasterize
Ari Jolma
ari.jolma at tkk.fi
Thu Apr 13 01:37:01 EDT 2006
Matthew Perry kirjoitti:
> On 4/12/06, Guillaume HUBY <ghuby at geosys.com> wrote:
>
>> An exact method should compute if a polygon edge cut a pixel edge and if
>> pixel is inside polygon.
>>
>>
Could the standard scanline / active edge table -method of polygon
filling algorithm be modified to fill only pixels, which are completely
inside the polygon? I.e. would something along the line of using two
scanlines, one for the top and one for the bottom of the pixel, and the
active edges would be compared against the left and right of the pixel,
work? A pixel is completely within a polygon if all of its borders are
within. Hmm, maybe not since the algorithm would only make sure that the
top and bottom borders are within.
I can understand the general need for this type of rasterization but
what is the specific need in this case?
Ari
--
Prof. Ari Jolma
Kartografia ja Geoinformatiikka / Cartography and Geoinformatics
Teknillinen Korkeakoulu / Helsinki University of Technology
POBox 1200, 02015 TKK, Finland
Email: ari.jolma at tkk.fi URL: http://www.tkk.fi/~jolma
More information about the Gdal-dev
mailing list