mirror of
https://github.com/SamEyeBam/animate.git
synced 2025-12-14 17:58:02 +00:00
larry babby and threejs for glsl
This commit is contained in:
42
webGl/my-threejs-test/node_modules/glslify-bundle/README.md
generated
vendored
Normal file
42
webGl/my-threejs-test/node_modules/glslify-bundle/README.md
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
# glslify-bundle
|
||||
|
||||
[](http://github.com/badges/stability-badges)
|
||||
|
||||
Bundle a [glslify-deps](http://github.com/stackgl/glslify-deps) dependency tree into
|
||||
a GLSL source string.
|
||||
|
||||
This has been separated from *glslify-deps* such that you can prebundle a dependency
|
||||
tree server-side, but then still modify shader file contents in a browser.
|
||||
|
||||
## Usage
|
||||
|
||||
[](https://nodei.co/npm/glslify-bundle/)
|
||||
|
||||
### `source = bundle(deps)`
|
||||
|
||||
Takes the output object from [glslify-deps](http://github.com/stackgl/glslify-deps)
|
||||
and returns a bundled GLSL string.
|
||||
|
||||
``` javascript
|
||||
var bundle = require('glslify-bundle')
|
||||
var deps = require('glslify-deps')
|
||||
var path = require('path')
|
||||
|
||||
var file = path.join(__dirname, 'index.glsl')
|
||||
|
||||
deps().add(file, function(err, tree) {
|
||||
if (err) throw err
|
||||
|
||||
var glsl = bundle(tree)
|
||||
|
||||
console.log(glsl)
|
||||
})
|
||||
```
|
||||
|
||||
## Contributing
|
||||
|
||||
See [stackgl/contributing](https://github.com/stackgl/contributing) for details.
|
||||
|
||||
## License
|
||||
|
||||
MIT. See [LICENSE.md](http://github.com/stackgl/glslify-bundle/blob/master/LICENSE.md) for details.
|
||||
Reference in New Issue
Block a user