spheremap sky

Blitz3D Forums/Blitz3D Programming/spheremap sky

Rook Zimbabwe(Posted 2004) [#1]
I want to create a spheremap starfield for my game background. Can anyone point me to a few good examples?
-RZ


REDi(Posted 2004) [#2]
I would suggest using a cube in stead of a sphere, sphere suffers from the texture bunching up at the poles.

To create a skybox (or sphere) do something like this...
CameraID = CreateCamera()
SkyBoxID = CreateCube(CameraID)
FlipMesh SkyBoxID
EntityOrder SkyBoxID,1000
EntityFX SkyBoxID,1

And then just apply your texture to it.


slenkar(Posted 2004) [#3]
thats only the start of the nightmare, how do you get 6 tiling textures??????


REDi(Posted 2004) [#4]
Slenkar, you can only use one texture with the above example, and there are loads of amazing NASA images that would be excellent for use with this type of project, just edit them with PSP to make seamless.


slenkar(Posted 2004) [#5]
"just edit them with PSP to make seamless"

we're not all that rich, can it be done in GIMP?


Bot Builder(Posted 2004) [#6]
Filters>map>make seamless

:P


slenkar(Posted 2004) [#7]
If you texture a cube with such a texture it will still show seams, "make seamless" only works for flat surfaces or spheres.


REDi(Posted 2004) [#8]
I don't know about GIMP but it works fine in PSP, if you want to send it to me I'll see what I can do. Or you could just download the trial version of PSP here!

I can't see why you think the shape of a mesh makes any difference to the texture thats applied to it.


slenkar(Posted 2004) [#9]
"http://point.worldtel.net.pk/wallpaper/telescope/Hubble%20Eagle%20Nebula%20wide%20field%2004086y.jpg"

Okay here is a 1024x1024 nebula picture, see if you can texture that to a cube seamlessly.


REDi(Posted 2004) [#10]

:P

You didn't specify a size, so here it is at 1024x1024.
personally I would have used a much smaller part of the image and it would have ended up being 256x256.


REDi(Posted 2004) [#11]
Hmmm just tested it and I see what you mean now, the top and bottom quads of the cube aren't matching. I look into this later, I know I've done it before.


REDi(Posted 2004) [#12]

Bit of a cheat but it works ;)

I've also played around with the top and bottom of the image so it looks okay on a sphere aswell.


Rook Zimbabwe(Posted 2004) [#13]
Whoa... Fan-freaking-tastic!!!! : )
-RZ


slenkar(Posted 2004) [#14]
so, what did you do?


Rook Zimbabwe(Posted 2004) [#15]
I went with spheremap since you never see the top or bottom but I use different starfields for each level. Looks mondo mucho cool!!!


slenkar(Posted 2004) [#16]
nah I mean how did he get the image like that.


Akat(Posted 2004) [#17]
3DMax can do it very easily, use the cubemap camera in material mapping, it will generate you 6 bitmap.


Rook Zimbabwe(Posted 2004) [#18]
link to look at 3dmax???
-RZ


slenkar(Posted 2004) [#19]
I dont have 3 grand though