No.135 · Backgrounds· New
Ember Globe
A slowly turning sphere drawn in thousands of twinkling points: an ember-coloured upper half from a hot cap down to scattered sparks, a cool white lower half, and a near-empty equator between them. A background only, with no text.
The prompt
Written for the variant you picked above: Ember
Build a full-bleed black background with a point-cloud sphere in the middle (WebGL1, one gl.POINTS draw, no libraries), plus an optional slot for content on top. Points: 12,000 on a unit sphere shell with ±3.5% radial jitter, alternating hemispheres, with latitude y = ±(1 − u^1.7) so they crowd toward both poles and thin out around the equator; each has a random seed. Generate them once, deterministically. Vertex shader: rotate round the vertical axis at 0.12 rad/s, tip the globe 0.32 rad toward the viewer (so the top cap reads as a bright arc) plus a pointer tilt, apply a light perspective (1 / (1 + 0.18 z)) and scale to 34% of the smaller side. Colour by the point's own latitude: in the upper half mix spark (near the equator) → ember (from y 0.05 to 0.4, jittered per point so sparks mix in) → hot (from 0.62 to 0.96); the lower half is the cool colour. Alpha = a per-point twinkle (0.55 ± 0.45, its own rate) × a latitude fade (30% at the equator to 100% by |y| 0.55) × a back-face dim (55% behind), 60% for the cool half, and the hottest cap eased down by a third so it stays coloured instead of blowing out to white. Point size 2.3 × DPR × (0.55–1.45 by seed) × perspective, scaled with the globe. Fragment shader: a soft round sprite (smoothstep on the squared distance) with additive blending, so dense caps bloom on their own. Motion: rAF, paused offscreen and in hidden tabs; reduced motion draws one frame; a fine pointer eases the tilt (up to ±0.35 and ±0.25 rad). Without WebGL, layered radial gradients from the same palette stand in. Props: palette [hot, ember, spark, cool], count, radius, speed, motion, children. Selected variant — Ember (ember): Hot #ffae8a, ember #ff7428, spark #f0bd3a, cool #e6e9ee: a peach-hot cap fading to orange and amber sparks over a white lower half. This selection takes precedence over references to other themes or options in the general brief. Implement this selected appearance; do not add a variant picker or alternative appearances unless requested. Implementation requirements: Use React and TypeScript. Keep the component self-contained, with uniquely scoped CSS and no animation libraries. Include required imports, styles and font setup in the result. Interaction: A fine pointer tips the globe toward it; nothing to click. Motion: Rotation 0.12 rad/s; each point twinkles at its own 1.2–3.8 rad/s; pointer tilt eases at 5% per frame. Accessibility: Decorative and aria-hidden. Reduced motion renders one still frame. Any text placed on top should sit clear of the bright caps. Responsive behavior: Fills its container; the globe is sized from the smaller side so it stays round and whole on phones. DPR capped at 2. Touch: No pointer tilt on touch; the globe keeps turning. Preserve keyboard access, visible focus and reduced-motion behavior. Keep fictional demo data and simulated service calls in a separate usage example; expose callbacks for real actions and recover from rejected requests. Keep usage-example links inside the demo: use local buttons or prevent navigation. Demonstration links must not navigate to Vitrine routes or open other pages; preserve real URL support in the reusable component itself. Verify the result at narrow and wide viewport sizes, with keyboard input and reduced motion enabled.
Notes
- Interaction
- A fine pointer tips the globe toward it; nothing to click.
- Motion
- Rotation 0.12 rad/s; each point twinkles at its own 1.2–3.8 rad/s; pointer tilt eases at 5% per frame.
- Accessibility
- Decorative and aria-hidden. Reduced motion renders one still frame. Any text placed on top should sit clear of the bright caps.
- Responsive
- Fills its container; the globe is sized from the smaller side so it stays round and whole on phones. DPR capped at 2.
- On touch
- No pointer tilt on touch; the globe keeps turning.