跳过主要内容
全部模板

提示词模板

Spiral Galaxy Particle Observatory — Single-File HTML Canvas Prompt

A detailed one-shot coding prompt for a self-contained HTML page that renders a rotating spiral galaxy of ~42,000 particles with differential rotation, additive glow, nebula dust, an observatory-style HUD and drag/zoom controls. The example video shows an unreleased Flash model's one-shot result. Shared by @MiaAI_lab.

专为 GPT Image 设计视频模板第 2 版

演示视频

查看案例

从示例开始

点一张示例图,整套设置立即套用,再改成你自己的。

  • 查看案例

改成你的

只展示值得改的部分,提示词会实时更新。

Name shown in the HUD.

How many points form the galaxy.

Closing mood line.

你的提示词

Create a single self-contained HTML page that renders a rotating spiral galaxy made of tens of thousands of particles on a full-viewport 2D canvas, presented as a quiet astronomical observatory instrument. The page is pure black (#000000) with a very faint starfield and a dozen distant, softly blurred background galaxies (tilted ellipses drawn as radial gradients) pre-rendered to an offscreen canvas. A radial vignette darkens the corners. The galaxy itself is built from (drop to ~14,000 when prefers-reduced-motion is set). Eighteen percent form a spherical bulge using Gaussian scatter; the remainder are distributed along two logarithmic spiral arms using r = a·e^(bθ) with b ≈ 0.28, an exponential density falloff in radius (mean 0.32 of the disk radius), and angular scatter that widens with radius so arms are crisp near the core and diffuse at the rim. Each particle stores radius, base angle, vertical height (disk thickness ~0.06 scaled by radius), size and brightness. Colors are mapped by radius: warm white/yellow in the core (#FFEBBE to #FFCD82), blue-white along the arms (#CDD7FF to #91C3FF), and faint red-magenta dust at the outer edge (#AA7882 to #D25058). About six percent of arm particles are "hot" oversized blue knots at full brightness. Rotation is differential: angular velocity ω = 0.35 / (0.25 + r), so the inner disk visibly outruns the outer arms and the spiral winds over time. Project the 3D disk to 2D with a yaw rotation about the disk normal followed by a tilt rotation about the screen X axis; depth slightly scales point size. Render with globalCompositeOperation "lighter" for additive glow, drawing every particle as a pre-rendered 32px radial-gradient sprite tinted per quantized color and cached in a Map. Above the disk, a "nebula dust" layer of ~90 large soft radial-gradient ellipses follows the arms (warm peach near the core, cobalt and wine-red farther out) at 6–9% alpha, plus a warm radial core glow. HUD typography: designation line in a tiny uppercase monospace with 0.32em tracking (#6D7787), the galaxy name "" in a large serif (Iowan Old Style / Palatino / Georgia) with the word Meridian italic in amber (#FFD9A0) and a soft amber text-shadow, and an italic serif classification paragraph. The bottom-left stats strip (Particles, Distance in Mly, Diameter in kly, Tilt, Zoom) uses tabular monospace numerals with the first three counting up over ~3.2 seconds with a quartic ease-out. The HUD fades in over 2.4 seconds. Top-right holds a small SVG compass whose needle rotates with the yaw. Right edge has four round glass buttons (zoom in, zoom out, pause, reset) with blur backdrop, scaling to 1.12 on hover and glowing amber at the border. Interactions: pointer drag changes yaw (horizontal) and tilt (vertical, clamped between near face-on and near edge-on); mouse wheel and two-finger pinch zoom between 0.35× and 6× with eased approach; Space toggles rotation; reset returns to the default oblique view. The canvas must handle window resize and devicePixelRatio (capped at 2). Mood: .

点击高亮部分即可直接修改。

适用场景

Use when you want to benchmark a coding model on a dense, spec-heavy creative-coding task or need a polished galaxy visualization page.

怎样效果最好

  • Change the galaxy name, particle count or mood line; keep the numeric spiral and color specs for a faithful result.
  • Ask the model for a single self-contained file and open it directly in a browser to test.

避坑提醒

  • Weaker models drop parts of the spec (HUD count-up, compass, pinch zoom); check each interaction.
  • 42,000 additive sprites can be slow on low-end devices; lower the count if frames stutter.

来源与归属

示例案例作者
Mia

继续浏览