{"_id":"glsl-token-defines","_rev":"21-276f1da4e5ab8ca4fb98f35e146b342a","name":"glsl-token-defines","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"glsl-token-defines","version":"1.0.0","keywords":["ecosystem:stackgl"],"author":{"url":"http://hughsk.io/","name":"Hugh Kennedy","email":"hughskennedy@gmail.com"},"license":"MIT","_id":"glsl-token-defines@1.0.0","maintainers":[{"name":"hughsk","email":"hughskennedy@gmail.com"}],"homepage":"https://github.com/stackgl/glsl-token-defines","bugs":{"url":"https://github.com/stackgl/glsl-token-defines/issues"},"dist":{"shasum":"cb892aa959936231728470d4f74032489697fa9d","tarball":"https://registry.npmjs.org/glsl-token-defines/-/glsl-token-defines-1.0.0.tgz","integrity":"sha512-Vb5QMVeLjmOwvvOJuPNg3vnRlffscq2/qvIuTpMzuO/7s5kT+63iL6Dfo2FYLWbzuiycWpbC0/KV0biqFwHxaQ==","signatures":[{"sig":"MEUCIQDvziyE2nZ+gCJt+ZLRes4xfJSAZ5Unfi8v9xCKhmW7kwIgL3ELsZNGsvzBiSYzFEgq7XX7GR6iWruzstXVWAV0NTc=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"index.js","_from":".","_shasum":"cb892aa959936231728470d4f74032489697fa9d","gitHead":"5505aa03ff9ae9fe3ada1b2dcb31f1eefb94da23","scripts":{"test":"node test | tap-spec"},"_npmUser":{"name":"hughsk","email":"hughskennedy@gmail.com"},"repository":{"url":"git://github.com/stackgl/glsl-token-defines.git","type":"git"},"_npmVersion":"2.5.0","description":"Retrieve the values defined with preprocessor statements in a selection of GLSL tokens","directories":{},"_nodeVersion":"0.10.36","dependencies":{"glsl-tokenizer":"^2.0.0"},"devDependencies":{"tape":"^3.5.0","tap-spec":"^2.2.1"}}},"time":{"created":"2015-03-11T02:11:02.884Z","modified":"2024-12-29T00:47:14.931Z","1.0.0":"2015-03-11T02:11:02.884Z"},"bugs":{"url":"https://github.com/stackgl/glsl-token-defines/issues"},"author":{"url":"http://hughsk.io/","name":"Hugh Kennedy","email":"hughskennedy@gmail.com"},"license":"MIT","homepage":"https://github.com/stackgl/glsl-token-defines","keywords":["ecosystem:stackgl"],"repository":{"url":"git://github.com/stackgl/glsl-token-defines.git","type":"git"},"description":"Retrieve the values defined with preprocessor statements in a selection of GLSL tokens","maintainers":[{"email":"hughskennedy@gmail.com","name":"hughsk"},{"email":"mikolalysenko@gmail.com","name":"mikolalysenko"},{"email":"dave.des@gmail.com","name":"mattdesl"},{"email":"chris@neversaw.us","name":"chrisdickinson"},{"email":"javascript@yosh.is","name":"yoshuawuyts"},{"email":"me@mikkoh.com","name":"mikkoh"},{"email":"tatum.creative@gmail.com","name":"tatumcreative"},{"email":"wwwtyro@gmail.com","name":"wwwtyro"},{"email":"thibaut.seguy@gmail.com","name":"thibauts"},{"email":"post.ben.here@gmail.com","name":"bpostlethwaite"},{"email":"df.creative@gmail.com","name":"dfcreative"},{"email":"arnebackeric@gmail.com","name":"erkaman"},{"email":"renaudeau.gaetan@gmail.com","name":"gre"},{"email":"rsreusser@gmail.com","name":"rreusser"},{"email":"marcin.ignac@gmail.com","name":"vorg"},{"email":"arch.mojtaba.samimi@gmail.com","name":"archmoj"}],"readme":"# glsl-token-defines\n\n[![experimental](http://badges.github.io/stability-badges/dist/experimental.svg)](http://github.com/badges/stability-badges)\n\nRetrieve the values defined with preprocessor statements in a selection of\n[GLSL tokens](http://github.com/stackgl/glsl-tokenizer).\n\nDoesn't handle full function-style macros for the time being. Patches welcome!\n\n## Usage\n\n[![NPM](https://nodei.co/npm/glsl-token-defines.png)](https://nodei.co/npm/glsl-token-defines/)\n\n### `defs = defines(tokens)`\n\nWhere `tokens` is an array of tokens produced by\n[glsl-tokenizer](http://github.com/stackgl/glsl-tokenizer).\n\nReturns an dictionary object where keys are the name of the defined variable,\nand values are the values of the defined variable. If a variable is not\nassigned a value, this will be an empty string.\n\nFor example, the following:\n\n``` glsl\n#define PI 3.14\n#define TAU (PI*2.)\n#define VEC vec3(1.)\n#define EMPTY\n```\n\nWould yield:\n\n``` javascript\n{\n  PI: '3.14',\n  TAU: '(PI*2.)',\n  VEC: 'vec3(1.)',\n  EMPTY: ''\n}\n```\n\n## Contributing\n\nSee [stackgl/contributing](https://github.com/stackgl/contributing) for details.\n\n## License\n\nMIT. See [LICENSE.md](http://github.com/stackgl/glsl-token-defines/blob/master/LICENSE.md) for details.\n","readmeFilename":"README.md"}