Skip to main content
gamedev.net
🔒 Locked

SKYCUBE?

Started by veronica 3 replies 350+ views
Original Post
veronica
veronica
I would like to create a nice looking sky in a school project I am working with. What is the best way to create that? I am using openGL and c++. Is there an easy way to make a skycube or are there alternatives? Can I find source code for this task? /veronica
kalioxen
ECKILLER
ECKILLER
make a cube with faces facing inside. Then texture it with an image of a sky.

ECKILLER
ECKILLER
Superastic
Superastic
If you just slap an image of a sky over a cube you''ll end up with a big mess.
You need to have a seperate 2D sky image for each face of the cube representing the different view directions, and they need to fit together seamlessly, which is very difficult if you''re creating them yourself.
You can get hold of some programs to do this for you, one is Terragen, it can render terrain and skies, just take 5 pictures of the sky, at degrees: 0, 90, 180, 270, and directly up. You can then use these as the cube maps.

Easier still, just apply a single sky texture to a spherical sky dome.
RotoMuffin
RotoMuffin
Just about any modeling/rendering package that can make a half decent sky can be used (even POV-ray). Just align six cameras to each axis in the positive and negative directions, and set all the camera''s field of views to 90 degrees. Render the images and then use the resulting textures as your cubemap.

-R
kadaf
kadaf
Hey! Do not try to make some nice looking sky textures, if you are not just a little artistic.
Just "borrow" some skybox textures from Half-Life or Counter Strike :-) that seems to be the most simple option.

If you want code for setting up the sky box, just pop me an mail, and i''ll send (mullen@forum.dk)

.....
Rasmus Neckelmann
-- Rasmus Neckelmann

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.