# Astrolabe — `astrolabe-align@1.0.0`

A polished brass astrolabe: the open-work rete turning over its engraved plate while the sighting rule sweeps from star to star. Loops perfectly.

An astrolabe, the medieval computer of the heavens, seen face-on: the mater engraved with its degree scale and the hours in Roman numerals, the plate with its circles of altitude, the open-work rete turning over it with its ring of the zodiac and pointers to the stars, and the alidade, the sighting rule, sweeping across as if lining up each star in turn. Choose the metal, how many stars the rete points to, the turns per loop, the seed, the backdrop and whether the camera sways.

- Kind: object; status: published; digest sha256:798685405c505af7d7f01c860e58faa37e3d7d54bef840361ab4a9ae08422864
- Role: Object (3D, three.js): a scholarly hero object for astronomy, navigation, history and time content.
- Implementation: three; entry `src/astrolabe-align.js`
- Files: https://aipixelwizard.com/registry/astrolabe-align/1.0.0/<path> (`LICENSE`, `asset.json`, `demo.js`, `index.html`, `src/astrolabe-align.js`)
- Manifest JSON: https://aipixelwizard.com/api/v1/visuals/astrolabe-align/versions/1.0.0
- Runnable demo: https://aipixelwizard.com/registry/astrolabe-align/1.0.0/index.html (open over http; it imports sibling packages by relative path)
- Dependencies (exact): `three@0.185.1` (source) — Renderer, geometry and physical materials.; `chrome-material@1.1.0` (demo) — Studio environment light and backdrop.; `apw-runtime@1.0.0` (demo) — Demo harness.

## Exports
- `createAstrolabe({ metal?, stars?, turns?, seed? }) => { group, setProgress(progress), dispose() }` — The instrument as a group of meshes (radius 3, face towards +z); add it with an environment map and a light.
- `METALS: { brass, gold, silver, bronze }` — Metal finishes: colour (sRGB) and roughness.

## Parameters
- `metal` (select one of brass | gold | silver | bronze, default "brass") — Metal
- `stars` (integer 4–20, default 12) — Stars: Pointers on the rete.
- `turns` (integer 1–3, default 1) — Turns per loop
- `seed` (integer 1–999, default 3) — Seed
- `background` (color, default "#13233a") — Backdrop
- `orbit` (boolean, default true) — Camera sway

## Composition
- Inputs: Time within the loop; the metal, stars, turns, seed, backdrop and camera sway.
- Outputs: A full frame rendered in 3D with a studio environment.
- Coordinates: The astrolabe is centred on the origin in the xy plane with radius 3, face towards +z; its throne rises to y ≈ 3.9.
- Lighting: A warm key light with a shadow map and the studio environment.
- Timing: setProgress(progress) sets the rete and alidade angles; frames render in any order.
- Works with: chrome-material, orbit-camera, kinetic-title, number-reveal
- The degree scale, hour numerals and altitude circles are engraved once on a canvas texture; the rete is extruded 2D shapes (ring, cross-piece, leaf pointers and star discs).

## Output and loop
- 1080×1080, 30 fps, 16 s, procedural
- Seamless loop: yes — The rete turns a whole number of times per loop, the alidade swings in sines of whole cycles and the camera sway is a sine of the loop, so the last frame meets the first.
- Verified 2026-10-06 in Chrome 154.0.8037.97 headless on Linux 7.0.0-38-generic (x64), Node 22.14.0 (WebGL 2 via SwiftShader (software)); deterministic: yes; loop check: Frame 0 vs end state (progress 1): mean |Δ| 0.0000, max |Δ| 0 of 255.

## Use it
New project: Create a WebGLRenderer with a studio environment (see chrome-material), add createAstrolabe().group and call astrolabe.setProgress(progress) each frame.

Existing project: Copy src/astrolabe-align.js; add astrolabe.group to your scene with an environment map.

Reuse ideas:
- Astronomy title: Brass, twelve stars.
- Night-sky scene: Silver, night blue.
- Luxury craft loop: Gold, many stars.

## Limitations
- The plate's circles are a stylised projection, not an exact stereographic chart for a latitude.
- The rete's pointers do not point at real stars.

## License
MIT. Copyright (c) 2026 AI Pixel Wizard. Released under the MIT License. See LICENSE in this folder.

Provenance: Adapted from the owner's threejs-sketches/objects-scenes/astrolabe-align (MIT) and rebuilt for AI Pixel Wizard in October 2026 as an original object: an engraved mater and plate, an extruded open-work rete with seeded star pointers, a sweeping alidade and whole-turn motion for an exact loop.

