Globe Component
 globeComponent027view, link (75.7 KB, 930700) source (455.5 KB)Thu, 6 Jul 06, 3:32pm UTC 


This is a new version of the globe component. It is designed to be easier to use, and can be used either as an object of the celestial sphere component (plug-in), or as an isolated component (standalone) with a live preview.

When used in the celestial sphere there is no need for the programmer to manually update and position the globe (unlike the earlier globe component), all of that happens automatically. For example, you do not have to define a onMouseUpdate function that repositions the globe when the user drags the celestial sphere around. To add the globe to a celestial sphere instance, all you need is the following line of code:

sphereMC.addObject("Globe Component v2", "globe");

Then, if you want to show sun shading, you would add the following:

sphereMC.globe.instance.showShading = true;
sphereMC.globe.instance.setSunPosition({ra: 0, dec: 0});

All function calls and changes to property values take effect immediately -- you do not have to call an update function.

Note: if you want to show the equator or other features on the globe you still need to do the sphere in a sphere trick.

 globeComponent002view, link (61.8 KB, 500500) source (229.5 KB)Fri, 2 Apr 04, 3:30pm UTC