<div dir="ltr">Perfect. Thanks so much! And thank you for showing the syntax for gdalwarp as well as how to useĀ <span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">gdal_edit.py. I would not have figured out these options without you help.</span><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Best regards,</span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Rich</span></div><div><span style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br></span></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 29, 2018 at 1:23 PM, Even Rouault <span dir="ltr"><<a href="mailto:even.rouault@spatialys.com" target="_blank">even.rouault@spatialys.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On mercredi 28 mars 2018 18:16:45 CEST Richard Greenwood wrote:<br>
> I have a question that is probably more "user" than "developer". Is there<br>
> different place that I should post my question?<br>
><br>
> I don't think that I understand -srcnodata. I assume that -srcnodata "0 0<br>
> 0" on a 3 band image means that all 3 bands have to be 0 to be "no data"<br>
> but I think what I'm seeing is that if any to the 3 bands is 0 then that<br>
> pixel is considered to be "no data". Am I mis-understanding -srcnodata?<br>
<br>
</span>Richard,<br>
<br>
That depends on the utility / algorithm.<br>
<br>
For gdalwarp, -srcnodata "0 0 0" will imply by default -wo UNIFIED_SRC_NODATA=YES<br>
See <a href="http://www.gdal.org/structGDALWarpOptions.html#a0ed77f9917bb96c7a9aabd73d4d06e08" rel="noreferrer" target="_blank">http://www.gdal.org/<wbr>structGDALWarpOptions.html#<wbr>a0ed77f9917bb96c7a9aabd73d4d06<wbr>e08</a><br>
<br>
For gdalbuilvrt / VRT (and other raster formats in general), nodata is evaluated on each band independantly.<br>
Unless you specify the NODATA_VALUES metadata item.<br>
<br>
gdalbuildvrt out.vrt in1.tif in2.tif<br>
gdal_edit.py -mo "NODATA_VALUES=0 0 0"<br>
<br>
Then utilities/algorithms that can use mask bands (not all can do however) will behave as you expect.<br>
<span class="HOEnZb"><font color="#888888"><br>
Even<br>
<br>
--<br>
Spatialys - Geospatial professional services<br>
<a href="http://www.spatialys.com" rel="noreferrer" target="_blank">http://www.spatialys.com</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Richard W. Greenwood, PLS<br><a href="http://www.greenwoodmap.com" target="_blank">www.greenwoodmap.com</a></div></div>
</div>