Sha256: 5ec0f183bcc67f4c36913d5015d59ec6b87c22968d58be26081f090be79154b4
Contents?: true
Size: 442 Bytes
Versions: 13
Compression:
Stored size: 442 Bytes
Contents
#ifdef GL_ES precision mediump float; precision mediump int; #endif #define PROCESSING_TEXTURE_SHADER uniform sampler2D texture; varying vec4 vertColor; varying vec4 vertTexCoord; const vec4 lumcoeff = vec4(0.299, 0.587, 0.114, 0); void main() { vec4 col = texture2D(texture, vertTexCoord.st); float lum = dot(col, lumcoeff); if (0.5 < lum) { gl_FragColor = vertColor; } else { gl_FragColor = vec4(0, 0, 0, 1); } }
Version data entries
13 entries across 13 versions & 2 rubygems