Skip to content

boxcrittersmods/bc-shaders

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

91 Commits
 
 
 
 
 
 

Repository files navigation

Box Critters Shaders

Based off: [https://github.com/baseten/easelbender]

Steps (for now)

  1. Install https://boxcrittersmods.ga/other/tampermonkey/
  2. Install https://github.com/boxcritters/bc-shaders/raw/master/bc-shaders.user.js

Sample Usage

loadShader({
	shader:
		`#version 300 es
		precision mediump float;

		in vec2 vPixelCoord;
		out vec4 fColor;

		uniform sampler2D uStageTex;
		uniform float uTime;
		uniform vec2 uViewportSize;
		uniform vec2 uMousePos;

		uniform vec2 uCustomUniform;

		void main() {
			fColor = texture(uStageTex, vPixelCoord);
		}`,
	container: world.stage,
	uniforms: function () {
		return { uCustomUniform: [0.0, 0.5] }
	}
})

params

  • shader: GLSL Shader
  • container: createjs stage to apply shader to
  • uniforms: Custom uniforms

Built in uniforms

  • sampler2D uStageTex
  • float uTime
  • vec2 uViewportSize
  • vec2 uMousePos
  • float uRandom

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published