Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GLSL ES 300 #4

Open
mattdesl opened this issue Jun 24, 2015 · 0 comments
Open

GLSL ES 300 #4

mattdesl opened this issue Jun 24, 2015 · 0 comments

Comments

@mattdesl
Copy link
Contributor

Changes at a glance:
http://www.shaderific.com/blog/2014/3/13/tutorial-how-to-update-a-shader-for-opengl-es-30

  • #version 300 es appears at top
  • texture2D -> texture
  • attribute -> in
  • gl_FragCoord - custom out
  • varying -> in / out
  • some more constants:
    • gl_VertexID, gl_InstanceID, 'gl_MaxVertexAttribs', 'gl_MaxVertexUniformVectors', 'gl_MaxVertexOutputVectors', 'gl_MaxFragmentInputVectors', 'gl_MaxVertexTextureImageUnits', 'gl_MaxCombinedTextureImageUnits', 'gl_MaxTextureImageUnits', 'gl_MaxFragmentUniformVectors', 'gl_MaxDrawBuffers', 'gl_MinProgramTexelOffset', 'gl_MaxProgramTexelOffset',
  • new functions like textureSize, inversesqrt, transpose, inverse, textureProj
  • new literals like sampler2DArray

Reference:
https://www.khronos.org/registry/gles/specs/3.0/GLSL_ES_Specification_3.00.3.pdf

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant