Skip to content

Instantly share code, notes, and snippets.

@baobao
Created May 8, 2016 14:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save baobao/72614d0fc001638587ec709cfd82d1d6 to your computer and use it in GitHub Desktop.
Save baobao/72614d0fc001638587ec709cfd82d1d6 to your computer and use it in GitHub Desktop.
https://gist.github.com/baobao/5c21deb63e7866eed75f415057b6a25d がGLSLに書き出されるとこうなる
Shader "Simple"
{
SubShader
{
Pass
{
GpuProgramID 16286
Program "vp"
{
SubProgram "gles "
{
"#version 100
#ifdef VERTEX
attribute vec4 _glesVertex;
uniform highp mat4 glstate_matrix_mvp;
void main ()
{
gl_Position = (glstate_matrix_mvp * _glesVertex);
}
#endif
#ifdef FRAGMENT
void main ()
{
gl_FragData[0] = vec4(1.0, 1.0, 1.0, 1.0);
}
#endif
"
}
}
Program "fp"
{
SubProgram "gles "
{
"// shader disassembly not supported on gles"
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment