Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/huasofoundries/systemjs-glsl-plugin
Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules
https://github.com/huasofoundries/systemjs-glsl-plugin
glsl javascript-modules loader-plugin opengl-shading-language
Last synced: 11 days ago
JSON representation
Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules
- Host: GitHub
- URL: https://github.com/huasofoundries/systemjs-glsl-plugin
- Owner: HuasoFoundries
- License: mit
- Created: 2016-08-01T12:10:38.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2021-04-29T20:31:28.000Z (over 3 years ago)
- Last Synced: 2024-12-05T20:48:06.530Z (28 days ago)
- Topics: glsl, javascript-modules, loader-plugin, opengl-shading-language
- Language: Makefile
- Size: 4.88 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# systemjs-glsl-plugin
Loader plugin to treat (and build) OpenGL Shading Language (*.glsl) files as javascript modules. Made for `[email protected]`
This plugin is, for now, a POC to load *.glsl files (such as the ones found on the [THREE.js source](https://github.com/mrdoob/three.js) ) and let SystemJS treat them as javascript ES6 modules.
I made this loader to import some specific THREE.js submodules into one of my projects, then building a static build with [jspm-cli](https://github.com/jspm/jspm-cli), and getting [Rollup](https://github.com/rollup/rollup) to perform its three shaking magic on the result.
## Installation
Install it with `jspm` using:
```sh
jspm install glsl=npm:systemjs-glsl-plugin
```## Config
This loader must be enabled in the `meta` section of `jspm.config.js`
```js
meta: {
"*.glsl": {
"defaultExtension": false,
"loader": "glsl"
},{
...
}
}
```