# Making a custom skybox from photos

Yesterday night was a full moon and the clouds were awesome, the perfect setting for my current mapping project, so I went and took a bunch of photos for a panorama. Now I’ve managed to mesh them all together to create a hemispherical panorama, and I cannot figure out how I should go about converting this into a skybox. I don’t care about anything below the horizon, so I’ll only need to make a ceiling and the top half of the 4 walls from this picture. I’d imagine I’d want to do something like this:

http://img33.imageshack.us/img33/3585/386232.png

but there’s just no way I can do that manually and get it right. Has anyone done this before, or have any ideas?

This is the composite hemisphere I’m working with, at 25% scale:

http://img180.imageshack.us/img180/7578/wipsky2.png

Valve has a skybox setup with at least 5 separate square images (right, left, up, front, back).

I’ve actually tried creating a tutorial on skybox creation over at my site sourcefilms.org. It’s intended for information on creating machinima using the Source engine, but there are some mapping elements here and there.

http://sourcefilms.org/wiki/index.php5?title=Skybox_Creation

Thanks, but it’s not quite what I’m looking for. I know how to make a skybox from square or rectangular images, but morphing this panoramic circle into 5 sides of a skybox has me stumped. This probably falls under image editing rather than mapping, but I was hoping it was a common procedure.

What I think I need to do, is turn this circle into a square by pulling the diagonals out to form corners, but I cannot find anything in GIMP or online that does this (like below)

http://img25.imageshack.us/img25/7600/explanation.png

After this I’d be able to cut a square out of the center for the top, then cut the four resulting sides into trapezoids which would be perspective-morphed into rectangles, and it would be done. I just can’t find anything to turn that circle into a square…

I attempted to use lens distortion to solve the problem, but it stretches horribly, although otherwise it looked great in game. If it’s any incentive, I’m going to release this skybox when I get it finished.

You make a panorama, apply it to a basic sphere primative in a 3d modelling program, set up a camera inside the sphere and then render 6 images all with a 90 degree fov.