2009/4/15 Jody Garnett <[email protected]>:
> Have you read the javadocs?
> - 
> http://java.sun.com/j2se/1.3/docs/api/java/awt/image/Raster.html#getSample(int,
> int, int)
>
> You need to call the correct getSample method to match the data type
> stored in the raster.
>

But it looks like xx is using a JAI iterator which, I'm fairly sure,
allows you to call either getSample (return type is int),
getSampleFloat or getSampleDouble regardless of the data type of the
image.

Back to the question of getting different values from getRGB(x, y) and
RectIter.getSample() - I'm afraid it's almost certain that the problem
is in your code rather than these methods.  When you create an
iterator it initially points to the origin (minX, minY) of band 0 in
your image.

Hope this helps

Michael

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to