Mapdev:Howto skybox

From Spring
Revision as of 08:23, 25 April 2007 by Smoth (talk | contribs)
Jump to navigationJump to search

-I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth -I am working on this... do not edit it please. -Smoth


Skybox Information

This is going to contain notes about the creation of skyboxes aka cubemaps.

Skyboxes are created with a series of 6 separate images which form what we call a cube map. Below is an example of the skybox images that I created for a map.

this is what we call a cube cross
this is what we call a cube cross

Despite what you will see on many sites you do not need a cube cross for the creation of your skybox. You will be using six individual images. Each image represents a different face on an imaginary cube. Each face is applied to the cube that surrounds the map.

see how each side of the cube is it's own image
see how each side of the cube is it's own image

Here an image is being applied to the cubemap. See how each side of the cube is an image?


Skybox creation


Creating your 6 textures You will need six images representing each side of your skybox. I will not go into any specific method of construction. There are tutorials out there for that. Just remember you will need 6 textures, front, back, left side, right side, top and bottom.

Creating your dds using the nvidia dds utilities You will need these utilities from Nvidia's website: http://developer.nvidia.com/object/dds_utilities.html


Once you have downloaded and installed the tools you will need to created 2 files:


Compiledds.bat and cubemapfile.lst


Inside of compiledds.bat type in: nvdxt -cubeMap -list cubemapfile.lst -output cubemap.dds

pause This will compile your skybox to the name cubemap.dds, feel free to change the name. Also, the pause command will stop the the batch file and force it to wait before it closes, this will allow you to see any errors that may or may not occur.


Inside of cubemapfile.lst type in: left.jpg right.jpg top.jpg bottom.jpg front.jpg back.jpg


The .dds file created should be put in the /maps directory with your smd and smt.

Skybox notes


Do not do these: sizes that are not to the power of two... 'i.e. use sizes like, 64x64,128X128,256X256 or 512X512'

The reason: in my first release I used a series of 6 1000X1000 images and the ati video cards were having horrid fps. So avoid it by using 512X512.