Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

3d-object

БесплатноБез исполняемых скриптовНе проверен

A product or object in 3D — built from shapes, extruded from a logo, or loaded from your own .glb — lit like a studio shot, turning on a turntable, ready to…

feimacodeот feimacode★ 1 227 звёзд на GitHub

Об этом скилле

3D Object

Intent. One object, shown well: a product, a logo or a simple form, lit like a studio photo, on a quiet stage, turning slowly. The page is a single self-contained three.js scene. People use it as a hero visual, export a still or a transparent cut-out for slides and pages, or a turntable clip for social.

This is not a 3D editor, a game scene or text-to-3D generation. If the user wants a model of something that doesn't exist yet and can't be built from simple shapes, say so and offer a procedural stand-in.

1. Pick the object path

  • Procedural: build the object from three.js geometry: LatheGeometry for anything turned (bottles, speakers, cups, lamps), ExtrudeGeometry for flat shapes with depth, boxes and cylinders with bevels (RoundedBoxGeometry from the addons) for devices. Combine a few parts in a Group. Aim for the silhouette and proportions first; small details (a groove, a light ring, a seam) make it read as a product.
  • Extruded logo: parse the brand's SVG with SVGLoader, turn each filled path into shapes (SVGLoader.createShapes), and extrude with a bevel. Flip y (SVG's y points down), center the geometry, and scale it to a fixed size. Strokes aren't extruded; ask for a filled version of the mark if that's all there is.
  • The user's model (.glb / .gltf): load it with GLTFLoader. Copy the file under assets/ next to the design (with a shell copy: it's binary) and load assets/<name>.glb; if you can't copy it, use its path relative to the design. Set up DRACOLoader with the pinned decoder path (below) so Draco-compressed models work. Never assume the model's units, origin or orientation: measure its bounding box, rest it on the ground, center it, and frame the camera from its size (the GLB example's stage() does exactly this). If the file is over 50 MB, tell the user it will load slowly and suggest npx @gltf-transform/cli optimize in.glb out.glb --compress draco first.

2. Build the scene

Use exactly these pinned URLs, through an import map:

<script type="importmap">
{ "imports": {
  "three": "https://cdn.jsdelivr.net/npm/[email protected]/build/three.module.js",
  "three/addons/": "https://cdn.jsdelivr.net/npm/[email protected]/examples/jsm/"
} }
</script>

Draco decoder path: https://cdn.jsdelivr.net/npm/[email protected]/examples/jsm/libs/draco/gltf/.

Don't write three.js script tags from memory: build/three.min.js no longer exists (removed in r160), nor does examples/js/… (removed in r148), so <script src=".../three.min.js"> 404s, THREE is undefined and the page shows nothing. Use the import map above and import * as THREE from 'three' in a <script type="module">, with addons from three/addons/….

  • Canvas: one full-bleed <canvas id="stage" data-od-webgl> passed to WebGLRenderer({ canvas, antialias: true, preserveDrawingBuffer: true }). Size it from the canvas's CSS box on load and on resize. On tall, narrow canvases (aspect below 1), frame the object again so it fills the portrait frame as it fills the desktop one: widen the fov and move the camera back only as far as the object needs (the fitView snippet in the 3d-scene skill does this from the object's bounding sphere). The check measures how much of each frame the object fills.
  • Color: outputColorSpace = SRGBColorSpace, toneMapping = ACESFilmicToneMapping.
  • Materials: physically based (MeshStandardMaterial / MeshPhysicalMaterial), with colors read from the design system's tokens (getComputedStyle(document.documentElement).getPropertyValue('--accent')) so the object matches the page: the body from --surface or --fg, one detail from --accent. Choose roughness and metalness for the real material (matte plastic 0.6–0.9 rough, brushed metal metalness 1 at 0.25–0.4 rough, glossy paint with clearcoat). Keep a user model's own materials unless asked to recolor it.
  • Light: the studio setup by default: studio light from a generated room (scene.environment = new PMREMGenerator(renderer).fromScene(new RoomEnvironment(), 0.04).texture, envMapIntensity about 0.6), a shadow-casting key DirectionalLight #fff4e6 at intensity 3 from 45° to the side and 40° up (soft shadows: PCFSoftShadowMap, shadow.radius about 6), a fill #e6eeff at 0.9 from the other side and a rim at 2 from behind, exposure 1.0. When the brief sets a scene (daylight, a lamp, a fire, dusk), use that setup from the 3d-scene skill's light table instead; a light you can see is the key and points at the object. The object is the brightest thing in the frame that isn't a light. When real reflections matter (glass, chrome, glossy paint) or the brief names a setting's light (a sunset, a studio, a forest), find an HDRI with find_feima_design_3d_assets (type: "hdri", free CC0 files from Poly Haven) and light from it: new RGBELoader().loadAsync(url) from three/addons/loaders/RGBELoader.js, then `scene.environment = pmrem.fromEquirectangular(tex).texture
Полный SKILL.md на GitHub

Установить 3d-object в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

.od-local-overlay

FAQ

Что делает скилл 3d-object?

A product or object in 3D — built from shapes, extruded from a logo, or loaded from your own .glb — lit like a studio shot, turning on a turntable, ready to export as a still, a transparent cut-out or a turntable video.

Как установить скилл 3d-object?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл 3d-object запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить 3d-object с