@mobecher/rollup-plugin-glslang

reads a directory of shaders, compiles them and outputs to another directory

Usage no npm install needed!

<script type="module">
  import mobecherRollupPluginGlslang from 'https://cdn.skypack.dev/@mobecher/rollup-plugin-glslang';
</script>

README

rollup-plugin-glslang

Rollup plugin that uses @webgpu/glslang to compile shaders from glsl to SPIR-V

This project was forked from @javascribble/rollup-plugin-glslang to fix module imports

import { glslang } from '@javascribble/rollup-plugin-glslang';

export default {
  ...options,
  plugins: [
    glslang({
      source: './',
      target: './'
    })
  ]
}