Constructs the SphereHorizon for the given camera.
The camera used as a reference to compute the horizon.
Array with a boolean for each canvas corner telling whether it intersects with the world. Corners are in ccw-order starting with bottom left.
Indicates whether the horizon circle is fully visible.
'True' if horizon is fully visible, false otherwise.
Subdivides and arc of the horizon circle, providing the world coordinates of the divisions.
Function called for every division point, getting the point world coordinates as parameter.
Angular parameter of the arc's start point [0,1].
Angular parameter of the arc's end point [0,1].
Number of division points for the whole horizon. Smaller arcs will be assigned a proportionally smaller number of points.
Gets the world coordinates of a point in the horizon corresponding to the given parameter.
Parameter value in [0,1] corresponding to the point in the horizon circle at angle t(arcEnd - arcStart)2*pi counter clockwise.
Start of the arc covered by parameter t, corresponds to angle arcStart2pi.
End of the arc covered by parameter t, corresponds to angle arcEnd2pi.
Optional target where resulting world coordinates will be set.
the resulting point in world space.
Gets the horizon intersections with the specified canvas side, specified in angular parameters [0,1].
the intersections with the canvas.
Generated using TypeDoc
Class computing horizon tangent points and intersections with canvas for spherical projection.
The horizon for a sphere is a circle formed by all intersections of tangent lines passing through the camera with said sphere. It lies on a plane perpendicular to the sphere normal at the camera and it's center is at the line segment joining the sphere center and the camera.
The further the camera is, the nearer the horizon center gets to the sphere center, only reaching the sphere center when the camera is at infinity. In other words, the horizon observed from a finite distance is always smaller than a great circle (a circle with the sphere radius, dividing the sphere in two hemispheres, and therefore it's radius is smaller than the sphere's.