comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: JPEG2000 and GEOTIFF query
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: JPEG2000 and GEOTIFF query [message #61726] Wed, 30 July 2008 06:25 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Gaurav writes:

> I am working with large volume of geo-referenced data and would like
> to save the images that I have in JPEG2000 format. I have seen that
> one can preserve the geographic information when one uses proprietory
> softwares like ENVI, even in jp2 format. They even have a name: GeoJp2
> for it. My question is, can we create JPEG2000 images using IDL so
> that they preserve the geographic information? It is easily done in
> the case of TIFF images using the GEOTIFF tag. Is there something of
> the sort available for JPEG2000?

In the case of georeferenced JPEG images, ENVI simply writes
a separate TIFF World File containing the map information in ASCII
format. This files are simple to write and you can do it yourself:

http://www.omg.unb.ca/~jonnyb/processing/geotiff_tifw_format .html

They give these files a .jgw extension, so that if you open a JPEG
file, and have a file of the same name with this extension in the
same directory, it just opens and reads the map data from this file.

> And talking of TIFF, I would like to bring it to the notice of the
> powers-that-be at IDL that it would be very useful if they could
> modify the use of GEOTIFF keyword. Right now, if you obtain a sub-
> rectangle of a large TIFF image, the structure returned by GEOTIFF is
> exactly the same as it would be for the whole image. Would it not be
> much more convenient if, in the case of subset images, the GEOTIFF
> structure contains the geographic information about that small section
> of the image, viz, the new easting, northing values etc. Right now I
> have to do it on my own and I usually get confused offsetting the
> values for the sub-rectangle.

It would probably be more convenient, but normally this is where
well-written algorithms play a role. ;-)

And, anyway, the GEOTIFF information is associated with the entire
image, and the entire image is still present in the file when you
read a sub-set, so... It seems reasonable to me that it would be up
to the programmer to figure out what is going on. Given that you have
all the information you need in the GeoTiff structure and in the info
structure returned by the Query_TIFF function, it would be a lazy
programmer, indeed, who couldn't figure out how to assign a lat/lon
to a sub-set pixel. But maybe that's just me being cranky this
morning. :-)

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
[Message index]
 
Read Message
Read Message
Previous Topic: Re: how to save the console output as a ascii or text file in IDL
Next Topic: Re: problem with online help IDL v7.0

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 22:36:17 PDT 2025

Total time taken to generate the page: 0.16083 seconds