[gdal-dev] substitute pixel values

Brian Case rush at winkey.org
Wed Jan 9 09:26:06 PST 2013


hey Michael

i have done this with a vrt.

you can use a <lut>

The ComplexSource supports adding a custom lookup table to transform the
source values to the destination. The LUT can be specified using the
following form:

    <LUT>[src value 1]:[dest value 1],[src value 2]:[dest value
2],...</LUT>


http://www.gdal.org/gdal_vrttut.html


you should also keep in mind gdal will not know the difference between -
values in death valley and - values in the ocean

Brian

On Wed, 2013-01-09 at 16:33 +0000, Smith, Michael wrote:
> I have some DEMs that are created from lidar.  For reasons related to
> seeing currents and wind effect, we did not ask for the water to be
> flattened, but rather it shows waves.  This is cool, and what we
> wanted.  BUT of course now we want to create a second set of DEMs with
> a  nice flat ocean.
> 
>  
> 
> I have numerous pixels out in the ocean which are slightly less than
> 0.  So how does one select out all pixels < 0 and substitute them with
> 0 with GDAL?  
> 
>  
> 
> ===============================
> Michael Smith MS GISP
> State GIS Manager, Maine Office of GIS
> State of Maine, Office of Information Technology
> michael.smith _at_ maine.gov
> 207-215-5530
> 
> Board Member, Maine GeoLibrary
> Education Chair, Maine GIS Users Group
> State Rep, National States Geographic Information Council
> icons
> 
> ***NOTE NEW ADDRESS***
> 
> State House Station 145
> 51 Commerce Drive
> Augusta, ME 04333-0145
> 69o 47' 58.9"W  44o 21' 54.8"N
> 
> 
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev

-- 
Brian Case
KF7WPK
rush at winkey.org




More information about the gdal-dev mailing list