Current edition: Vol.4, No.10, October 2001
 

Active Worlds News


9.11.01 Remembered 3.2 Launched
3D Homepages
New Website
Tech Support Tip
Skyboxes
Bot of the Month
Worlds to Watch
Hot Spots to Visit
AWEC Calendar
AWCOMREG Articles
Intersculpt 2001
KriegMar Gallery
Halloween

Resources

Building Links
Community Links
AWCOM Links

 

 

icon

 

icon

 

icon

 

 

Skyboxes

Courtesy of Oleyo


Example of a world with a skybox

Wahoo! AW 3.2 has been released and there is now more fun stuff than ever! One of my favorite additions to this version of the browser is the support for skyboxes. Everyone should consider adding a skybox to their world as they can add a great sense of depth. But many of us may wonder, "What IS a skybox and how can I make one?"

What is a Skybox?

A skybox is a 3D model that surrounds your entire field of view. It can be any shape but it is usually in the shape of a box. It rotates with your camera view perfectly so you don't get any of the strange scrolling speeds that can be seen when using a panorama. You can never get closer to the skybox so it maintains the illusion of being very large and distant. Another behavior of the skybox is that it renders behind everything else in the scene, so it always seems to be in the distance. However to make a "real" skybox requires a bit more than just putting our panoramic textures on a box or cylinder.

How do I make a Skybox?

Getting the Textures

If we were to just take some landscape textures and put them in a box then we would see distortion in the corners where the texture is farther away from you than they are at the sides of the box. To get a true skybox, we need to take six camera shots inside a 3D environment…one for each face of the cube. This way, because of the camera, the screenshots will be stretched a bit to compensate for the corners of the box. The program I like to use is Bryce 4.0 by MetaCreations. www.metacreations.com To get the desired images you will need to render images with your camera set to 90 degrees (one quarter of your box) and then turn 90 right, left, back, up, and down. If you do use Bryce, and want a 90-degree aperture, you will actually have to set the camera to 112.5 degrees (90x1.25). This is due to an old bug that they kept around for the purposes of backward compatibility. Here is a great link for some info on creating and using skyboxes:
http://www.gamasutra.com/features/visual_arts/

As always when creating content for AW, It is very important to keep the download size in mind. Having textures that aren't big enough can easily destroy a skybox's illusion. A blocky backdrop will not convey the sense of depth that we hope to achieve. Here are some pointers on texture size:

  • If your skybox has only sky in it, you can get away with a small amount of textures. For a plain cloudy sky, a single 256x256 texture on each side will look fine. (Clouds are blurry anyway)
  • You will be forced to use a lot more textures in your skybox if you want to have details like terrain or mountains. This is not exactly a drawback, if you decide the extra download is worth it then a nice skybox can do a lot for the feel of your world.
  • Consider dropping the bottom texture of the skybox. How often will you see it in AW? Usually you will only see it when you are underground.

Now that we have our textures, lets talk about the skybox model.

Making the Box

Size

Many people believe that the skybox is a massive box that is so big that it surrounds everything that you see in AW. This is not the case. The skybox can actually be any size as your distance to it never changes and it always renders behind everything no matter what. I usually use a 2m square box, which is the default cube size in Truespace and is easy to work with.

Shape

Remember to make sure it is a cube; since your texture maps will be made for a square box. You may however want to consider chopping off everything below the horizon line in order to achieve a smaller download. If you decide to do it this way then you don't need to change how you get skybox textures. Simply take an image as normal, and cut away the bottom half. Ex. If the texture was 256x256 then cut away the bottom half so it is 256x128. Do the same with your box. Instead of being 2m in all dimensions, make it only 1 meter tall (with almost the full meter above the horizon…remember that the reason for cutting off the bottom is because it is going to be out of site most of the time).

Here are some other things to remember when building your skybox:

  • Make sure that the faces of your cube are facing INSIDE the box…that is where your camera will be! If you don't then you wont see your skybox at all.
  • Use the prelight command on all of the vertices of your box. You don't want the box to get darker as you turn down the world lights!
  • And finally: Currently you need to save your skybox one meter higher than you actually want it to be in AW. For example: If you want your eye to be in the center of the box (usually you do) then you need to raise the whole box by one meter in Truespace before you save it. Don't know why yet but we are looking into it. :)

I hope this has been an informative resource.

Happy Building!
-Oleyo

 

  Active Worlds   |   Newsletter Home   |   Newsletter Archive   |   Contact Us    |   Disclaimer