Hi, 2009/10/14 Seth Girvin <[email protected]>
> I can get statistics on my GeoTIFF which is great, but I need to get the > count of pixels in each class in the raster. > Ideally I want to get the count by a range e.g. 123787 cells between 0 - > 0.25, 3242353 cells between 0.25-0.5. Would I need to read through all cells > individually? I can't seem to find a way to do this using GDAL command line > tools, so I'm not sure what function name I should be looking out for. > I know nothing about the C# bindings, but using the python bindings, you can get a histogram, and change its bin buckets around to your satisfaction: g = gdal.Open(my_fname) b = g.GetRasterBand(1) h = b.GetHistogram() J
_______________________________________________ gdal-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/gdal-dev
