![]() |
|
|||||||
| Add-ons & Scripts Find add-ons, scripts, and utilities for World Wind. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: Oct 2004
Location: Austria
Posts: 342
![]() |
Hello,
I made a Plug-in where you can easy add and edit favorite Icons for World Wind. The script works only for World Wind 1.3.2 and higher, it's called My favorite Icons. Please download the favoriteicons.zip, from below and unzip it into your World Wind directory. ![]() Screenshot of the plug-in with international names First I have to say, I'm one those evil copy-cats who taken the code of TomServo's Earthquake Plug-in to make the layer visible. I thank him and ShockFire for the inspiration. I also taken the knowledge of Doug Hill's Favorites Plug-in but only the knowledge how to add an extra menu. Input Form To start it, choose Plugins and load there FavoriteIcons. Afterwards choose in the My Favorite Icons menu, the item Add an Icon or Edit Icons. You are now in the Add an favorite Icon Tab., you can easily add points to a script below is the Favorite Icon List, a table where all Favorites including the Description, ClickableUrl and URI will be shown. You can add either an Icon or an Favorite, the last is only a Link in Favorite Icons. You can make a World Wind script of your Favorites. As option you can also import other files, like GPX Waypoint files, WW Layers, KML Placemark,CSV file, if wanted, also temporary for only finding the places of this files. The Favorites.txt is a tab separated text with 5 columns. Add an Icon simple: Go to the place where you want to add an Icon/Favorite, load either the form in Add an Icon or Edit Icons or press in the form the button "Insert the current coordinates" to get the current coordinates. Insert the Name of the Icon, this will be shown later in the Layer Manager and in Favorite Icons. Input a Description, if wanted, for this point. Also you add a ClickableUrl, after double-click your browser will start with this link. Change, if wanted, the Latitude, Longitude, Altitude, Heading, Tilt and Bank. Choose if wanted at World and Layer which World you want and what kind of Layer you want to switch on with this Icon/Favorite. Below the Latitude, Longitude you can input DMS coordinates. If you choose no at Use the Heading and Tilt for the URI, the Heading and Tilt will not be used for the this Icon/Favorite. After you clicked at the URI field or a different field the URI will be changed. The world will not be changed with the URI, so an URI with Moon as world will go to the coordinates on the Earth if Earth is the current World in WorldWind. Change, if wanted, at Add an Icon/Favorite from Yes (=Icon) to Only Link in Favorites, if want only add an link. Press the Add to Favorites button and now the link will be added at Favorite Icons and a Icon at this place, if you wanted one. You don't need to save anything, all changes will be saved automaticly. Everything below are only options which aren't needed for adding an Icon. You can add either an Icon or an Favorite, the last is only a Link in Favorite Icons. As option you can also import other files, like GPX Waypoint files, WW Layers, CSV file, if wanted temporary for only finding the places of this files. The Favorites.txt is a tab separated text with 5 columns. International users could use their chars, e.g. Chinese, Japanese, Korean, Cyrillic etc., they are not restricted to the standard chars like the placenames do. See below for internationalcities.txt, an example with city names in the original writing. Import it, to see the example. Thai chars are at the moment not supported. If you have the layer manager open, the Layer manager will changed as the only viewing window, the other map will be frozen. Clicking on this icon will remove all icons, also of other plugins. You can test it with Krung Thep, Krung Thep Maha Nakhon, Γ*ΒΈΒΓ*ΒΈΒ£Γ*ΒΈΒΈΓ*ΒΈβ‘Γ*ΒΉβ¬Γ*ΒΈβΓ *ΒΈΕΎ Γ*ΒΈΒ―, Γ*ΒΈΒΓ*ΒΈΒ£Γ*ΒΈΒΈΓ*ΒΈβ‘Γ*ΒΉβ¬Γ*ΒΈβΓ *ΒΈΕΎΓ*ΒΈΒ‘Γ*ΒΈΒ«Γ*ΒΈΒ²Γ*ΒΈβ’Γ*ΒΈβΓ*Β ΈΒ£, http://en.wikipedia.org/wiki/Bangkok. Insert an URI, GPX Data or DMS Coordinates: Under the Insert Coordinates Menu you'll find 3 items. 1. Insert URI, here you can past an URI in the form, World Wind will go to the coordinates, for this function is the shortcut Crtl+U available. 2. Insert a GPX Track Point, here you can past a GPX Trackpoint in the form, World Wind will go to the coordinates, for this function is the shortcut Crtl+G available. 2. Insert DMS Coordinates, here you can past DMS coordinates in the form, the coordinates should be formatted XXΓΒ°XX'XX" XXΓΒ°XX'XX", e.g. 37ΓΒ°49'35" 122ΓΒ°25'18" with the orientation char before or after the coordinates,World Wind will go to the coordinates, for this function is the shortcut Crtl+D available. These are all input options. Editing, Searching, Removing and Inserting new points For Searching in the Icon List, input the name at Search for Icon/Favorite and press Search, the cursor in the DataGrid, the table, will go to this place and World Wind will go to this place. For removing the current Favorite you can use Remove Current Favorite, Remove All Favorites deletes all entries except the first, this one will be replaced with your input. Remove All Favorites will delete your Favorites file, therefore be careful. For Editing a Favorite press Edit Current Favorite, the form will filled with data of this entry also World Wind will move to this place if the Favorite has coordinates. You can now edit this data in the form, add Description, ClickableUrl, change the URI and so on. If you press "Add to Favorites", the Favorite will be replaced with the data of the form, normally. You see on the right side the Textbox "Insert Position", normally there is no number in the box, only after you press Edit Current Favorite, you see a number, that is the entry number. You can insert not replace the entry if you choose no at Replace Favorite at Insert Position, if you also choose yes at Insert multiple lines you will insert all input until you choose no at this option. You can also simple input a number at "Insert Position" and choose no for the first option and yes for the second and you insert all points at the entry number, you filled in. Moving the icons/favorites of the Icon List For moving the current entry there are 4 options, the Arrow buttons. First choose the row you want to move and then press the button. The ^-Button is for moving the entry up. The v-Button is for moving the entry below. The ArrowUp-Button is for moving the entry on top of the list. The ArrowDown -Button is for moving the entry on the bottom of the list. Make a World Wind Script For using Heading and Tilt please either replace the Timeline.dll or changing the WorldWindAutomation_v1.xsd (Replace the string Horizontal and Vertical with HorizontalAngle and VerticalAngle). The Timeline.dll with correct handling of at least the Tilt could be found at the Skripter description. For making a World Wind script you can choose at Make a WW Script temporary either Make a Simple WW Script or Make a WW Script. Make a Simple WW Script makes a script with constant velocity of 60 kilometres per second and viewing in the direction of the next point. This file is named IconFavorites.xml and could be found in the Scripts directory. You can now call the script at Plug-Ins| Scripts. For making script with more options choose Make a WW Script, here you can choose the delay, viewing direction, whether you want to show the Icon/Favorite names as message and save it in different file. Please fill in the script name, the repeats and if wanted a short description. Choose at Use the adapted timeline.dll or by-pass the Heading/Tilt problem with Script change the option By-pass the Heading/Tilt problem by inserting HorizontAngle/VerticalAngle after Change of WorldWindAutomation_v1.xsd if you want at least use the tilt and after you replaced the Horizontal and Vertical with HorizontalAngle and VerticalAngle in WorldWindAutomation_v1.xsd. Check the For only using the Script with WW 1.3.1: Change the Coordinates from 00.00000 to" 00000E-5 for International users with comma as decimal seperator if you are from a country with comma as decimal separator and want to use the scripts for WW 1.3.1,too. If you want check at Show the Icon/Favorite Name as message Yes and choose the Horizontal and Vertical Position of the Message. You can also choose if you want to view in the direction of the next point automatically, Use the heading and tilt data from above, view to North with tilt or no heading and tilt. For the delay time you can choose if you want to use the Use the Delay Time right, constant velocity or constant velocity with altitude change. Then press Save the Script, choose a name for the file and press Save, you can now use the file. Import Files to the Favorites list You can either import a Favorite Icon file, GPX waypoint file, a Text/CSV file, a KML Placemark file or a layer file , the first one for editing, append and so on. To Import files choose Import Icons/Favorites. You can choose at Append to Icons/Favorites or load as Icon/Favorite temporary, if you want to append the imported icons/favorites to the Favorites file, to import the file only temporary. If no is checked, it has the same function like Remove All Entries, this will delete your Favorites file, be careful. If you choose Show the imported Icons temporary, the points of the file will be shown in the Imported Icons layer and links will be added in Imported Icons/Favorites. There will be only links added, if you choose Only add a Link in "Imported Icons/Favorites" temporary. Change, if wanted for the first two append options, at Add Icons for the points from Yes (=Icon) to Only Link in Favorites, if want only add an link. Change the Altitude, it will be the Altitude of the Favorite view. For a Favorite Icon file, GPX waypoint file or a layer file, simply press the button. For opening a KML file, you can choose if you want to use the source altitude or the altitude you filled in the form. For a Text/CSV File you have to change the column headers of this file. Mandatory is Latitude and Longitude or IconUri and IconName. IconUri (=World Wind URI, worldwind://..) is alternative to Latitude and Longitude. You can also have a Description, , ClickableUrl, Altitude, Heading, Tilt, ShowIcon column. The position info (Altitude, Heading, Tilt) is useful for going to this place additional to Latitude and Longitude. ShowIcon could be used to set whether Icon will be shown (=1) for this point or not (=0). Please first choose how the values are separated or better in which format you saved it. The best format to use, is separated by Tabs, you will not have the problems to look in the file how it is separated. Because in countries with comma as decimal separator, the CSV file will be there separated by a semicolon. Then choose the Kind of coordinates, Decimal Point or Comma for standard coordinates or DMS for DMS coordinates, e.g. N 47ΓΒ°40'43" E 15ΓΒ°43'52". Export to a File You can save the data as Favorite Icon file, for sending to somebody else. For saving as Layer file, please fill in a Layer name. Change if wanted Save all Points (Icons/Favorites)to Save only Icons, so only the Icons of this file will be saved, not the others which are only a link. Change if wanted Show only this Layer to Yes, so only this Layer will be shown, no Image Layer, nothing else. Change if wanted Show this Layer at World Wind Start to Yes, so the Layer will be shown at World Wind Start. Press Pick an Toolbar Icon to choose the Icon for the toolbar, best size of this Icon is 128x128 pixels. Then click the Save the Layer button, save the Layer as .xml file in the Config/Earth directory. After restart of World Wind the Toolbar Icon should be visible and if press on it the Layer should be shown. Known Problems Thai chars aren't supported. No tilt in scripts without without either replacing the Timeline.dll or changing the WorldWindAutomation_v1.xsd, (Replace the strings Horizontal and Vertical with HorizontalAngle and VerticalAngle) but this is a WW specific problem. Maybe the right to left written names have problems, they could be written in the Favorites from left but in the layer form and at the icon the name is written correct. The problem with & (=ampersand) in layers, because of HTML codes starting with &, is bypassed by auto-replace at layer export. Large Numbers (about 44000 Icons) of Icons will take a long time to load if they are imported the import process lasting to long. No switch between Moon and Earth with URI, they go both to the current world. No switch between Moon and Earth with URI, they go both to the current world. Changes of a field of the URI parts (Latitude, Longitude, Altitude, Heading, Tilt, Bank and World and Layer) will be only made after you clicked on other field, the URI or your added the Icon/Favorite to the Favorite Icon List. Handbook, PDF, 153 kb canosso
__________________
My Plug-ins for World Wind |
|
|
|
|
|
#2 |
|
Senior Member
Join Date: Dec 2004
Posts: 334
![]() |
Canosso
I've downloaded you plug-in and am following the instructions. Looks Great. Will take a little time to work out how to make it all work. I'll watch this thread with interest. Combining all the plug-ins and their functions must be a bit confusing for newcomers. Maybe the most necessary ones, like placemarks, tracks, layers, navigation controls, gps and wms options etc. should be included in the initial program download. Most of the other individual add-ons should remain as options for users to download if interested. I hope everything still works with !.4 when it comes along. Thanks to all the developers. |
|
|
|
|
|
#3 | |
|
World Wind Developer
Join Date: Aug 2005
Location: United States
Posts: 358
![]() |
Quote:
Dan |
|
|
|
|
|
|
#4 |
|
Cosmic Overlord
Join Date: Oct 2004
Location: United Kingdom
Posts: 2,362
![]() |
Well the next version of World Wind, after 1.3.x, will be 1.5 this will be a complete code re-write so plugins and add-ons for 1.3.x may not work, but this isn't likely to happen before 2006, and things may change.
But before you all panic the coding for 1.5 hasn't even been started yet, and its not even really in the design stage, just ideas being thrown around. Personally I imagine a plugin could always be made to allow 1.3.x add-ons to work in 1.5. |
|
|
|
|
|
#5 |
|
Member
Join Date: Feb 2005
Location: Austria
Posts: 96
![]() |
hey canosso !
man, you are doing really great work! i was testing your 'favorite icons' plugin .... hmmm..... what should i say about? everyting works great - and even importing a big load of positions (was testing it with about 10.000 positions) seems to be no problem.... GREAT WORK - like all the code you submit ![]()
__________________
browse and download all free AddOns i have built for World Wind and Punt http://www.dynagis.net/wwdownload/free_addons.html |
|
|
|
|
|
#6 |
|
Senior Member
Join Date: Oct 2004
Location: Austria
Posts: 342
![]() |
Hello,
now are all chars supported, except Thai chars. Line breaks could be made in the Description. I improved the CSV import, so there are more import possibilities. @aussiemac: I will improve the usability of the program. canosso
__________________
My Plug-ins for World Wind |
|
|
|
|
|
#7 |
|
Senior Member
Join Date: Oct 2004
Location: Austria
Posts: 342
![]() |
Hello,
I separated the forms for better usability and added a WW Script writing feature, one for a simple script and the second for parameter input. The first writes a file IconFavorites.xml in your Script directory, I would prefer to call the Timeline.Scriptplayer, the script feature of World Wind, by a plugin, so nobody would need to first save the script and then start it. I hope you enjoy the plug-in. canosso
__________________
My Plug-ins for World Wind |
|
|
|
|
|
#8 |
|
Senior Member
Join Date: Oct 2004
Location: Austria
Posts: 342
![]() |
Hello,
I added a KML Placemark import option. You can choose if you want to use the Altitude of your source file or the Altitude you filled in the form. canosso
__________________
My Plug-ins for World Wind |
|
|
|
|
|
#9 | |
|
Cosmic Overlord
Join Date: Oct 2004
Location: United Kingdom
Posts: 2,362
![]() |
Quote:
|
|
|
|
|
|
|
#10 |
|
Member
Join Date: May 2005
Location: Toronto, Canada
Posts: 47
![]() |
When trying to load the favorites icon, I got the error:
Cannot find a part of the path C rogram files\Nasa\Worldwind 1.3\plugins\favoriteicons\favorites.txtthanx Rick |
|
|
|
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Favorites / Bookmarks plugin | Dugrhill | Add-ons & Scripts | 21 | 02-27-2010 04:59 AM |
| Another favorite Icons plugin | jp09 | Add-ons & Scripts | 20 | 05-15-2006 07:38 PM |
| World Wind Favorite Icons | ericrose | Add-ons & Scripts | 9 | 11-28-2005 08:38 PM |
| stereo viewer plugin | jumpjack | Add-ons & Scripts | 15 | 08-19-2005 09:48 PM |