Jump to content
  • Advertisement
Sign in to follow this  
johnnyBravo

Creating a sky sphere?

This topic is 4527 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi I've currently got a skybox for me space game, but I want to implement a sky sphere. I'm not sure where to start though. First is it possible to use D3DXCreateSphere to create the mesh? Like i've been able to create a sphere with the triangles facing outwards, but how would I make them face inward for a sky? And also how would I map texture coordinates to the mesh? As in the dx docs it says the D3DXCreateSphere only uses the fvf D3DFVF_XYZ | D3DFVF_NORMAL. Also if there are any tutorials, as I am having a hard time finding any. Thanks

Share this post


Link to post
Share on other sites
Advertisement
You can use the sphere created by D3DXCreateMesh. If you clone the mesh you can indicate new FVF flags (D3DXCloneMesh if I'm correct); ommit the flag for normals. You can render the mesh with reversed culling (D3DRS_CULLMODE) and it will appear folded inside out. Be sure to turn off lighting. Heck; you don't even have to clone it; with lighting off the normals simply don't bother anyway.

Alternatively you can use a 3D modeling package to produce the sphere (dome).

Illco

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!