UNPKG

@needle-tools/engine

Version:

Needle Engine is a web-based runtime for 3D apps. It runs on your machine for development with great integrations into editors like Unity or Blender - and can be deployed onto any device! It is flexible, extensible and networking and XR are built-in.

31 lines (28 loc) 1.29 kB
/** * Ambient module declaration for `needle-bindings`. * * `SceneData` is keyed by GLB friendly name, then by the node hierarchy: * ctx.sceneData.Minimal.Camera.$object // → THREE.Camera * ctx.sceneData.Minimal.Camera.$components.OrbitControls.autoRotate = true; * ctx.sceneData.Minimal.UI.Button.$components.Button * * Each node entry has: * $object — the Three.js Object3D (typed precisely, e.g. Mesh, Camera, Light) * $components — Needle components attached to this node * [childName] — child nodes, recursively typed * * When the `needle:dts-generator` Vite plugin is active it writes * `.needle/generated/needle-bindings.gen.d.ts` next to the installed package, * which augments this interface with the actual bindings extracted from * the project's GLB files at build time. */ // Pull in the project-local generated augmentation (written by needle:dts-generator). /// <reference path="../../.needle/generated/needle-bindings.gen.d.ts" /> declare module "needle-bindings" { /** * Scene data keyed by GLB friendly name, then by node hierarchy. * Fallback index signature allows unknown names without crashing. */ // eslint-disable-next-line @typescript-eslint/no-empty-interface interface SceneData {} }