<div>Hello,</div> <div> </div> <div>Thanks for the info. I am not sure whether this specific file that I have contains this key -- I'll need to get more info about this product. I was given a few HDF file formats and asked to retrieve specific fields, but I am not sure whether the products correspond to the spec I am using.</div> <div> </div> <div>I did try to use gdalinfo on the file, as well as on it's subdatasets. A lot of data was outputted, but nothing close to the field I am interested in. So, given that fact, can I conclude that the field is not available in that file? Does gdalinfo and getMetadata return all the possible metadata in that product? </div> <div> </div> <div>Thanks,</div> <div>Inessa<BR><BR><B><I>Andrey Kiselev <dron@ak4719.spb.edu></I></B> wrote:</div> <BLOCKQUOTE class=replbq style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid">On Fri, Jul 14, 2006 at 08:21:32PM -0700, Inessa Shalomov
wrote:<BR>> I am trying to use GDAL and its HDF file format support to extract<BR>> specific metadata fields from an HDF file. The GetMetadataItem()<BR>> call is not recognizing the metadata keys I am passing in, although<BR>> according to the spec I am using, the keys are valid.<BR>> <BR>> I used the following code to <BR>> GDALDataset *poDataset;<BR>> GDALAllRegister();<BR>> poDataset = (GDALDataset *) GDALOpen (pszFilename, GA_ReadOnly);<BR>> const char* retval = poDataset->GetMetadataItem(“PRODUCT_UL_CORNER_LAT”, NULL);<BR>> <BR>> Am I not making the right API calls for HDF? Are there any<BR>> additional method calls to retrieving the metadata?<BR><BR>Inessa,<BR><BR>That should work in case there is "PRODUCT_UL_CORNER_LAT" record in the<BR>metadata of your HDF file. Are you sure that your file actually contains<BR>this record? Have you tried gdalinfo on that file? Are you opening<BR>proper subdataset instead of the main HDF
file (look here for details on<BR>HDF subdatasets: http://www.remotesensing.org/gdal/frmt_hdf4.html)?<BR><BR>Regards,<BR>Andrey<BR><BR><BR>-- <BR>Andrey V. Kiselev<BR>ICQ# 26871517<BR>_______________________________________________<BR>Gdal-dev mailing list<BR>Gdal-dev@lists.maptools.org<BR>http://lists.maptools.org/mailman/listinfo/gdal-dev<BR></BLOCKQUOTE><BR><p> 
                <hr size=1>Groups are talking. We’re listening. Check out the <a href="http://pa.yahoo.com/*http://us.rd.yahoo.com/evt=41144/*http://groups.yahoo.com/local/newemail.html">handy changes to Yahoo! Groups.</a>