View Full Version : Sine/Cosine wave for sunrise and sunset
05-18-2012, 10:13 AM
I'm working with opengl to create a sunrise and sunset based on the actual times. I'm having trouble coming up with a sin/cos formula that goes from -1 to 1 to -1 for any given sunrise and sunset time with sunrise and sunset obviously equaling -1 and high noon equaling 1.
05-18-2012, 01:14 PM
Your apparent sunrise/sunset depends on your altitude and the altitudes of what's on the horizon (not to mention what's in between you and there).
And then you need an astromony model to determine where the sun is relative to the earth on a specific date at a specific time.
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.