Hi David, I'm moving your question to the user list - I hope that's alright.
The JAI Extrema operation doesn't have any parameters for excluding one or more values. You might like to look at the unsupported/jai-tools module. It wraps the JAI-tools ZonalStats image operator for use in GeoTools. This operator lets you define values or ranges of values to treat as NODATA: Here are the javadocs for the operator: http://jai-tools.org/docs/jai-tools/stable/apidocs/jaitools/media/jai/zonalstats/ZonalStatsDescriptor.html Michael On 8 April 2011 02:04, David Winslow <[email protected]> wrote: > Hi all, > I'm trying to inspect some geotiffs so I can generate color > ramps appropriate to the value range present. but when i retrieve the > extrema for a coverage band the NODATA value is not ignored - so my ramp > ends up being broader than i'd like. I was hoping to find something like > the existing Extrema operation, but with a parameter containing a list of > values to ignore (or a list of such lists per band.) I don't see such a > thing in either GeoTools or JAI (but I am a JAI newbie so I might have > missed something). > In case it's not clear what I'm looking for, find attached a very basic > implementation of what I'm thinking of (see findExtrema at the end of the > file). I'd be happy to clean it up for inclusion in GeoTools if this is > something that seems desirable, though I might need a bit of help fitting > into the existing Operation system - I didn't see anything in the docs on > adding new ones to the library. > I also noticed that while GridSampleDimension has a method > getNoDataValues(), it actually returns null for GeoTIFFs, even ones that do > populate the GC_NODATA property. Is this behavior intentional? > -- > David Winslow > OpenGeo - http://opengeo.org/ > ------------------------------------------------------------------------------ > Xperia(TM) PLAY > It's a major breakthrough. An authentic gaming > smartphone on the nation's most reliable network. > And it wants your games. > http://p.sf.net/sfu/verizon-sfdev > _______________________________________________ > Geotools-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/geotools-devel > > ------------------------------------------------------------------------------ Forrester Wave Report - Recovery time is now measured in hours and minutes not days. Key insights are discussed in the 2010 Forrester Wave Report as part of an in-depth evaluation of disaster recovery service providers. Forrester found the best-in-class provider in terms of services and vision. Read this report now! http://p.sf.net/sfu/ibm-webcastpromo _______________________________________________ Geotools-gt2-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users
