ST_SunPosition
Signature
Description
Compute the sun position, according a point
location, and return a new 2D point which coordinate is defined as:
-
x = sun azimuth
direction along the horizon, in radians, measured from north to east, -
y = sun altitude
above the horizon, in radians, e.g. 0 at the horizon and PI/2 at the zenith.
By default, the current time sun position is returned. Optionally, the user can specify another date using the time
parameter.
The point
coordinates have to be exprimed in the WGS84 projection system (lat / long
)
Examples
At the current time:
Or using the time
parameter (e.g for May 26th 2010 at 15h35’26s) :
Use case
A specific use case, using ST_SunPosition
and ST_GeometryShadow
is avalaible HERE.