<div dir="auto">You may be looking for clip/mask:<div dir="auto"><br></div><div dir="auto"><a href="https://rasterio.readthedocs.io/en/latest/topics/masking-by-shapefile.html" target="_blank" rel="noreferrer">https://rasterio.readthedocs.io/en/latest/topics/masking-by-shapefile.html</a></div><div dir="auto"><br></div><div dir="auto"><a href="https://corteva.github.io/rioxarray/stable/examples/clip_geom.html">https://corteva.github.io/rioxarray/stable/examples/clip_geom.html</a></div><div dir="auto"><br></div><div dir="auto"><br></div><div dir="auto">After clipping, you can use numpy to do the sum.</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Dec 27, 2021, 12:58 PM Luca Bertoncello <<a href="mailto:lucabert@lucabert.de" target="_blank" rel="noreferrer">lucabert@lucabert.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi list!<br>
<br>
I'm very new to GDAL, so please excuse me if the question is too simple...<br>
<br>
My problem: I'm writing an App to fly VFR and I'd like to display a<br>
vertical profile of the route.<br>
Of course, it must work offline, so I cannot use a service like Google<br>
Maps or similar...<br>
<br>
I tryed OpenTopoData with the EUDEM dataset and I can get the elevation<br>
from a single point.<br>
Very nice, but not useful for my App...<br>
<br>
Since I don't need a huge precision, but I do need a relative small file<br>
to use in my App, it may suffice if I can create a database with the<br>
maximum elevation in a square 5x5 km, identified by the coordinates of<br>
the center.<br>
<br>
And here start the problems, since I don't have any idea how to extract<br>
these data from the TIFF files I have.<br>
<br>
On the server (Debian 10) is Python and PERL installed, as well as the<br>
GDAL utilities.<br>
<br>
Can someone help me?<br>
<br>
Thank you very very much for your help!<br>
Luca Bertoncello<br>
(<a href="mailto:lucabert@lucabert.de" rel="noreferrer noreferrer" target="_blank">lucabert@lucabert.de</a>)<br>
_______________________________________________<br>
gdal-dev mailing list<br>
<a href="mailto:gdal-dev@lists.osgeo.org" rel="noreferrer noreferrer" target="_blank">gdal-dev@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/gdal-dev" rel="noreferrer noreferrer noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/gdal-dev</a><br>
</blockquote></div>