mjbWorld program - Extensions to support astronomy and planetary motion

Here are proposed extensions grouped according to classes involved:

Support planetary motion

Vrml node: PROTO

Class: kinematicsBean and DynamicsBean

Since VRML/X3D does not support this directly I suggest inventing some custom standard nodes (not part of VRML/X3D specification) when saving to a standard VRML/X3D file they would have to be converted to a PROTO, scripts, etc.

The kinematicsBean would control such things as spin speed, orbit speed, orbit angle and optionally other parameters associated with elliptical orbit (semimajor axis, foci, periheilion, aphelion, etc.)

The dynamicsBean would calculate these from initial conditions, mass, inertia tensor, and forces.

User interface: wizard to create and edit planetary system

Vrml node:


New screen, shows planets with moons in a row, allows:

Support midi files

Vrml node: AudioClip and Sound

Class: SoundBean and AudioClipBean

Get these classes to work, we do not need full functionality but it must:

Texture support

Vrml node: ImageTexture and PixelTexture

Class: ImageTextureBean and pixelTextureBean

Support texture transform

Vrml node: TextureTransform

Class: textureTransformBean

Allow the texture to be moved relative to the object so that, for instance, the poles are positioned correctly. This requires:

Support scripts

Vrml node:

Class: ScriptBean

Implementation of script node using JavaScript

User interface: trackball system

Vrml node:


Improvement to movement tracking using mouse, to allow.


Vrml node: Background

Class: backgroundBean

Support for star background, either by Backround which links to image via URL or by using TextureBackground. I am not sure about all the issues with this. For instance how would the background move when the camera moves.

Surface of planet

Vrml node: ElevationGrid and Geo nodes


If we are looking at moons from surface of planet, do we need some interesting surface on planet? For instance, elevation grid? This could be generated randomly? Or possibly if we used geo nodes we might be able to use data from earth locations?


Vrml node: Material transparency field or ColorRGBA or Color RGBA color model or Fog


Atmosphere, Cloud map, etc. might be indicated by a partly transparent sphere around the outside of the planet/moon. Possible ways to implement this might be:


Vrml node: LOD

Class: LOD

Level of Detail (LOD) could be used to speed up rendering.


metadata block
see also:


Correspondence about this page

Book Shop - Further reading.

Where I can, I have put links to Amazon for books that are relevant to the subject, click on the appropriate country flag to get more details of the book or to buy it from them.


Commercial Software Shop

Where I can, I have put links to Amazon for commercial software, not directly related to this site, but related to the subject being discussed, click on the appropriate country flag to get more details of the software or to buy it from them.


This site may have errors. Don't use for critical systems.

Copyright (c) 1998-2015 Martin John Baker - All rights reserved - privacy policy.