Results 1 to 2 of 2

Thread: Lunar DEMs

Threaded View

  1. #1
    Software Dev/Rep Gracious Donor waldronate's Avatar
    Join Date
    Mar 2007
    The High Desert

    Default Lunar DEMs

    In a discussion with a fellow on the Wilbur mailing list, he pointed out a set of new Lunar DEMs that I had not seen before. has files dated from August of this year in various resolutions. The pretty DEMs are the LDEM* files, not the LDEC* files.

    He wanted to open these files in Wilbur, so I explained the process for opening the files directly instead of using a PNG (it seems Wilbur doesn't like the large 16-bit PNGs he was using). The process is:

    Download the LDEM_.IMG file and its associated LDEM_.LBL file. We'll use the LDEM_16.IMG file because it's a reasonable size and not overly large. Don't want to swamp the servers, now do we?

    Open up the .LBL file in something like Notepad and find the lines that read LINES and LINE_SAMPLES. These are the height and width of the image, respectively. The SAMPLE_TYPE and SAMPLE_BITS will tell you the endianness and size of each sample. You may also wish to locate the MAXIMUM_LATITUDE, MINIMUM_LATITUDE, WESTERNMOST_LONGITUDE, and EASTERNMOST_LONGITUDE entries as these represent the extents of the map. The LDEM_16 file is a whole-sphere file, but the higher-resolution data takes several files to cover the globe.

    Use File>>Open and select "Binary Surface (*.bin)" as the type, enter "*.img" in the file name part, and pick your desired IMG file.

    Click image for larger version. 

Name:	Open.png 
Views:	54 
Size:	11.9 KB 
ID:	38386

    In the Import File dialog, enter the LINES value in both places that read "Width" and the LINE_SAMPLES value in both places that read "Height". Set the type to 2 byte if SAMPLE_BITS is 16, 1 byte is SAMPLE_BITS is 8, or 4 byte is SAMPLE_BITS is 32. Check the "LSB First (Intel)" box if SAMPLE_TYPE reads "LSB_INTEGER". Set Header Length, X Start, and Y Start to 0. The Map Edges Top, Left, Right, and Bottom should correspond to the .LBL files MAXIMUM_LATITUDE, MINIMUM_LATITUDE, WESTERNMOST_LONGITUDE, and EASTERNMOST_LONGITUDE, respectively.

    Click image for larger version. 

Name:	Import.png 
Views:	48 
Size:	5.9 KB 
ID:	38387

    Then click OK and the full-resolution data should appear in Wilbur, ready for whatever you'd like to do to it.

    Click image for larger version. 

Name:	Opened.jpg 
Views:	69 
Size:	81.4 KB 
ID:	38388
    Last edited by waldronate; 09-08-2011 at 12:05 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts