Using Light in a Frame

Using Light in a Frame

Hello a-Frame Users

I'm trying to play with light in a-Frame in order to create a scene that shows the Lunar (Moon) Phases.

Right now my problem is that I can't combine directional light with ambient light in a way that simulates the Sun, Earth and the Moon.

someone know how can I light the scene in the correct way?

1 Answer

Two things are important here

1) make sure that the light actually is set up to cast shadows:

  <a-entity light="castShadow: true"></a-entity>

2) make sure your entities cast and receive shadows:

  <a-entity shadow="cast: true"></a-entity>
  <a-entity shadow="receive: true"></a-entity>

Check it out here.

3

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Alexander Ross
Author

Alexander Ross

Alexander Ross has covered the video game industry for a decade, writing deep dives on game design, esports tournaments, VR developments, and gaming culture.