Skip to content

plyr4/glsl-shaders

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

glsl-shaders

A playground for creating cool glsl shaders.

Running the shaders

Shadertoy

Use Shadertoy to run fragment shaders found in frag/ in the browser.

  • Shadertoy uses the void mainImage() driver function that is (hopefully) provided in the .frag file.
  • Shadertoy defines its own void main() to run the shader so the provided function needs to be removed before it will work.
  • Shadertoy provides various uniform variables as standard input, so the .frag files in this repo contain #if macro workarounds to make it easier for them to work in both Shadetoy and glslViewer.
  1. Find a fragment shader in frag/.
  2. Visit Shadertoy.
  3. Copy/paste the fragment shader code.
  4. Remove main() entirely.

glslViewer

Use glslViewer to run fragment and vertex shaders locally. They should run out of the box if installed properly.

$ glslViewer frag/default.frag

Be sure to check the wiki if that command isn't working.

About

shaders

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published