Skip to content

Commit

Permalink
Some doc and workflow fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
eduardodoria committed Jun 2, 2021
1 parent 4d01394 commit b63bf5b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
ninja --version
cmake --version
- name: Update glslang sources (SPIRV-Cross)
- name: Update glslang sources (SPIRV-Tools)
working-directory: libs/glslang
run: |
python update_glslang_sources.py
Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
## Supershader: Cross-compiler for shader language

**Supershader** is a command line tool that converts GLSL code to other GLSL versions, HLSL and MSL.

It is used in [Supernova](https://github.com/supernovaengine/supernova) engine as shader creation tool.


### Build

1. Download glslang external libs (SPIRV-Cross)
1. Download glslang external libs (SPIRV-Tools)

```bash
cd libs/glslang/
Expand All @@ -21,6 +23,7 @@ cmake --build $BUILD_DIR --config Release
# "Release" (for --config) could also be "Debug", "MinSizeRel", or "RelWithDebInfo"
```


### Usage
```bash
./supershader --vert=shader.vert --frag=shader.frag ---defines "USE_UV=1; HAS_TEXTURE" --lang glsl330 --output shaderoutput --json
Expand Down Expand Up @@ -65,6 +68,7 @@ With ```--json``` argument we have reflection info in json and bare shader outpu
```
* Output: ```shaderoutput_glsl.json```, ```shaderoutput_vs.glsl```, ```shaderoutput_fs.glsl```


### SBS file format
> Inspired by **septag** file format: [sgs-file.h](https://github.com/septag/glslcc/blob/master/src/sgs-file.h)
Expand All @@ -85,6 +89,7 @@ Each block header is 8 bytes ( uint32_t fourcc code + uint32_t for size).
- sokol-shdc (https://github.com/floooh/sokol-tools/blob/master/docs/sokol-shdc.md)
- glslcc (https://github.com/septag/glslcc)


### External libraries
- glslang (https://github.com/KhronosGroup/glslang)
- SPIRV-Cross (https://github.com/KhronosGroup/SPIRV-Cross)
Expand Down

0 comments on commit b63bf5b

Please sign in to comment.