{"name":"troika-three-utils","version":"0.25.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","gitHead":"a2a487e422ad6d62fd4a4d5a7c4d95111ed3afdb","bugs":{"url":"https://github.com/protectwise/troika/issues"},"homepage":"https://github.com/protectwise/troika#readme","_id":"troika-three-utils@0.25.0","_nodeVersion":"12.16.1","_npmVersion":"lerna/3.20.2/node@v12.16.1+x64 (darwin)","dist":{"integrity":"sha512-z99ObywNICIYuKhh2Oknt4N18fPSfkh9zkuaUWVwTmpT8HEMsP8oKFdpoDsvcbe7xACVuaItgTGE69yGfAjeTA==","shasum":"a477d13b8905507e3859a3d35416ff92817a79e6","tarball":"http://registry-npm.ywwl.com/troika-three-utils/download/troika-three-utils-0.25.0.tgz","fileCount":17,"unpackedSize":122497,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJexFgdCRA9TVsSAnZWagAATH8P/3xrTE4jHmsg98oIe1rK\nrIA/FcAf7i5/pTD8IlB8pcsk45IkQ0GJ2+izjzdTFF8YWmw3br2oz0mjtFH3\n1FDRNKoCzeLuXnnyooizsM/jquChstQOV6KgftXi2mMPOc5bfwQFznyZZYuI\nziyyxGLJXcvy8w490q7md/43xwu2CZgGOqEaXpZYoVoClnGHuZhfGKyUofaX\na80bCLn9ZAGaIOIPQcEjEDYFAcrmJ2vzRhoassZsD98M2VT773wAEgqHAPQi\nmEDnCy0t5Ppfbg2luer8feqiqd0cMfS9HH6i23d0UhUEF7UVQU4g0jfgn8va\nKlY5QCEPzuVvk8QJI2kES2NgVSj9ykbmzzLb9C7cL2aIazNX9Vf2NH0F9aTh\nElrT4vAEg7D9EE8CiIvWsXSqSR8mJK2ysEH1c5ORReR86cPvMiEKCUQFP2Gu\nZ+00EHFgNoeM4+AtQyD2d4gTpPs4rVzjRn+BJxfjH45p7S3Ul94xvs3oGtSe\nM3PaJ4EACjaqZC0U92bOcbgqYUbAWqyD2PGzL5oIlip3HlfTXslY8lSr1P0+\nz6MMLtHVMHhX3DeB/S3bMJ2MP2aE2cYd6qQNL4XhYoVNyyr1h97InKPdbtqj\njijPl50EA/4i38L7uhrMonQ32dE5nTcHZleSX452dkl376fvzqPZyZoTWU2o\nMQ1V\r\n=0CcR\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBKeWYjjCwAvksE1iBzXN60RCAs10bckPL7uc6IwX4PgAiEA9KRYCOhyc1rOyC3+SI1+kc7DbpN1dOYcFLRrFowBYEc="}],"size":33332,"noattachment":false,"key":"/troika-three-utils/-/troika-three-utils-0.25.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.25.0_1589925916859_0.815597818301022"},"_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":1589925916969,"_cnpm_publish_time":1589925916969,"dist-tags":{"latest":"0.53.1"}}