diff options
Diffstat (limited to 'local_sunrise.py')
-rw-r--r-- | local_sunrise.py | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/local_sunrise.py b/local_sunrise.py index 37cf17d..dbc8555 100644 --- a/local_sunrise.py +++ b/local_sunrise.py @@ -21,18 +21,21 @@ config = { 'ray_samples' : 16, 'light_samples': 8, - 'exposure': 4.0, + 'exposure': 2.0, 'zoom': 1.0, # only for pinhole view 'eye_pos': np.array([0, 0, 1.0001]), 'eye_dir': np.array([0, 1, 0]), # only for pinhole view 'date': (2020, 1, 20), - 'latitude': 49.01, - 'longitude': 8.4 + 'timezone': 1, # GMT+1 + 'summertime': False, + + 'latitude': 49.01356, + 'longitude': 8.40444 } -time_range = (5, 20, 1) +time_range = (6, 20, 0.5) cl_platform = cl.get_platforms()[0] cl_context = cl.Context(properties=[(cl.context_properties.PLATFORM, cl_platform)]) @@ -48,7 +51,7 @@ with open('raymarch.cl') as f: for time in np.arange(*time_range): pit = datetime(*config['date'], int(np.floor(time)), int((time-np.floor(time))*60), 0) - sun_dir = sun_direction(config['latitude'], config['longitude'], pit, 1.0) + sun_dir = sun_direction(config['latitude'], config['longitude'], pit, config['timezone'], 1.0 if config['summertime'] else 0.0) sun = make_double3( np.cos(sun_dir[0])*np.sin(sun_dir[1]), |