tsgl

Light TypeScript wrapper around WebGL based on https://github.com/evanw/lightgl.js/

Usage no npm install needed!

<script type="module">
  import tsgl from 'https://cdn.skypack.dev/tsgl';
</script>

README

Travis npm David

tsgl

Light TypeScript wrapper around WebGL based on https://github.com/evanw/lightgl.js/

Installation

NPM: npm install tsgl --save

In the browser, you can include the UMD bundle in a script tag, and the module will be available under the global tsgl

Demos

camera src Move camera using mouse.
gpuLightMap src Draw soft shadows by calculating a light map in multiple passes.
immediateMode src OpenGL-style immediate mode.
mag src Calculate and render magnetic field lines.
multiTexture src Blend two textures while rendering them to a quad.
rayTracing src Realtime GPU ray tracing including reflection.
renderToTexture src Render mesh to texture, then render that texture to another mesh.
setupDemo src Draw a rotating cube.
shadowMap src Draw shadow of a mesh using a shadow map.
<!--- DEMO-TABLE-END --->

License

MIT