World Wind Forums

Go Back   World Wind Forums > Community > Add-ons & Scripts

Add-ons & Scripts Find add-ons, scripts, and utilities for World Wind.

Reply
 
Thread Tools Display Modes
Old 02-16-2007, 07:18 AM   #1
patmurris
WWJ Consultant
 
patmurris's Avatar
 
Join Date: Jun 2005
Location: Saint-Paul de Vence, Alpes Maritimes, France
Posts: 3,412
Lightbulb 3D Cross Section plugin and viewer

Here is version 1.4 beta 3 of the 3D Cross Section plugin (Zip 1.1M).

UPDATE 2007-02-23 : Version 1.4 released - see this post on page 3

It allows to select a square area of terrain and view the 'cut-out' in a separate 3D window - the terrain viewer.



The 'terrain extraction' and SRTM .bil export plugin has been written by withak - Thanks a lot

The 3D window is the 'Mini terrain viewer' I've been working on at times, and made better for the occasion. It can be used outside WW. You can load previously saved cross sections, and even view the SRTM tiles in WW cache by dropping them over. You can also apply different color schemes...

Install

1. You need WW 1.4 (as of today).

2. Unzip in your WW Plugins directory. That should add a folder named '3DCrossSection'.

3. Start WW and the new plugin should be listed in Plug-ins->Load/Unload.
Select the plugin and click 'Load'. It should turn green.

4. Once loaded, it becomes an option in the Plugins menu.


Usage

1. Navigate to the place you want to cut out - with a vertical view

2. Click Plugins / 3D Cross section... to select the area.

3. Adjust the selection size and heading, move the terrain and recenter...

4. Enter a file name with no extension Ex: "My_Terrain", enter a short description

5. Click 'View selection' and be ready to wait a bit... (10... 20 sec)

6. Once the terrain viewer comes up, you can examine the terrain section as in WW
and change the color schemes by using the Textures and Sides menus.

Some keyboard controls (more here) :
  • Shift + / - : change camera field of view (zoom)
  • Ctrl + / - : change terrain vertical elevation factor

Hawai - cut out from World Wind with vertical exaggeration



SRTM level 10 .bil file from WW cache - no vertical exaggeration

This is a beta... still some issues to solve. I hope to add textures from WW layers too and maybe plot 3D points from imported data (earthquakes...).

BTW : According to "NASA/NGA MEMORANDUM OF UNDERSTANDING" regarding SRTM data, they are freely redistributable. Thanks Bull for the link.
__________________
My World Wind Java Blog & WW.net Plugins page

Last edited by patmurris; 02-24-2007 at 06:02 PM.
patmurris is offline   Reply With Quote
Old 02-16-2007, 08:36 AM   #2
uninspiredname
Member
 
Join Date: Apr 2005
Posts: 31
Default

Amazing!! Great job once again!
uninspiredname is offline   Reply With Quote
Old 02-16-2007, 10:31 AM   #3
jp09
Senior Member
 
Join Date: Jun 2005
Location: France
Posts: 166
Default

Wow,it's wonderful job !!!
Trying it at once !
jp09 is offline   Reply With Quote
Old 02-16-2007, 11:36 AM   #4
jp09
Senior Member
 
Join Date: Jun 2005
Location: France
Posts: 166
Default

Tsss tssss tssss !
Patmurris, it will not work for french users ! Still that decimal separator pb : in the form, I've got a french ',' decimal separator for lat, lon, rotation, and that's certainly why it won't extract anything for me

Edit : I've found a solution : I'm not sure it's a clean one, because I'm not sure of its extent... but it works : adding
System.Threading.Thread.CurrentThread.Cu rrentCulture = System.Globalization.CultureInfo.Invaria ntCulture;
in Load()

Very nice plugin indeed
jp09 is offline   Reply With Quote
Old 02-16-2007, 02:28 PM   #5
withak
What?
 
withak's Avatar
 
Join Date: Apr 2005
Location: San Francisco, California
Posts: 2,464
Default

I wondered about . vs , in the Plugin but then forgot to ask Pat whether it should use local settings or global.

You can probably fix it by changing every ".ToString()" in the plugin to ".ToString(CultureInfo.InvariantCulture) " and adding "using System.Globalization;" at the top of the file. That will make sure the xml gets written with . as the decimal separator no matter what your local settings are. The display boxes would still use your current settings.
withak is offline   Reply With Quote
Old 02-16-2007, 03:07 PM   #6
TomServo
God. Root. What is difference?
 
TomServo's Avatar
 
Join Date: Sep 2004
Location: Eastern Pennsylvania
Posts: 2,856
Default

Sweet! Great work!
__________________


Earth is Square blog

PUBLIC NOTICE AS REQUIRED BY LAW: Any use of this forum post, in any manner whatsoever, will increase the amount of disorder in the universe. Although no liability is implied herein, the consumer is warned that this process will ultimately lead to the heat death of the universe.
TomServo is offline   Reply With Quote
Old 02-16-2007, 05:39 PM   #7
m_k
Bored Explorer
 
m_k's Avatar
 
Join Date: Nov 2004
Location: Warsaw, Poland
Posts: 1,737
Default

Great job!

Some thoughts:
1. It would be nice to have the elevation factor displayed somewhere.
2. From what I see the light source moves with the camera (or maybe it's absolute and the terrain moves I would like a relative-to-ground shading mode
3. And apart from that globalization bug there's a minor issue with selection frame being rendered as grey when sun shading is enabled.
__________________
Hot stuff: FAQ, forum search, DirectX, .NET, Video Card Compatibility list
m_k is online now   Reply With Quote
Old 02-16-2007, 05:45 PM   #8
TomServo
God. Root. What is difference?
 
TomServo's Avatar
 
Join Date: Sep 2004
Location: Eastern Pennsylvania
Posts: 2,856
Default

Hmm... I wonder if this could be adapted to work with the EQ plug-in.. so you can do a 3D section and show the earthquakes at depth.
__________________


Earth is Square blog

PUBLIC NOTICE AS REQUIRED BY LAW: Any use of this forum post, in any manner whatsoever, will increase the amount of disorder in the universe. Although no liability is implied herein, the consumer is warned that this process will ultimately lead to the heat death of the universe.
TomServo is offline   Reply With Quote
Old 02-16-2007, 07:25 PM   #9
mazop
Member
 
Join Date: Feb 2005
Location: Austria
Posts: 96
Default

yes, really *great* job !

Quote:
Originally Posted by m_k View Post
Great job!

Some thoughts:
1. It would be nice to have the elevation factor displayed somewhere.
2. From what I see the light source moves with the camera (or maybe it's absolute and the terrain moves I would like a relative-to-ground shading mode
3. And apart from that globalization bug there's a minor issue with selection frame being rendered as grey when sun shading is enabled.
4. No Sky-texture when using .bil's for terrain?
If i use .bil's for terrain, i cant get a sky-texture to load. when i convert the .bil to .png and load it as the terrain, loading of sky-textures works.
__________________
browse and download all free AddOns i have built for World Wind and Punt
http://www.dynagis.net/wwdownload/free_addons.html
mazop is offline   Reply With Quote
Old 02-16-2007, 07:45 PM   #10
patmurris
WWJ Consultant
 
patmurris's Avatar
 
Join Date: Jun 2005
Location: Saint-Paul de Vence, Alpes Maritimes, France
Posts: 3,412
Default

Quote:
Originally Posted by jp09 View Post
Tsss tssss tssss !
Patmurris, it will not work for french users ! Still that decimal separator pb : in the form, I've got a french ',' decimal separator for lat, lon, rotation, and that's certainly why it won't extract anything for me
Oups... where and how does it fail exactly ? Before or after you click 'View selection' ?

Quote:
Originally Posted by mazop View Post
Hmm... I wonder if this could be adapted to work with the EQ plug-in.. so you can do a 3D section and show the earthquakes at depth.
I'm thinking of allowing to import lists of point data in the viewer (like csv with lat/lon/elevation/description on each line). Any idea how the eqs could be made available that way - or another way ?

The sky is coming...
How long does it take for you to get the selection in the viewer ? on my aging cpu it takes up to 20 seconds... a progress bar would be needed here i think...
__________________
My World Wind Java Blog & WW.net Plugins page

Last edited by patmurris; 02-16-2007 at 07:48 PM.
patmurris is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may post new threads
You may post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
stereo viewer plugin jumpjack Add-ons & Scripts 15 08-19-2005 09:48 PM


All times are GMT +1. The time now is 04:47 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.