VRML coding Help: Backgrounds, Lights, LOD, Sound


 

 

Including a background in your Virtual World

This can't be done within Cosmoworlds so we will have to edit the VRML code itself.

First open the file in Jot.

Then just under the line that says

#VRML2.0 UTF CosmoWorlds 

put the following text in your file.

backGround { 

bottomUrl    ["yourimage.gif"]
backUrl       ["yourimage.gif"]
frontUrl       ["yourimage.gif"]
leftUrl         ["yourimage.gif"]
rightUrl       ["yourimage.gif"]
topURL       ["yourimage.gif"]
            }

The terms (called fields in VRML) bottomUrl, backUrl ...   allow you place images in the infinite distance.  These fields make a cube that your viewpoint is always within.  For example, the backUrl puts your image at z = -infinity and the frontUrl field puts your image at z=+infinity.  You can use the same image or different images in each field depending on the concept you are trying to model.