{"name":"troika-three-utils","version":"0.29.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":"839fc0fc5095dcd8dedabee8b3de57521f657a85","bugs":{"url":"https://github.com/protectwise/troika/issues"},"homepage":"https://github.com/protectwise/troika#readme","_id":"troika-three-utils@0.29.0","_nodeVersion":"10.16.0","_npmVersion":"lerna/3.22.1/node@v10.16.0+x64 (darwin)","dist":{"integrity":"sha512-zsw46ibPmikoRnJK8d18MiOboNgdUnBxGrQdWssIDBSGzgkHRgpdT+MOuTEi9923a30gg4oM0YNMZHdc9X9B3A==","shasum":"15a2961cbec20ff3e4784d4f21ac4044a8c421d9","tarball":"http://registry-npm.ywwl.com/troika-three-utils/download/troika-three-utils-0.29.0.tgz","fileCount":17,"unpackedSize":125598,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfA6ZMCRA9TVsSAnZWagAACBsP/0jZrYd3PDpcvHlJUG9S\nzF5lbGjpljjjTNMJ5fq5i014PELrQXcb3GflBkMBOi5npB7UkecN9H8XgJOd\nLh71RlX/xFMCFdb82XaPalep5+nekQRV0pVNUe2oDKaygqsMMeF51JbZHc2B\ng1wZzt4rBhnaVdA6oM01pTz0GuYhcf0QnDTT9F8/n6DMJgAbhBWkmoi7paFw\nAtRzZ0OsNNqQKN9zmUGPiBJi/m0eRuimJBgriAxqRf6CvQMCAmU+VQEbRzZC\ns2eh4j5U6cP6MjXBZfHfh8R6LwIggYMzgu7ULXnDzpiUaIvz65A2marAtt3n\nfmnmGWrmCytv/sBhFJFBqV42sKJOlEVbPuFFpyrzIwkfOtajTrBW1xG3/MXL\ngOw09vXehcUjs6RcK0zLDwth5EPkNLR4H+lqCOKe49/nMXhNa+7zPSUUdHyY\n3e9cmEOPsBH3R9955pPKSl6GpDhTo7Fv9DuQf8tE8EtrfgOavZxWzFuMsr8p\nQW59eehG/NEBJJ1MdcN/bsVucrTdfbhRBiJrbGm/03HFKl2SsRaWROswlWAV\nZEE6+MjOTaRsKxW8wY6zyrmSmfOvJn8oo+RcstUsZLWo9EtRiYR9e0Huilx3\nLTYDCY1Xl9q4kWyUU5/G/hNLAWzIyQOeA9hBsQmD6hFxCQLETel3ntqwJDl5\nxhEx\r\n=N4i6\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDYJIDhebV3ZQqC2aMddQ5ISr3XT94BINMZds6NVUsiGAiBS6e36LsmIVodAffc6MkMDXrAkKTsVvPKPHxrc3RcgOQ=="}],"size":35192,"noattachment":false,"key":"/troika-three-utils/-/troika-three-utils-0.29.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.29.0_1594074700420_0.5302286549682866"},"_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":1594074700549,"_cnpm_publish_time":1594074700549,"dist-tags":{"latest":"0.53.1"}}