Hello Ian, Not sure if this is reliable, but you could try:
GridEnvelope gridRange = layer.getReader().getOriginalGridRange(); Then use the (oddly named) getLow and getHigh methods of GridEnvelope to retrieve the image dimensions. Michael On 13 August 2012 22:53, Ian Mayo <i...@planetmayo.com> wrote: > Hi all, > I'm successfully using GeoTools to load, project, and present scanned > geo tiff images via SWT. > > But, my users would like to be able to view an image at it's native > scanned resolution - so that it is displayed without any resampling. > I believe I've just got to retrieve the image dimensions, set the > screenarea to those bounds the data area to the bounds of the image, > and I'll have a 1:1 representation. > > I've been through the API (Javadoc) documentation, but can't find how > to find the native image size of a GridReaderLayer object. > > Can anybody provide any tips on how to get the original image size please? > > cheers, > Ian > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > GeoTools-GT2-Users mailing list > GeoTools-GT2-Users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ GeoTools-GT2-Users mailing list GeoTools-GT2-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users