[gdal-dev] gdal utilities question
Chaitanya kumar CH
chaitanya.ch at gmail.com
Wed Dec 11 08:29:33 PST 2013
Dennis,
You can create a new raster with the pixel values scaled to one bit so that
all you have is zero for no color and one for any color. Use gdal_translate
with the -scale option. The exact method depends on the data. Then you are
essentially ignoring the color.
Contours are set as lines instead of polygons because they terminate at the
raster edges.
--
Best regards,
Chaitanya Kumar CH
On Dec 11, 2013 9:48 PM, "Dennis Burgess" <dmburgess at linktechs.net> wrote:
> I have been using the GDAL utilities. But ran into a snag. We create KML
> overlay files, basically KML file that geolocates a PNG on google maps.
> This PNG is a vector image as well as can have 1 or two colors other than
> the transparent background. We used gdal to convert this to a GEOTIFF
> using the gdal_contour and this work quite well, its ignores the colors for
> the most part, as all we want is a poly of the colored areas, don't care
> about what color. gedal_polygonize, sees all colors and seams much more
> rough.
>
>
>
> in both cases, we generate a KML shapefile, but it appears they create
> line entries vs polygons.
>
>
>
> We also use ogr2ogr to simplify the KML as well. Can anyone give me some
> better method to get a pologyon for only the colored areas , ignoring
> changes in color.?
>
>
>
> *Dennis Burgess,*
>
>
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20131211/3f107440/attachment.html>
More information about the gdal-dev
mailing list