What's the best way to create/edit a skybox?

  • If you're asking a question make sure to set the thread type to be a question!

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Okay, for some reason I've been struggling with this excessively the last few days.

I've been trying to edit one of Valve's skyboxes, but the problem is that I just can't get the parts to be seamless. I tried getting every part of the skybox in the same picture and editing them as a whole, and then I cut that picture into parts - but there were still seams in the places where the picture ended.

I've seen a lot of successful attempts at modding Valve's skyboxes around here - what's the trick?

I read [ame=http://forums.tf2maps.net/showthread.php?t=5268]this[/ame] tutorial, but it doesn't really explain how to get the pictures to be seamless.
 
Last edited:

DJive

Cake or Death?
aa
Dec 20, 2007
1,465
741
Big Rexy did an amazing right up on this.


[ame="http://forums.tf2maps.net/showthread.php?t=5268"][TUTORIAL] The Complete Guide To Implementing Custom Skybox Textures And Env Lighting [/ame]
 

YM

LVL100 YM
aa
Dec 5, 2007
7,135
6,056
Photoshop

make one file with all the sides in (except top and bottom) and make them seamless, then simply crop each one when you save them as vtfs again. you can use the offset filter to get the end ones seamless too.

then i generally take all four sides and arange them in a square with their tops facing inwards with the top one in the middle, i then make that one seamless without altering the sides and then crop out the sides to save it.
 

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Hm, nice idea about arranging them in a square like that afterwards, that's pretty much what I've been missing - I managed to get the side edges right, but the top ones kept bugging me.

 

Beamos

L2: Junior Member
May 14, 2008
80
43
Photoshop

make one file with all the sides in (except top and bottom) and make them seamless, then simply crop each one when you save them as vtfs again. you can use the offset filter to get the end ones seamless too.

then i generally take all four sides and arange them in a square with their tops facing inwards with the top one in the middle, i then make that one seamless without altering the sides and then crop out the sides to save it.

Yeah, I do something similar to this.

(It can be nice and procedural if you want it to be!)

  1. Make a long 1024x4096 canvas. This piece will eventually be turned into your left, front, right, and back panels.
  2. Paint it how you want the sky to look. Keep in mind that you're not painting the top yet! You're just painting the sides!
  3. After you do that, slice the canvas into 4 1024x1024 parts.
  4. Move the last 2 slices next to eachother as if the entire canvas wrapped around. If you were to print out your sky as it is right now and tape the ends together, you'd want it to be seamless, right? This is one part of making it seamless. So move those 2 side panels next to eachother so that the sides that'd be touching if you were to tape the canvas together are indeed touching. (Maybe I should post a picture to show what I mean....)
  5. Paint them to make them seamless.
  6. Optional step: Make sure you apply the new painting changes you just made to the altered panels! Now, if needed, cut the panels up (again) into 1024x1024 panels. Depending on how you painted the panels, you may or may not need this step.
  7. Change the canvas side to 3072x3072.
  8. Take each of the 4 panels, and place them in a cross (+) shape. YOu want a blank 1024x1024 piece to be flush inbetween the panels in the middle of the cross. The current panels you have make up the spokes of the cross.
  9. Rotate each panel so the *TOP* part of each panel is facing the middle panel.
  10. Now it gets tricky. We're going to paint the middle panel, which will eventually become the top panel. Depending on the nature of your envisioned sky, you could do something very simple, or very detailed and complex. I won't go into detail though. Basically, it involves taking the 4 panels and overlapping them, then airbrushing the new center panel to make it seamless and look good.
  11. If you're airbrushing the middle panel-side panel sides, be careful so as to not break the seamless nature of the current side panels.
  12. Once you're satisfied, break up all 5 panels (4 sides + the top panel), rotate them back to their original rotations (side panels will face up), and for the middle panel, well, you might or might not need to rotate it, depending on how you save your files. It has to do with orienation to the front, back, left and right panels. No worry- if you load up your sky ingame and the top panel isn't aligned, you can just rename the vmt's to fake rotating the side panels until you get them aligned with the top panel.
  13. Now, take each of the side panels and, if you're using photoshop CS2 (not sure about other versions, but I'd assume all the newer ones have this), select ONLY the 1024x1024 area the panel is in and go to edit>transform>warp (I think it was). You want the arc-shaped warp. For the "bend" option on the top toolbar, enter in the value -27 or so. Just be sure to have it be between -25 and -30. Trial and error, really. This is one way of getting around the distortion that seems to naturally occur due to how the skies are applied. Remember, you're trying to make a cube (which the sky textures are applied to) appear spherical!
  14. Reduce canvas size to 1024x1024 and save each panel, naming it as needed. Make your vmt, and try it out ingame!

Note: It seems I forgot to point out some things. Quoting a post on page 2:

I believe you're using the "arch" feature instead of "arc" (or did I get them mixed up? you want the [warp tool] that maintains the side borders)

I also forgot to say to copy the layer you want to warp and place it below the layer you are warping, otherwise you get that transparent region ontop of the warped tile, plus it might break the top-side panel seam. You might need to do a little bit of repainting to make the warped layer and the layer below that look natural, so be prepared! Just remember, don't paint the very edges of any tile, otherwise you risk breaking the seamless nature of the sky.

Sorry for any wonky grammar and word choices (just woke up!)

With any luck, that methodology will give you seamless, not-so-boxy skies :D

Using the procedure above, I've managed to fashion myself a skybox (which is still in alpha- still has a very ugly portion that's going to be redone): [ame="http://www.youtube.com/watch?v=13OyoY-Mi7g"]YouTube - Team Fortress 2 Sandstorm Effect Alpha[/ame]

Hope this helps :)
 
Last edited:

Beamos

L2: Junior Member
May 14, 2008
80
43
Terr: Hahaha, that's why the music was chosen! :p
 

Beamos

L2: Junior Member
May 14, 2008
80
43
I believe you're using the "arch" feature instead of "arc" (or did I get them mixed up? you want the one that maintains the side borders)

I also forgot to say to copy the layer you want to warp and place it below the layer you are warping, otherwise you get that transparent region ontop of the warped tile, plus it might break the top-side panel seam. You might need to do a little bit of repainting to make the warped layer and the layer below that look natural, so be prepared! Just remember, don't paint the very edges of any tile, otherwise you risk breaking the seamless nature of the sky.

Sorry for any wonky grammar and word choices (just woke up!)
 

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Thanks, I got the idea now. I did try both Arc and Arch but I was turned away by the transparent bit in both cases :) I'll get to fixing it now.
 

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Well, here's my progress so far, tested on a map I threw together in a few minutes.

The theme is supposed to be post-apocalyptic :)

I still need to work on the warping of the sides and the seaming a little bit (and change the fog color of course), but otherwise I'm satisfied :D
 
Last edited:

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Aaand I made a cordon compile of the actual map to see how it works with it - I'm very satisfied :D [ame="http://forums.tf2maps.net/showthread.php?p=91419#post91419"]ARENA Enclave - TF2Maps.net Forums[/ame]
 

Beamos

L2: Junior Member
May 14, 2008
80
43
Oh my god, that sky is lovely!! Did you paint it?!
 
Last edited:

psihomir

L4: Comfortable Member
Mar 17, 2008
192
32
Nah, I reworked an image I found.

I e-mailed the author asking for permission to use it and I'm still waiting for a reply - and I sure hope he agrees, I've been searching for a few days and this one just fits the map perfectly :D