RetroArch/android/phoenix/assets/Shaders/Mudlord/sharpen-light2.shader
2013-02-05 21:56:29 -05:00

107 lines
2.6 KiB
GLSL

<?xml version="1.0" encoding="UTF-8"?>
<!-- XML/GLSL shader autogenerated by cg2xml.py -->
<shader language="GLSL" style="GLES2">
<vertex><![CDATA[
varying vec4 _color1;
varying float _frame_rotation;
varying float _frame_direction;
varying float _frame_count;
varying vec2 _output_dummy_size;
struct input_dummy {
vec2 _video_size;
vec2 _texture_size;
vec2 _output_dummy_size;
float _frame_count;
float _frame_direction;
float _frame_rotation;
};
struct output_dummy {
vec4 _color1;
};
vec4 _oPosition1;
uniform mat4 rubyMVPMatrix;
vec4 _r0002;
attribute vec4 rubyVertexCoord;
attribute vec4 COLOR;
attribute vec4 rubyTexCoord;
varying vec4 COL0;
varying vec4 TEX0;
mat4 transpose_(mat4 matrix)
{
mat4 ret;
for (int i = 0; i < 4; i++)
for (int j = 0; j < 4; j++)
ret[i][j] = matrix[j][i];
return ret;
}
uniform mediump vec2 rubyOutputSize;
uniform mediump vec2 rubyTextureSize;
uniform mediump vec2 rubyInputSize;
void main()
{
mat4 rubyMVPMatrix_ = transpose_(rubyMVPMatrix);
vec4 _oColor;
vec2 _otexCoord;
_r0002.x = dot(rubyMVPMatrix_[0], rubyVertexCoord);
_r0002.y = dot(rubyMVPMatrix_[1], rubyVertexCoord);
_r0002.z = dot(rubyMVPMatrix_[2], rubyVertexCoord);
_r0002.w = dot(rubyMVPMatrix_[3], rubyVertexCoord);
_oPosition1 = _r0002;
_oColor = COLOR;
_otexCoord = rubyTexCoord.xy;
gl_Position = _r0002;
COL0 = COLOR;
TEX0.xy = rubyTexCoord.xy;
}
]]></vertex>
<fragment><![CDATA[
#ifdef GL_ES
precision mediump float;
#endif
varying vec4 _color;
varying float _frame_rotation;
varying float _frame_direction;
varying float _frame_count;
varying vec2 _output_dummy_size;
struct input_dummy {
vec2 _video_size;
vec2 _texture_size;
vec2 _output_dummy_size;
float _frame_count;
float _frame_direction;
float _frame_rotation;
};
struct output_dummy {
vec4 _color;
};
vec4 _TMP1;
vec4 _TMP0;
uniform sampler2D rubyTexture;
vec2 _c0007;
vec2 _c0009;
varying vec4 TEX0;
uniform mediump vec2 rubyOutputSize;
uniform mediump vec2 rubyTextureSize;
uniform mediump vec2 rubyInputSize;
void main()
{
vec4 _Color;
_Color = texture2D(rubyTexture, TEX0.xy);
_c0007 = TEX0.xy + 9.99999975E-05;
_TMP0 = texture2D(rubyTexture, _c0007);
_Color = _Color - _TMP0*1.50000000E+01;
_c0009 = TEX0.xy - 9.99999975E-05;
_TMP1 = texture2D(rubyTexture, _c0009);
_Color = _Color + _TMP1*1.50000000E+01;
_Color.w = 1.00000000E+00;
gl_FragColor = _Color;
return;
}
]]></fragment>
</shader>