Last active
August 29, 2015 13:59
-
-
Save Ciechan/10596329 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// fragment shader | |
precision lowp float; | |
struct FSInput { | |
vec2 _texcoord; | |
sampler2D _texture; | |
float _opacity; | |
}; | |
struct FSOutput {vec4 _color1;}; | |
uniform FSInput _fIn1; | |
varying vec4 TEX0; | |
void main(){ | |
vec4 _color; | |
_color = texture2D(_fIn1._texture, TEX0.xy); | |
_color.w = _color.w*_fIn1._opacity; | |
gl_FragColor = _color; | |
} | |
// vertex shader | |
precision mediump float; | |
struct VSInput { | |
vec4 _position1; | |
vec4 _projection[4]; | |
float _linewidth; | |
float _powerlevel1; | |
float _timeoffset; | |
float _displaywidth1; | |
}; | |
struct VSOutput {vec4 _position;vec2 _texcoord;}; | |
VSOutput _ret_0; | |
float _TMP1; | |
float _TMP0; | |
float _TMP7; | |
float _TMP6; | |
float _TMP5; | |
float _TMP4; | |
float _TMP3; | |
float _TMP2; | |
uniform VSInput _vIn1; | |
float _fraction0017; | |
float _fadeCurve0017; | |
float _spaceWarp0017; | |
float _mainCurve0017; | |
float _a0019; | |
float _x0021; | |
float _s0022; | |
float _c0022; | |
float _a0028; | |
float _fadeCurve0032; | |
float _spaceWarp0032; | |
float _mainCurve0032; | |
float _a0034; | |
float _x0036; | |
float _s0037; | |
float _c0037; | |
float _a0043; | |
vec2 _v0047; | |
vec4 _r0053; | |
float _val0055; | |
attribute vec4 POSITION; | |
varying vec4 TEX0; | |
void main(){ | |
VSOutput _vOut; | |
vec4 _p0; | |
vec4 _p1; | |
vec2 _delta; | |
vec2 _ortho; | |
_fraction0017 = POSITION.x - POSITION.y; | |
_a0019 = _fraction0017*6.28318548E+00; | |
_TMP2 = cos(_a0019); | |
_fadeCurve0017 = -_TMP2*5.00000000E-01 + 5.00000000E-01; | |
_x0021 = 6.99999988E-01*_fraction0017*3.14159274E+00 + 2.04203510E+00; | |
_s0022 = sin(_x0021); | |
_c0022 = cos(_x0021); | |
_TMP3 = _s0022/_c0022; | |
_spaceWarp0017 = 1.00000000E+01*_TMP3; | |
_a0028 = 3.24999988E-01*_spaceWarp0017 + _vIn1._timeoffset; | |
_TMP4 = sin(_a0028); | |
_TMP5 = _fadeCurve0017/(-4.61538434E-01*(1.00000000E+00 - _fadeCurve0017) + 1.00000000E+00); | |
_mainCurve0017 = _TMP4*_TMP5; | |
_p0 = vec4(_fraction0017*_vIn1._displaywidth1, _mainCurve0017*_vIn1._powerlevel1, 0.00000000E+00, 1.00000000E+00); | |
_a0034 = POSITION.x*6.28318548E+00; | |
_TMP2 = cos(_a0034); | |
_fadeCurve0032 = -_TMP2*5.00000000E-01 + 5.00000000E-01; | |
_x0036 = 6.99999988E-01*POSITION.x*3.14159274E+00 + 2.04203510E+00; | |
_s0037 = sin(_x0036); | |
_c0037 = cos(_x0036); | |
_TMP3 = _s0037/_c0037; | |
_spaceWarp0032 = 1.00000000E+01*_TMP3; | |
_a0043 = 3.24999988E-01*_spaceWarp0032 + _vIn1._timeoffset; | |
_TMP4 = sin(_a0043); | |
_TMP5 = _fadeCurve0032/(-4.61538434E-01*(1.00000000E+00 - _fadeCurve0032) + 1.00000000E+00); | |
_mainCurve0032 = _TMP4*_TMP5; | |
_p1 = vec4(POSITION.x*_vIn1._displaywidth1, _mainCurve0032*_vIn1._powerlevel1, 0.00000000E+00, 1.00000000E+00); | |
_v0047 = _p1.xy - _p0.xy; | |
_TMP6 = dot(_v0047, _v0047); | |
_TMP7 = inversesqrt(_TMP6); | |
_delta = _TMP7*_v0047; | |
_ortho = vec2(-_delta.y, _delta.x)*POSITION.z; | |
_p1.xy = _p1.xy + _vIn1._linewidth*_ortho; | |
_r0053 = _p1.x*_vIn1._projection[0]; | |
_r0053 = _r0053 + _p1.y*_vIn1._projection[1]; | |
_r0053 = _r0053 + _p1.z*_vIn1._projection[2]; | |
_r0053 = _r0053 + _p1.w*_vIn1._projection[3]; | |
_val0055 = float((_ortho.y > 0.00000000E+00)); | |
_TMP0 = _val0055 - float((_ortho.y < 0.00000000E+00)); | |
_TMP1 = max(0.00000000E+00, _TMP0); | |
_vOut._texcoord = vec2(0.00000000E+00, _TMP1); | |
_ret_0._position = _r0053; | |
_ret_0._texcoord = _vOut._texcoord; | |
gl_Position = _r0053; | |
TEX0.xy = _vOut._texcoord; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment