Giter Club home page Giter Club logo

shdrr's Introduction

SHDRR: Live shader compiler

Crates.io Build Status

SHDRR is a live shader compiler, as in, it will automatically detect if a file changed within a directory and recompile it to SPIR-V using shaderc.

Right now, it detect the shader type (compute, vertex, fragment) using the file extension:

  • *.cs -> compute
  • *.fs -> fragment
  • *.vs -> vertex

Usage

See shdrr --help for usage:

SHDRR: Live compiler for SPIRV based on shaderc. 

USAGE:
    shdrr [FLAGS] [OPTIONS]

FLAGS:
    -h, --help       
            Prints help information

    -r               
            Look for shader file recursively

    -V, --version    
            Prints version information

    -v               
            Verbose output


OPTIONS:
    -d <dir>                 
            Directory with the shaders

    -e <env>                 
            This option let you choose the target environnement for Shaderc, 
                        
                        Accepted value are: 
                        vulkan, opengl, opengl_compat [default: vulkan]
    -O <optimization>        
            The optimization level follow the ones used by shaderc: 
                            1 or nothing is performance optimization, 
                            0 is no optimization for debugging, 
                            s is optimization for size. [default: 1]
    -o <output>              
            Output directory

    -s <spirv>               
            This option let you choose the SPIR-V version to be used for the compiled shader,
                        
                        Accepted value are: 1.0, 1.1, 1.2, 1.3, 1.4 [default: 1.0]

Exemple: To compile every shader contained in the directory ./shaders/src and its sub-directory to .shaders/bin, with verbosity:

shdrr -rv -d shaders/src -o shaders/bin

Installation

With cargo:

cargo install shdrr

shdrr's People

Contributors

maeln avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.