Skip to content

BabylonJS/twgsl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

twgsl

twgsl (from "to WGSL") is a small "adapter" layer exposing the SPIR-V to WGSL transpilation capabilities of Google's Tint library to JavaScript.

Building twgsl

I recommend building from a Linux VM set up explicitly for this purpose.

  1. Set up Emscripten, making sure to add its tools to your path.
  2. Set up Chrome Depot Tools, making sure to add the tools to your path.
  3. Clone twgsl and download the Tint submodule.
    git clone https://github.com/BabylonJS/twgsl.git
    cd twgsl
    git submodule update --init --recursive
    
  4. Set up the Tint repository to build.
    cd Dependencies/Tint
    cp standalone.gclient .gclient
    gclient sync
    
  5. Create a build folder outside the twgsl folder (assumed in this example to be adjacent), then configure cmake using Emscripten's CMake wrapper.
    mkdir twgsl_build
    cd twgsl_build
    emcmake cmake ../twgsl
    
  6. Build the twgsl target using Emscripten's Make wrapper.
    emmake make twgsl
    
    Significant optimizations are turned on, so this build may take a very long time.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published