allSkyProjectfunction
Where a point of the sky lands in the picture.
Import it
import { allSkyProject } from "@johnmorrisdotca/hoshi-stars/all-sky";
Definition
function allSkyProject(point: SkyPoint, options: AllSkyOptions): AllSkyPoint
Parameters
| Name | Type | Description |
|---|---|---|
point | SkyPoint | The sky position in degrees (J2000): right ascension and declination. |
options | AllSkyOptions | The picture: its |
Returns
AllSkyPoint
The point in the picture, x from the left and y from the top, inside the box 0..width by 0..width / 2.
Examples
import { allSkyProject } from "@johnmorrisdotca/hoshi-stars/all-sky";
// The Galaxy's centre (Sagittarius A*) is the middle of a galactic picture 1000 wide
console.log(allSkyProject({ rightAscension: 266.4168, declination: -29.0078 }, { width: 1000 })); // about { x: 500, y: 250 }{ x: 500.15487994211435, y: 250.15809089059522 }What it prints (run when this page was built)