Pastebin launched a little side project called HostCabi.net, check it out ;-)Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on Nov 13th, 2012  |  syntax: None  |  size: 0.47 KB  |  hits: 24  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. <script type="x-shader/x-vertex" id="vshPic">
  2. uniform vec4 uRect;
  3. uniform mat4 uOrtho;
  4. attribute vec2 aPoint;
  5. varying vec2 vTexCoord;
  6. void main(void)
  7. {
  8.         gl_Position = uOrtho * vec4(uRect.xy + uRect.zw * aPoint.xy, 0.0, 1.0);
  9.         vTexCoord = aPoint;
  10. }
  11. </script>
  12. <script type="x-shader/x-fragment" id="fshPic">
  13. precision mediump float;
  14. uniform sampler2D tTexture;
  15. varying vec2 vTexCoord;
  16. void main(void)
  17. {
  18.         gl_FragColor = texture2D(tTexture, vTexCoord);
  19. }
  20. </script>