Jump to content
  • Advertisement
Sign in to follow this  
MrDoomMaster

Visible Light Sources (Sun)

This topic is 4820 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

I'm creating a 3D solar system. I'm keeping this very simple. My planets are nothing more than colored spheres created in Truespace and saved as *.X files. I want the Sun to be actually lit up, like a light bulb, and the other planets should receive light from it. I tried placing a point light in the middle (inside) of the sun, yet this caused no light emission at all. Any tips? Thanks :)

Share this post


Link to post
Share on other sites
Advertisement
If all you want is simple lighting, a point light 'inside' the sun should do it..
If you're not getting any light out of it it's probably another problem...

maybe your light is misconfigured?
do you have any normals on the spheres? are you sure they are correct?
do you have lighting enabled?
maybe you're using a bad material?

Share this post


Link to post
Share on other sites
As I stated, the mesh is created in Truespace and normals are automatically saved to the X file.

The sphere is yellow, and when the light is in the middle of the mesh, the mesh looks like a faint yellow circle on the screen rather than a 3D sphere. I think it is trying to be lit up, yet it doesn't appear correctly. It should be a brighter yellow.

Share this post


Link to post
Share on other sites
I find it weird that it shows any yellow at all..
Your mesh normals are pointing outwards the sphere, so if you create a light inside the sphere it won't be affect the sun.

So if I were you, I'd create a material for the sun with a yellow value for the Emissive component of that material. For the other meshes however, I'd use the diffuse component of other materials.

Share this post


Link to post
Share on other sites
Here are the screenshots.

This screenshot is when the light is INSIDE of the mesh
http://img.photobucket.com/albums/v356/MrDoomMaster/SS014.jpg


This screenshot is the point light 10 units away from the mesh object
http://img.photobucket.com/albums/v356/MrDoomMaster/SS013.jpg


Also, I have tried enabling material emission, yet this does nothing in my DirectX Application.

Share this post


Link to post
Share on other sites
turn off lighting for the sun - as it is represents the light source it should be 100% bright all the time. What you are seeing as the light trying to illuminate a triangle/vertex pointing away from it, so it gets very little light.

Share this post


Link to post
Share on other sites
Quote:
Original post by MrDoomMaster
This screenshot is when the light is INSIDE of the mesh
http://img.photobucket.com/albums/v356/MrDoomMaster/SS014.jpg
Yes.
Quote:
Original post by MrDoomMaster
This screenshot is the point light 10 units away from the mesh object
http://img.photobucket.com/albums/v356/MrDoomMaster/SS013.jpg
Yes.

Your screenshots look correct. Kamikaze15 explained what is happening and what the solution is.

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!