{"name":"troika-three-utils","version":"0.32.0","description":"Various utilities related to Three.js","author":{"name":"Jason Johnston","email":"jason.johnston@protectwise.com"},"repository":{"type":"git","url":"git+https://github.com/protectwise/troika.git","directory":"packages/troika-three-utils"},"license":"MIT","main":"dist/troika-three-utils.umd.js","browser":"dist/troika-three-utils.umd.js","jsnext:main":"dist/troika-three-utils.esm.js","module":"dist/troika-three-utils.esm.js","module:src":"src/index.js","peerDependencies":{"three":"0.103.x - 0.119.x"},"gitHead":"9f263fcbf9d5c45dc3c73ede2baf7db26978f2ec","bugs":{"url":"https://github.com/protectwise/troika/issues"},"homepage":"https://github.com/protectwise/troika#readme","_id":"troika-three-utils@0.32.0","_nodeVersion":"12.16.1","_npmVersion":"lerna/3.22.1/node@v12.16.1+x64 (darwin)","dist":{"integrity":"sha512-zkdHAG2ObriDLb+pXc0dGiws1IHORETawUX4QwpK9RaQbLoLMpkzNFj4Qmx1kVRe0Nmh+UasOoMdRmEEUhd39g==","shasum":"d946e94b5a94ad646f2eb7467507273b0ce23df7","tarball":"http://registry-npm.ywwl.com/troika-three-utils/download/troika-three-utils-0.32.0.tgz","fileCount":17,"unpackedSize":127511,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfYYqbCRA9TVsSAnZWagAAOI8P/3wm2teasQn1KEMjbwr7\nM4QFcCUCtyk2q9NExjGiGpNEKMsITdPhpA1Dt/kl2YWwKSyKZXelJtCy9r4j\nNCZ1RiKSux6WrFvQHmMB7zypkd605ogihGAjYKK0u8M/BpezYH58eoa5fKVy\nTEObvwExkRPfqjDli4i7i4xbgYwpnt3/wjouAK1Cix8kyrQLoVNrcHbzkgWh\nakzfyzRkWO1zATSh+xxat2A1mg8/o3iBbYIYg7I+kJmdN+gHhBuCZR3T3VEu\n253/MbA9l7c5sgB7GIA1YV8sLVCsniWLj6QtlcXFYu/Z3YwXHWeTLYq4RfpO\nM4BgCULZc1W65Vif3NbcWUtBDEhQivrDm+kSZYqT+P24lo095gPr9EMPVt0f\ncKKVIgnI6Sul55efFTTC6s/Z0fFiGaqT/IEjR2yD5RJotFbbJxwpNSI6UHg2\nalwig6jttRldhxCJJXlFQaFOhq/aN0555jyKLODpHP60SAhguF4XoJHMYj5o\n3N3RAO61DgbhiedxOcEMqHW1Kq0gWpZpnPaHM4+C6Po1zAQDdsNSZAin4uoG\nW4r2c3vKrYuUMRpgoVUMhJ4+4Ldw/FBobRNpB3I5hWzZlSY38GTZBZ0wMYpq\n6sUiWIvUWevIPWre/H4GgdmKsiD5qhQOInjIgo12C1/jCo3r2dfK7Hx58kdH\nMqvo\r\n=VB5L\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDf6CHAO64ciuC2FHqYHyG8xgnyFqSDpwvCt22g+KGfZAiEAoXTEy979eef7QPvW3jyWGD57JfpldFydnJy0Vy7TeuE="}],"size":35448,"noattachment":false,"key":"/troika-three-utils/-/troika-three-utils-0.32.0.tgz"},"maintainers":[{"name":"lojjic","email":"jason+npm@lojjic.com"}],"_npmUser":{"name":"lojjic","email":"jason+npm@lojjic.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/troika-three-utils_0.32.0_1600227995458_0.25968444337981134"},"_hasShrinkwrap":false,"readme":"# Troika Three.js Utilities\n\nThis package provides various utilities for working with [Three.js](https://github.com/mrdoob/three.js), particularly having to do with shaders. It is used by [Troika 3D](../troika-3d), but has no dependencies itself other than Three.js, so it can be used outside the Troika framework.\n\n\n## Installation\n\nGet it from [NPM](https://www.npmjs.com/package/troika-three-utils):\n\n```sh\nnpm install troika-three-utils\n```\n\nYou will also need to install a compatible version of [Three.js](https://threejs.org); see the [notes on Three.js versions in the Getting Started docs](../../docs/getting-started/setup.md#threejs) for details.\n\n```sh\nnpm install three\n```\n\n\n## Provided Utilities\n\nSeveral utilities are provided; for a full list follow the imports in [index.js](./src/index.js) to their source files, where each is documented in JSDoc comments.\n\nSome of the most useful ones are:\n\n\n### createDerivedMaterial()\n\nThis utility allows you to easily _extend_ existing Three.js materials with your own custom shader code. This is an incredibly powerful tool, and is the  secret behind most of Troika's shader-driven tools like `troika-three-text`, `three-instanced-uniforms-mesh`, and `BezierMesh`. \n\nSee the [createDerivedMaterial documentation page](./docs/createDerivedMaterial.md) and its [source code with JSDoc](./src/DerivedMaterial.js) for details.\n\n\n### BezierMesh\n\nThis creates a cylindrical mesh and bends it along a 3D cubic bezier path between two points, in a custom derived vertex shader. This is useful for visually connecting objects in 3D space with a line that has thickness to it.\n\nSee the [BezierMesh documentation page](./docs/BezierMesh.md) and its [source code with JSDoc](./src/BezierMesh.js) for details.\n\n\n### InstancedUniformsMesh\n\n> NOTE: InstancedUniformsMesh has been moved to [its own `three-instanced-uniforms-mesh` package](https://github.com/protectwise/troika/tree/master/packages/three-instanced-uniforms-mesh).\n","publish_time":1600227995598,"_cnpm_publish_time":1600227995598,"dist-tags":{"latest":"0.53.1"}}