skybox question?
Blitz3D Forums/Blitz3D Beginners Area/skybox question?
| ||
Sorry, such a noob! How do you create a skybox? I saw the example with terragen on the blitzcoder site....is there any other way ? Code would be appreciated for study. Thanks. |
| ||
I assume you know how to generate the skybox images (since you saw the terragen tutorial.) Using those images to create a skybox involves the following steps: *Create a cube with the polygons inverted so that they face in. *Texture the sides of the cube with the correct skybox images. *Set the cube to fullbright and no fog so that shading and fog won't affect it. *Set its EntityOrder so that it will be drawn behind eveything else (note: the cube can be pretty small since EntityOrder will force drawing behind everything else. This way it won't be affected by the clip range of the camera.) *Add code so that the skybox will move (but not rotate) with the camera every frame. On Psionic's website there are examples with code for the first two steps, creating and texturing the skybox cube. |
| ||
Do you have an example code? When you say create a cube? just standard cube = createCube() ? I am not sure how to texture individual planes. Also, how do you set fullbright? I guess these are elementary questions, but I do not know the commands to translate what you are saying. |
| ||
The answers I got here are the best yet for creating really effective skyboxes. Including Example Code. Instead of the single-surface CreateCube, the example given creates a cbe from individual polygons that can be textured separately. Give it a try and see how you get on! |
| ||
thanks Malice. Ill give it a shot, the code seems a bit complicated. |