Skills for Real Engineers. Straight from my .agents directory.
threejs-textures
Agent skill fromCloudAI-X/threejs-skills
Three.js textures: image loading, color spaces, UV channels and transforms, texture types from canvas to HDR and KTX2, render targets, texture memory. Use when working with images on materials, UV coordinates, cubemaps, render targets or texture optimization; on WebGL or with WebGPU and TSL.
How to install threejs-textures
npx skills add CloudAI-X/threejs-skills# or add only this skill to Claude Code: copy the folder
skills/threejs-textures/
# into
~/.claude/skills/threejs-textures/ (all projects)
.claude/skills/threejs-textures/ (one project)
1# Three.js Textures23Targets three.js r186. Examples use WebGLRenderer; the WebGPU and TSL section uses WebGPURenderer.45## Quick Start67```javascript8import * as THREE from "three";910const renderer = new THREE.WebGLRenderer({ antialias: true });11renderer.setPixelRatio(window.devicePixelRatio);12renderer.setSize(window.innerWidth, window.innerHeight);13document.body.appendChild(renderer.domElement);1415const scene = new THREE.Scene();16const camera = new THREE.PerspectiveCamera(60, window.innerWidth / window.innerHeight, 0.1, 100);17camera.position.set(0, 0, 2);1819// Color images must be tagged sRGB or they render too bright and washed out20const texture = new THREE.TextureLoader().load("diffuse.jpg");21texture.colorSpace = THREE.SRGBColorSpace;2223const mesh = new THREE.Mesh(24 new THREE.PlaneGeometry(2, 2),25 new THREE.MeshBasicMaterial({ map: texture }),26);27scene.add(mesh);2829renderer.setAnimationLoop(animate);3031function animate() {32 mesh.rotation.z += 0.01;33 renderer.render(scene, camera);34}35```3637## Loading3839```javascript40// load() returns the texture at once; its image arrives asynchronously41const texture = new THREE.TextureLoader().load("diffuse.jpg");42texture.colorSpace = THREE.SRGBColorSpace;43mesh.material.map = texture; // before the first render; afterwards also set mesh.material.needsUpdate = true4445// When the next step needs the loaded image, await it46const colorMap = await new THREE.TextureLoader().loadAsync("diffuse.jpg");47colorMap.colorSpace = THREE.SRGBColorSpace;48```49…
Excerpt shown under the repository's MIT license.
More skills in threejs-skills
Similar skill repositories
Public repository for Agent Skills
An AI skill that provides design intelligence for building professional UI/UX across multiple platforms.
Persistent Context Across Sessions for Every Agent – Captures everything your agent does during sessions, compresses it with AI, and injects relevant context back into future sessions. Works with Claude Code, OpenClaw, Codex, Gemini, Hermes, Copilot, OpenCode + More
Production-grade engineering skills for AI coding agents.
Agent skills that give coding agents taste: art direction, reference images and a browser check instead of generic AI pages
