Publisher | Hessburg |
---|---|
File size | 363.36kB |
Number of files | 22 |
Latest version | 1.3.1 |
Latest release date | 2019-08-06 07:08:10 |
First release date | 2016-07-11 08:43:23 |
Supported Unity versions | 2018.4.2 or higher |
SunLight calculates the light color and orientation of a directional light source based on geographical location and time of day to create a realistic sun light source.
Works with Unity’s dynamic skybox introduced in Unity 5. Simple to use ; just drag it into your scene and let SunLight handle the directional light.
SunLight can be useful for augmented reality too. You could use it to match lighting of 3D objects to the angle of the real world sun for outdoor AR scenes.
Or you could use it for architectural applications and urban planning purposes. As a quick meaningful tool in Unity, when accuracy does not have to meet scientific standards. For example by using it for shadow simulations.
SunLight creates two directional lights, one to illuminate the scene and another one is used to trigger Unity’s Skybox only (layer mask set to nothing). This is necessary to avoid unwanted directional illumination from below the horizon in twilight conditions.
Manual / Script Reference
Usage:
Drag the prefab into the scene and set location and time in inspector.
– Chose a location from 10 presets or manually set latitude and longitude.
– Choose whether to let SunLight handle the progress of time or control it in your script.
– If you wish you can manually override the azimuth (horizontal rotation) of the sun via inspector or in your own script.
Users tested SunLight successfully with VR.
New in 1.1: Added the option to set a custom north direction.
New in 1.2: – Unity 5.5. and above: Uses the new RenderSettings.sun to set the sun in light settings. – Dropped refraction from calculation when sun is close to horizon to avoid a visual issue (which occurred for one frame only)
Works with Unity's built-in procedural skybox, making it rock solid and 100% compatible. Works perfectly on mobile.
Works with Unity’s dynamic skybox introduced in Unity 5. Simple to use ; just drag it into your scene and let SunLight handle the directional light.
SunLight can be useful for augmented reality too. You could use it to match lighting of 3D objects to the angle of the real world sun for outdoor AR scenes.
Or you could use it for architectural applications and urban planning purposes. As a quick meaningful tool in Unity, when accuracy does not have to meet scientific standards. For example by using it for shadow simulations.
SunLight creates two directional lights, one to illuminate the scene and another one is used to trigger Unity’s Skybox only (layer mask set to nothing). This is necessary to avoid unwanted directional illumination from below the horizon in twilight conditions.
Manual / Script Reference
Usage:
Drag the prefab into the scene and set location and time in inspector.
– Chose a location from 10 presets or manually set latitude and longitude.
– Choose whether to let SunLight handle the progress of time or control it in your script.
– If you wish you can manually override the azimuth (horizontal rotation) of the sun via inspector or in your own script.
Users tested SunLight successfully with VR.
New in 1.1: Added the option to set a custom north direction.
New in 1.2: – Unity 5.5. and above: Uses the new RenderSettings.sun to set the sun in light settings. – Dropped refraction from calculation when sun is close to horizon to avoid a visual issue (which occurred for one frame only)
Works with Unity's built-in procedural skybox, making it rock solid and 100% compatible. Works perfectly on mobile.