Skip to content
All effects

3D scene configurator

A small 3D world where visitors click to place things and drag a slider to move the sun, with the result saved in a shareable link.

Interactive

This is the real effect. Scroll or move your mouse inside the frame to try it.

The prompt

Build a 3D scene configurator with three.js for [the situation I describe]: a small 3D world where visitors place things by clicking, change the conditions with a slider, and keep the result in a shareable link. Scene (example: solar panels on a house): the base scene built from code (simple boxes and extruded shapes), a ground plane, and a set of slots where things can be placed. Empty slots are faint outlines, placed items are solid. Use soft light from the sky and one directional light, with soft shadows. Interaction: clicking a slot (raycaster) adds or removes an item with a small pop animation. A slider changes a condition live, for example the time of day moving the sun along an arc so shadows and light change. A small panel shows the count and a live estimate from one formula in one place. The camera can be orbited a little by dragging, within limits. State: the selection and the slider value are written to the URL (query string or hash) with history.replaceState, and read on load, so a configuration can be shared or sent with a quote request. Keyboard: slots can also be toggled with buttons in the panel. Cap the device pixel ratio at 2 and pause off screen. With prefers-reduced-motion, no pop animations. Style: build it in the existing design system of this website. Reuse its colours, fonts, spacing, corner radius and existing classes or components, and don't add new colours or fonts. Use real content from this website for any text or images in the effect (its headings, services and copy), never placeholder text. If the project has no design system yet, ask me for the brand colours and fonts before you start.

What it is

A small 3D world you can play with. Click to place things, drag a slider to move the sun, and everything you chose is kept in the link.

When it works

When the decision depends on a situation, not just a size. Think of a solar panel site where you put panels on a roof and watch the sun move over it. Because the setup lives in the URL, a visitor can send it with a quote request.

Get it right

  • Build the scene from code. No heavy 3D model files needed for a simple house.
  • Keep every number in one formula, so the estimate is easy to adjust.
  • Save the state in the URL. It turns playing around into a shareable request.

Also called

  • Interactive 3D planner
  • Click-to-place 3D tool
  • Sun position simulator
  • Shareable 3D configuration

More effects.

All effects