[gdal-dev] python: read pixel from raster

Sebastian E. Ovide sebastian.ovide at gmail.com
Wed Jan 12 12:57:04 EST 2011


thanks for that...

What I'm looking for is something like ReadRaster but using the coordinates
system used by the raster... (it could be lat,long etc...)

otherwise I would need to do something like

cs=read_raster_coordinate_system()
(x,y)= cs.convert_from_cs_to_pixel_xy(x,y)
pixel=ReadRaster

is there any single line command to do that ?

2011/1/12 Jorge Arévalo <jorge.arevalo at deimos-space.com>

> On Wed, Jan 12, 2011 at 4:57 PM, Sebastian E. Ovide
> <sebastian.ovide at gmail.com> wrote:
> > Hi All,
> > what would be the simpler way to read a pixel value from a raster using
> > python ?
> > something like  pixelvalue=read(x,y) where x,y and in the raster
> coordinate
> > system
> > thanks
> >
> > --
> > Sebastian E. Ovide
> >
> >
> >
> >
> >
> > _______________________________________________
> > gdal-dev mailing list
> > gdal-dev at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/gdal-dev
> >
>
> Hi Sebastian,
>
> This may help you:
> https://svn.osgeo.org/postgis/trunk/raster/scripts/python/pixval.py
>
> Best regards,
>
> --
> Jorge Arévalo
> Internet & Mobilty Division, DEIMOS
> jorge.arevalo at deimos-space.com
> http://mobility.grupodeimos.com/
> http://gis4free.wordpress.com
> http://geohash.org/ezjqgrgzz0g
>



-- 
Sebastian E. Ovide
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20110112/d1115a0c/attachment.html


More information about the gdal-dev mailing list