Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- precision highp float;
- uniform highp sampler2D colorTex_; //16x16 8bit texture with values in [0,3] (lowest two bits). Using linear filtering.
- in vec2 frag_texcoord; //in [0,1] for each dimension, generated from full screen quad vertices
- out vec4 FragData0; // 500x500 output
- void main() {
- vec4 v = vec4(texture2D(colorTex_, frag_texcoord).x, vec2(0.0), 1.0);
- float umax = 255;
- float uthreshold = 1;
- if(v > 1.0/255) {
- FragData0 = vec4(1.0, 1.0, 1.0, 1.0);
- } else {
- FragData0 = vec4(0.0, 0.0, 0.0, 1.0);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement