From 6277600290b0004d8e90528d2d258975620d542b Mon Sep 17 00:00:00 2001 From: weihuoya Date: Sat, 6 Aug 2022 13:48:29 +0800 Subject: [PATCH] fx --- cache/0004000000053700.shader | 18363 +++++++++++++ cache/0004000000053700.shader.meta | 4 + cache/000400000005DE00.shader | 2054 ++ cache/000400000005DE00.shader.meta | 4 + cache/000400000008FE00.shader | 542 + cache/000400000008FE00.shader.meta | 4 + cache/0004000000090700.shader | 21073 +++++++++++++++ cache/0004000000090700.shader.meta | 4 + cache/00040000000B3500.shader | 4582 ++++ cache/00040000000B3500.shader.meta | 4 + cache/00040000000DA000.shader | 2200 ++ cache/00040000000DA000.shader.meta | 4 + cache/00040000000F4F00.shader | 10421 ++++++++ cache/00040000000F4F00.shader.meta | 4 + cache/00040000000F5600.shader | 1995 ++ cache/00040000000F5600.shader.meta | 4 + cache/0004000000127900.shader | 5399 ++++ cache/0004000000127900.shader.meta | 4 + cache/0004000000131E00.shader | 17577 +++++++++++++ cache/0004000000131E00.shader.meta | 4 + cache/0004000000158D00.shader | 2841 +++ cache/0004000000158D00.shader.meta | 4 + cache/000400000018A400.shader | 8951 +++++++ cache/000400000018A400.shader.meta | 4 + cache/00040000001A4800.shader | 17028 +++++++++++++ cache/00040000001A4800.shader.meta | 4 + cache/000400000FAA5C00.shader | 3682 +++ cache/000400000FAA5C00.shader.meta | 4 + cache/0004001000021700.shader | 21256 ++++++++++++++++ cache/0004001000021700.shader.meta | 4 + .../app/src/main/assets/3dstdb-zh_CN.txt | 22 + 31 files changed, 138046 insertions(+) create mode 100644 cache/0004000000053700.shader create mode 100644 cache/0004000000053700.shader.meta create mode 100644 cache/000400000005DE00.shader create mode 100644 cache/000400000005DE00.shader.meta create mode 100644 cache/000400000008FE00.shader create mode 100644 cache/000400000008FE00.shader.meta create mode 100644 cache/0004000000090700.shader create mode 100644 cache/0004000000090700.shader.meta create mode 100644 cache/00040000000B3500.shader create mode 100644 cache/00040000000B3500.shader.meta create mode 100644 cache/00040000000DA000.shader create mode 100644 cache/00040000000DA000.shader.meta create mode 100644 cache/00040000000F4F00.shader create mode 100644 cache/00040000000F4F00.shader.meta create mode 100644 cache/00040000000F5600.shader create mode 100644 cache/00040000000F5600.shader.meta create mode 100644 cache/0004000000127900.shader create mode 100644 cache/0004000000127900.shader.meta create mode 100644 cache/0004000000131E00.shader create mode 100644 cache/0004000000131E00.shader.meta create mode 100644 cache/0004000000158D00.shader create mode 100644 cache/0004000000158D00.shader.meta create mode 100644 cache/000400000018A400.shader create mode 100644 cache/000400000018A400.shader.meta create mode 100644 cache/00040000001A4800.shader create mode 100644 cache/00040000001A4800.shader.meta create mode 100644 cache/000400000FAA5C00.shader create mode 100644 cache/000400000FAA5C00.shader.meta create mode 100644 cache/0004001000021700.shader create mode 100644 cache/0004001000021700.shader.meta diff --git a/cache/0004000000053700.shader b/cache/0004000000053700.shader new file mode 100644 index 00000000000..d4124175a4e --- /dev/null +++ b/cache/0004000000053700.shader @@ -0,0 +1,18363 @@ +// shader: 8DD9, CBBC43C38774091B + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 6D98C2C476DC3F58, CBBC43C38774091B +// shader: 8B31, 77C3EE176B2D5FFB + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.xy = (vs_in_reg0.xyyy).xy; + vs_out_attr0.z = (-uniforms.f[5].wwww).z; + vs_out_attr0.w = (uniforms.f[95].wwww).w; + vs_out_attr1 = uniforms.f[6].wzyx; + return true; +} +// reference: E07DBC51294BAAD9, 77C3EE176B2D5FFB +// shader: 8B30, 7974F3663498993D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF912097B5D, 7974F3663498993D +// program: 77C3EE176B2D5FFB, CBBC43C38774091B, 7974F3663498993D +// shader: 8DD9, 6B49BF5FD5349480 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E0A3E62E72D05152, 6B49BF5FD5349480 +// shader: 8B31, 821B2E6F196E4B62 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.xy = (vs_in_reg0.xyyy).xy; + vs_out_attr0.z = (uniforms.f[95].wwww).z; + vs_out_attr0.w = (uniforms.f[95].zzzz).w; + reg_tmp0 = vs_in_reg0.zwzw; + vs_out_attr1 = reg_tmp0.xyxy; + return true; +} +// reference: DABAE56B18D2F6D1, 821B2E6F196E4B62 +// shader: 8B30, 34BED21BE5F81B21 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) + (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((combiner_buffer.rgb) - (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((combiner_buffer.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (const_color[5].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6B173230E9DBC7E8, 34BED21BE5F81B21 +// program: 821B2E6F196E4B62, 6B49BF5FD5349480, 34BED21BE5F81B21 +// shader: 8B30, 30B703594147E54C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9BAB13DC4, 30B703594147E54C +// program: 821B2E6F196E4B62, 6B49BF5FD5349480, 30B703594147E54C +// shader: 8B30, 8D084CC0A7D7F1B9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9E9B49EAD, 8D084CC0A7D7F1B9 +// program: 821B2E6F196E4B62, 6B49BF5FD5349480, 8D084CC0A7D7F1B9 +// shader: 8DD9, 075A5034223F1416 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 91BCC71FEF9EA286, 075A5034223F1416 +// shader: 8B31, 75C7F5FD26A5FF54 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.xy = (vs_in_reg0.xyyy).xy; + vs_out_attr0.z = (uniforms.f[95].wwww).z; + vs_out_attr0.w = (uniforms.f[95].zzzz).w; + vs_out_attr1 = mul_s(uniforms.f[5].wzyx, vs_in_reg0.zwzw); + vs_out_attr2 = vs_in_reg0.zwzw; + return true; +} +// reference: 8972D72140453EB9, 75C7F5FD26A5FF54 +// shader: 8B30, B9F0B9C1491F2BA4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF986CEC0A6, B9F0B9C1491F2BA4 +// program: 75C7F5FD26A5FF54, 075A5034223F1416, B9F0B9C1491F2BA4 +// shader: 8DD9, 23B87C5B1F79AE3C + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +in vec4 vs_out_attr7[]; +in vec4 vs_out_attr8[]; +in vec4 vs_out_attr9[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + conditional_code = equal(uniforms.f[80].wz, vs_out_attr6[0].xy); + reg_tmp4.xy = (vs_out_attr0[0].xyyy).xy; + reg_tmp5.xy = (vs_out_attr0[0].zyyy).xy; + reg_tmp6.xy = (vs_out_attr0[0].xwww).xy; + reg_tmp7.xy = (vs_out_attr0[0].zwww).xy; + reg_tmp4.zw = (uniforms.f[80].wzwz).zw; + reg_tmp5.zw = (uniforms.f[80].wzwz).zw; + reg_tmp6.zw = (uniforms.f[80].wzwz).zw; + reg_tmp7.zw = (uniforms.f[80].wzwz).zw; + if (!conditional_code.y) { + sub_1(); + } else { + sub_4(); + } + return true; +} +bool sub_1() { + reg_tmp0.x = dot_s(reg_tmp4, vs_out_attr7[0]); + reg_tmp1.x = dot_s(reg_tmp5, vs_out_attr7[0]); + reg_tmp2.x = dot_s(reg_tmp6, vs_out_attr7[0]); + reg_tmp3.x = dot_s(reg_tmp7, vs_out_attr7[0]); + reg_tmp0.y = dot_s(reg_tmp4, vs_out_attr8[0]); + reg_tmp1.y = dot_s(reg_tmp5, vs_out_attr8[0]); + reg_tmp2.y = dot_s(reg_tmp6, vs_out_attr8[0]); + reg_tmp3.y = dot_s(reg_tmp7, vs_out_attr8[0]); + reg_tmp4.xy = (mul_s(reg_tmp0.xyyy, vs_out_attr9[0].xyyy)).xy; + reg_tmp5.xy = (mul_s(reg_tmp1.xyyy, vs_out_attr9[0].xyyy)).xy; + reg_tmp6.xy = (mul_s(reg_tmp2.xyyy, vs_out_attr9[0].xyyy)).xy; + reg_tmp7.xy = (mul_s(reg_tmp3.xyyy, vs_out_attr9[0].xyyy)).xy; + reg_tmp4.y = (reg_tmp4.yyyy + vs_out_attr6[0].wwww).y; + reg_tmp5.y = (reg_tmp5.yyyy + vs_out_attr6[0].wwww).y; + reg_tmp6.y = (reg_tmp6.yyyy + vs_out_attr6[0].wwww).y; + reg_tmp7.y = (reg_tmp7.yyyy + vs_out_attr6[0].wwww).y; + if (!conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + return false; +} +bool sub_2() { + output_buffer.attributes[0].xy = (reg_tmp4.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xyyy).xy; + setemit(0u, false, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp5.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr2[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zyyy).xy; + setemit(1u, false, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp6.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr3[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xwww).xy; + setemit(2u, true, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp7.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr4[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zwww).xy; + setemit(0u, true, true); + emit(); + return false; +} +bool sub_3() { + output_buffer.attributes[0].xy = (reg_tmp5.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr2[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zyyy).xy; + setemit(0u, false, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp4.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xyyy).xy; + setemit(1u, false, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp7.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr4[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zwww).xy; + setemit(2u, true, false); + emit(); + output_buffer.attributes[0].xy = (reg_tmp6.xyyy + vs_out_attr9[0].zwww).xy; + output_buffer.attributes[0].z = (vs_out_attr6[0].zzzz).z; + output_buffer.attributes[0].w = (uniforms.f[80].zzzz).w; + output_buffer.attributes[1] = vs_out_attr3[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xwww).xy; + setemit(0u, true, true); + emit(); + return false; +} +bool sub_4() { + reg_tmp0.x = dot_s(reg_tmp4, vs_out_attr7[0]); + reg_tmp1.x = dot_s(reg_tmp5, vs_out_attr7[0]); + reg_tmp2.x = dot_s(reg_tmp6, vs_out_attr7[0]); + reg_tmp3.x = dot_s(reg_tmp7, vs_out_attr7[0]); + reg_tmp0.y = dot_s(reg_tmp4, vs_out_attr8[0]); + reg_tmp1.y = dot_s(reg_tmp5, vs_out_attr8[0]); + reg_tmp2.y = dot_s(reg_tmp6, vs_out_attr8[0]); + reg_tmp3.y = dot_s(reg_tmp7, vs_out_attr8[0]); + reg_tmp0.z = dot_s(reg_tmp4, -vs_out_attr9[0]); + reg_tmp1.z = dot_s(reg_tmp5, -vs_out_attr9[0]); + reg_tmp2.z = dot_s(reg_tmp6, -vs_out_attr9[0]); + reg_tmp3.z = dot_s(reg_tmp7, -vs_out_attr9[0]); + reg_tmp0.w = dot_s(reg_tmp4, vec4(0.0, 0.0, 0.0, 1.0)); + reg_tmp1.w = dot_s(reg_tmp5, vec4(0.0, 0.0, 0.0, 1.0)); + reg_tmp2.w = dot_s(reg_tmp6, vec4(0.0, 0.0, 0.0, 1.0)); + reg_tmp3.w = dot_s(reg_tmp7, vec4(0.0, 0.0, 0.0, 1.0)); + reg_tmp5.x = (mul_s(uniforms.f[95].wwww, vs_out_attr6[0].zzzz)).x; + reg_tmp4.x = (mul_s(reg_tmp0.zzzz, reg_tmp5.xxxx)).x; + reg_tmp4.y = (mul_s(reg_tmp1.zzzz, reg_tmp5.xxxx)).y; + reg_tmp4.z = (mul_s(reg_tmp2.zzzz, reg_tmp5.xxxx)).z; + reg_tmp4.w = (mul_s(reg_tmp3.zzzz, reg_tmp5.xxxx)).w; + reg_tmp0.z = (reg_tmp0.zzzz + reg_tmp4.xxxx).z; + reg_tmp1.z = (reg_tmp1.zzzz + reg_tmp4.yyyy).z; + reg_tmp2.z = (reg_tmp2.zzzz + reg_tmp4.zzzz).z; + reg_tmp3.z = (reg_tmp3.zzzz + reg_tmp4.wwww).z; + if (!conditional_code.x) { + sub_5(); + } else { + sub_6(); + } + return false; +} +bool sub_5() { + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xyyy).xy; + setemit(0u, false, false); + emit(); + output_buffer.attributes[0] = reg_tmp1; + output_buffer.attributes[1] = vs_out_attr2[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zyyy).xy; + setemit(1u, false, false); + emit(); + output_buffer.attributes[0] = reg_tmp2; + output_buffer.attributes[1] = vs_out_attr3[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xwww).xy; + setemit(2u, true, false); + emit(); + output_buffer.attributes[0] = reg_tmp3; + output_buffer.attributes[1] = vs_out_attr4[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zwww).xy; + setemit(0u, true, true); + emit(); + return false; +} +bool sub_6() { + output_buffer.attributes[0] = reg_tmp1; + output_buffer.attributes[1] = vs_out_attr2[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zyyy).xy; + setemit(0u, false, false); + emit(); + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xyyy).xy; + setemit(1u, false, false); + emit(); + output_buffer.attributes[0] = reg_tmp3; + output_buffer.attributes[1] = vs_out_attr4[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].zwww).xy; + setemit(2u, true, false); + emit(); + output_buffer.attributes[0] = reg_tmp2; + output_buffer.attributes[1] = vs_out_attr3[0]; + output_buffer.attributes[2].xy = (vs_out_attr5[0].xwww).xy; + setemit(0u, true, true); + emit(); + return false; +} +// reference: 04D18B6804C33B81, 23B87C5B1F79AE3C +// shader: 8B31, A226445F0A79E9EE + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; +out vec4 vs_out_attr7; +out vec4 vs_out_attr8; +out vec4 vs_out_attr9; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr7 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr8 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr9 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp7 = uniforms.f[5].wzyx; + conditional_code = equal(uniforms.f[90].wz, reg_tmp7.xy); + vs_out_attr0 = vs_in_reg0; + if (uniforms.b[0]) { + sub_1(); + } else { + sub_4(); + } + reg_tmp0 = mul_s(uniforms.f[7].wzwz, vs_in_reg5); + vs_out_attr5.xz = (reg_tmp0.xzzz).xz; + vs_out_attr5.yw = (uniforms.f[90].zzzz + -reg_tmp0.yyww).yw; + if (uniforms.b[1]) { + sub_7(); + } else { + sub_12(); + } + vs_out_attr6.y = (uniforms.f[95].wwww).y; + vs_out_attr6.z = (uniforms.f[5].yyyy).z; + vs_out_attr7 = uniforms.f[8].wzyx; + vs_out_attr8 = uniforms.f[9].wzyx; + vs_out_attr9 = uniforms.f[12].wzyx; + return true; +} +bool sub_1() { + if (!conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + vs_out_attr6.x = (uniforms.f[95].wwww).x; + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[93].wzyx; + vs_out_attr1 = mul_s(uniforms.f[6].wzyx, reg_tmp0); + vs_out_attr2 = mul_s(uniforms.f[6].wzyx, reg_tmp0); + vs_out_attr3 = mul_s(uniforms.f[6].wzyx, reg_tmp0); + vs_out_attr4 = mul_s(uniforms.f[6].wzyx, reg_tmp0); + return false; +} +bool sub_3() { + vs_out_attr1 = uniforms.f[6].wzyx; + vs_out_attr2 = uniforms.f[6].wzyx; + vs_out_attr3 = uniforms.f[6].wzyx; + vs_out_attr4 = uniforms.f[6].wzyx; + return false; +} +bool sub_4() { + if (!conditional_code.x) { + sub_5(); + } else { + sub_6(); + } + vs_out_attr6.x = (vs_in_reg6.xxxx).x; + return false; +} +bool sub_5() { + vs_out_attr1 = mul_s(uniforms.f[92].wzyx, vs_in_reg1); + vs_out_attr2 = mul_s(uniforms.f[92].wzyx, vs_in_reg2); + vs_out_attr3 = mul_s(uniforms.f[92].wzyx, vs_in_reg3); + vs_out_attr4 = mul_s(uniforms.f[92].wzyx, vs_in_reg4); + return false; +} +bool sub_6() { + vs_out_attr1 = mul_s(uniforms.f[91].wzyx, vs_in_reg1); + vs_out_attr2 = mul_s(uniforms.f[91].wzyx, vs_in_reg2); + vs_out_attr3 = mul_s(uniforms.f[91].wzyx, vs_in_reg3); + vs_out_attr4 = mul_s(uniforms.f[91].wzyx, vs_in_reg4); + return false; +} +bool sub_7() { + reg_tmp4 = uniforms.f[90].wzyx; + conditional_code = equal(uniforms.f[4].wz, reg_tmp4.xy); + if (conditional_code.x) { + sub_8(); + } else { + sub_9(); + } + return false; +} +bool sub_8() { + vs_out_attr6.w = (uniforms.f[95].wwww).w; + return false; +} +bool sub_9() { + if (!conditional_code.y) { + sub_10(); + } else { + sub_11(); + } + return false; +} +bool sub_10() { + vs_out_attr6.w = (-uniforms.f[5].zzzz).w; + return false; +} +bool sub_11() { + vs_out_attr6.w = (uniforms.f[5].zzzz).w; + return false; +} +bool sub_12() { + vs_out_attr6.w = (uniforms.f[95].wwww).w; + return false; +} +// reference: 11B5E2195FBBFB0C, A226445F0A79E9EE +// shader: 8B30, 89F2CFFD36D8272B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0E61E83E09E9E6CA, 89F2CFFD36D8272B +// program: A226445F0A79E9EE, 23B87C5B1F79AE3C, 89F2CFFD36D8272B +// shader: 8DD9, DDD543B7EFD7D3AC + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +in vec4 vs_out_attr7[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_9(); +bool sub_10(); +bool sub_6(); +bool sub_7(); +bool sub_8(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + uint jmp_to = 88u; + while (true) { + switch (jmp_to) { + case 88u: { + conditional_code = lessThan(uniforms.f[82].zz, vs_out_attr3[0].ww); + if (conditional_code.x) { + { jmp_to = 298u; break; } + } + reg_tmp8.x = (vs_out_attr3[0].wwww).x; + reg_tmp9.x = (mul_s(uniforms.f[80].zzzz, reg_tmp8.xxxx)).x; + reg_tmp9.x = (floor(reg_tmp9.xxxx)).x; + reg_tmp9.x = (mul_s(uniforms.f[82].yyyy, reg_tmp9.xxxx)).x; + reg_tmp8.x = (reg_tmp8.xxxx + -reg_tmp9.xxxx).x; + reg_tmp9.y = (mul_s(uniforms.f[81].yyyy, reg_tmp8.xxxx)).y; + reg_tmp9.y = (floor(reg_tmp9.yyyy)).y; + reg_tmp9.y = (mul_s(uniforms.f[81].wwww, reg_tmp9.yyyy)).y; + reg_tmp8.x = (reg_tmp8.xxxx + -reg_tmp9.yyyy).x; + reg_tmp7.x = (reg_tmp8.xxxx).x; + reg_tmp7.y = (uniforms.f[81].zzzz).y; + reg_tmp2.xy = (vs_out_attr2[0].xyyy).xy; + reg_tmp3.xy = (vs_out_attr2[0].zyyy).xy; + reg_tmp4.xy = (vs_out_attr2[0].xwww).xy; + reg_tmp5.xy = (vs_out_attr2[0].zwww).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp7.xy); + if (conditional_code.x) { + sub_1(); + } + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp9.xy); + if (conditional_code.y) { + sub_2(); + } + if (conditional_code.x) { + sub_3(); + } + reg_tmp7.xy = (reg_tmp2.xyyy).xy; + reg_tmp7.z = (reg_tmp3.xxxx).z; + reg_tmp7.w = (reg_tmp3.yyyy).w; + reg_tmp8.xy = (reg_tmp4.xyyy).xy; + reg_tmp8.z = (reg_tmp5.xxxx).z; + reg_tmp8.w = (reg_tmp5.yyyy).w; + reg_tmp6.xy = (reg_tmp15.zwww).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp6.xy); + if (conditional_code.y) { + { jmp_to = 224u; break; } + } + reg_tmp1.xy = (vs_out_attr3[0].xyyy).xy; + reg_tmp1.z = (mul_s(uniforms.f[81].yyyy, vs_out_attr3[0].xxxx)).z; + reg_tmp1.w = (mul_s(uniforms.f[81].yyyy, vs_out_attr3[0].yyyy)).w; + reg_tmp0.x = (vs_out_attr5[0].zzzz).x; + reg_tmp0.y = (vs_out_attr6[0].zzzz).y; + reg_tmp0.z = (vs_out_attr7[0].zzzz).z; + reg_tmp9.x = (mul_s(reg_tmp0.xxxx, vs_out_attr0[0].wwww)).x; + reg_tmp9.y = (mul_s(reg_tmp0.yyyy, vs_out_attr0[0].wwww)).y; + reg_tmp9.z = (mul_s(reg_tmp0.zzzz, vs_out_attr0[0].wwww)).z; + reg_tmp2.x = (vs_out_attr4[0].xxxx).x; + reg_tmp2.y = (vs_out_attr3[0].zzzz).y; + reg_tmp2.y = (reg_tmp2.yyyy + vs_out_attr4[0].zzzz).y; + reg_tmp3.x = rcp_s(uniforms.f[80].x); + reg_tmp3.x = (mul_s(reg_tmp2.yyyy, reg_tmp3.xxxx)).x; + reg_tmp3.x = (floor(reg_tmp3.xxxx)).x; + reg_tmp3.x = (mul_s(uniforms.f[80].xxxx, reg_tmp3.xxxx)).x; + reg_tmp2.y = (reg_tmp2.yyyy + -reg_tmp3.xxxx).y; + reg_tmp2.y = (-uniforms.f[80].yyyy + reg_tmp2.yyyy).y; + reg_tmp3 = uniforms.f[95]; + reg_tmp4 = uniforms.f[94]; + reg_tmp0.z = (mul_s(reg_tmp2.yyyy, reg_tmp2.yyyy)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp3.xyyy, reg_tmp3.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp4.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp4.zwww)).xy; + reg_tmp3 = uniforms.f[93]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp3.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp2.yyyy)).y; + reg_tmp0.xy = (mul_s(-uniforms.f[81].zzzz, reg_tmp0.xyyy)).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp10.zz); + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + reg_tmp10 = reg_tmp0.xyxy; + reg_tmp2 = -reg_tmp3.xwxw; + reg_tmp4 = mul_s(reg_tmp2, reg_tmp10.xxyy); + reg_tmp2.x = (reg_tmp4.zzzz + -reg_tmp4.yyyy).x; + reg_tmp2.y = (reg_tmp4.xxxx + reg_tmp4.wwww).y; + reg_tmp2.zw = (uniforms.f[81].xxxx).zw; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp7.xyyy).xy; + setemit(0u, false, false); + emit(); + reg_tmp2.xz = (reg_tmp3.zzzz).xz; + reg_tmp2.yw = (-reg_tmp3.wwww).yw; + reg_tmp4 = mul_s(reg_tmp2, reg_tmp10.xxyy); + reg_tmp2.x = (reg_tmp4.zzzz + -reg_tmp4.yyyy).x; + reg_tmp2.y = (reg_tmp4.xxxx + reg_tmp4.wwww).y; + reg_tmp2.zw = (uniforms.f[81].xxxx).zw; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp7.zwww).xy; + setemit(1u, false, false); + emit(); + reg_tmp2.xz = (-reg_tmp3.xxxx).xz; + reg_tmp2.yw = (reg_tmp3.yyyy).yw; + reg_tmp4 = mul_s(reg_tmp2, reg_tmp10.xxyy); + reg_tmp2.x = (reg_tmp4.zzzz + -reg_tmp4.yyyy).x; + reg_tmp2.y = (reg_tmp4.xxxx + reg_tmp4.wwww).y; + reg_tmp2.zw = (uniforms.f[81].xxxx).zw; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp8.xyyy).xy; + setemit(2u, true, false); + emit(); + reg_tmp2 = reg_tmp3.zyzy; + reg_tmp4 = mul_s(reg_tmp2, reg_tmp10.xxyy); + reg_tmp2.x = (reg_tmp4.zzzz + -reg_tmp4.yyyy).x; + reg_tmp2.y = (reg_tmp4.xxxx + reg_tmp4.wwww).y; + reg_tmp2.zw = (uniforms.f[81].xxxx).zw; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp8.zwww).xy; + setemit(0u, true, true); + emit(); + return true; + } + case 224u: { + reg_tmp1.xy = (-reg_tmp10.xyyy).xy; + reg_tmp1.z = (reg_tmp15.xxxx + -reg_tmp10.xxxx).z; + reg_tmp1.w = (reg_tmp15.yyyy + -reg_tmp10.yyyy).w; + reg_tmp9.x = (reg_tmp10.wwww).x; + reg_tmp2.y = (reg_tmp15.zzzz).y; + reg_tmp2.y = (reg_tmp2.yyyy + vs_out_attr4[0].zzzz).y; + reg_tmp3.x = rcp_s(uniforms.f[80].x); + reg_tmp3.x = (mul_s(reg_tmp2.yyyy, reg_tmp3.xxxx)).x; + reg_tmp3.x = (floor(reg_tmp3.xxxx)).x; + reg_tmp3.x = (mul_s(uniforms.f[80].xxxx, reg_tmp3.xxxx)).x; + reg_tmp2.y = (reg_tmp2.yyyy + -reg_tmp3.xxxx).y; + reg_tmp2.y = (-uniforms.f[80].yyyy + reg_tmp2.yyyy).y; + reg_tmp3 = uniforms.f[95]; + reg_tmp4 = uniforms.f[94]; + reg_tmp0.z = (mul_s(reg_tmp2.yyyy, reg_tmp2.yyyy)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp3.xyyy, reg_tmp3.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp4.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp4.zwww)).xy; + reg_tmp3 = uniforms.f[93]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp3.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp2.yyyy)).y; + reg_tmp0.xy = (mul_s(-uniforms.f[81].zzzz, reg_tmp0.xyyy)).xy; + reg_tmp10 = reg_tmp0.xyxy; + reg_tmp0 = mul_s(reg_tmp1.xwxw, reg_tmp10.xxyy); + reg_tmp6.x = (reg_tmp0.zzzz + -reg_tmp0.yyyy).x; + reg_tmp6.y = (reg_tmp0.xxxx + reg_tmp0.wwww).y; + reg_tmp6 = mul_s(reg_tmp6, reg_tmp9.xxxx); + reg_tmp3.xyz = (vs_out_attr0[0].xyzz).xyz; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp6.xyyy).xy; + reg_tmp3.w = (uniforms.f[81].zzzz).w; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp7.xyyy).xy; + setemit(0u, false, false); + emit(); + reg_tmp0 = mul_s(reg_tmp1.zwzw, reg_tmp10.xxyy); + reg_tmp6.x = (reg_tmp0.zzzz + -reg_tmp0.yyyy).x; + reg_tmp6.y = (reg_tmp0.xxxx + reg_tmp0.wwww).y; + reg_tmp6 = mul_s(reg_tmp6, reg_tmp9.xxxx); + reg_tmp3.xyz = (vs_out_attr0[0].xyzz).xyz; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp6.xyyy).xy; + reg_tmp3.w = (uniforms.f[81].zzzz).w; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp7.zwww).xy; + setemit(1u, false, false); + emit(); + reg_tmp0 = mul_s(reg_tmp1.xyxy, reg_tmp10.xxyy); + reg_tmp6.x = (reg_tmp0.zzzz + -reg_tmp0.yyyy).x; + reg_tmp6.y = (reg_tmp0.xxxx + reg_tmp0.wwww).y; + reg_tmp6 = mul_s(reg_tmp6, reg_tmp9.xxxx); + reg_tmp3.xyz = (vs_out_attr0[0].xyzz).xyz; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp6.xyyy).xy; + reg_tmp3.w = (uniforms.f[81].zzzz).w; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp8.xyyy).xy; + setemit(2u, true, false); + emit(); + reg_tmp0 = mul_s(reg_tmp1.zyzy, reg_tmp10.xxyy); + reg_tmp6.x = (reg_tmp0.zzzz + -reg_tmp0.yyyy).x; + reg_tmp6.y = (reg_tmp0.xxxx + reg_tmp0.wwww).y; + reg_tmp6 = mul_s(reg_tmp6, reg_tmp9.xxxx); + reg_tmp3.xyz = (vs_out_attr0[0].xyzz).xyz; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp6.xyyy).xy; + reg_tmp3.w = (uniforms.f[81].zzzz).w; + { + sub_6(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2].xy = (reg_tmp8.zwww).xy; + setemit(0u, true, true); + emit(); + return true; + } + case 298u: { + reg_tmp10 = vs_out_attr0[0].xyzz; + reg_tmp11 = vs_out_attr4[0]; + reg_tmp12 = vs_out_attr5[0]; + reg_tmp13 = vs_out_attr6[0]; + reg_tmp14 = vs_out_attr7[0]; + reg_tmp0.xy = (vs_out_attr3[0].zzzz).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp0.xy); + if (conditional_code.x) { + sub_9(); + } else { + sub_10(); + } + return true; + } + default: return false; + } + } + return false; +} +bool sub_1() { + reg_tmp0.xy = (reg_tmp2.xyyy).xy; + reg_tmp2.xy = (reg_tmp3.xyyy).xy; + reg_tmp3.xy = (reg_tmp0.xyyy).xy; + reg_tmp0.xy = (reg_tmp4.xyyy).xy; + reg_tmp4.xy = (reg_tmp5.xyyy).xy; + reg_tmp5.xy = (reg_tmp0.xyyy).xy; + return false; +} +bool sub_2() { + reg_tmp0.xy = (reg_tmp2.xyyy).xy; + reg_tmp2.xy = (reg_tmp4.xyyy).xy; + reg_tmp4.xy = (reg_tmp0.xyyy).xy; + reg_tmp0.xy = (reg_tmp3.xyyy).xy; + reg_tmp3.xy = (reg_tmp5.xyyy).xy; + reg_tmp5.xy = (reg_tmp0.xyyy).xy; + return false; +} +bool sub_3() { + reg_tmp0.xy = (reg_tmp2.xyyy).xy; + reg_tmp2.xy = (reg_tmp4.xyyy).xy; + reg_tmp4.xy = (reg_tmp5.xyyy).xy; + reg_tmp5.xy = (reg_tmp3.xyyy).xy; + reg_tmp3.xy = (reg_tmp0.xyyy).xy; + return false; +} +bool sub_4() { + reg_tmp3.xy = (reg_tmp10.xyyy).xy; + reg_tmp3.z = (reg_tmp1.xxxx + -reg_tmp10.xxxx).z; + reg_tmp3.w = (reg_tmp1.yyyy + -reg_tmp10.yyyy).w; + reg_tmp3 = mul_s(reg_tmp3, reg_tmp2.xxxx); + reg_tmp3.x = (mul_s(reg_tmp3.xxxx, vs_out_attr4[0].yyyy)).x; + reg_tmp3.z = (mul_s(reg_tmp3.zzzz, vs_out_attr4[0].yyyy)).z; + return false; +} +bool sub_5() { + reg_tmp3.x = (reg_tmp1.zzzz).x; + reg_tmp3.y = (reg_tmp1.wwww).y; + reg_tmp3.z = (reg_tmp1.zzzz).z; + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp3 = mul_s(reg_tmp3, reg_tmp2.xxxx); + reg_tmp3.xz = (mul_s(reg_tmp3.xzzz, vs_out_attr4[0].yyyy)).xz; + return false; +} +bool sub_9() { + reg_tmp10.w = (vs_out_attr0[0].wwww).w; + reg_tmp15.xy = (vs_out_attr3[0].xyyy).xy; + reg_tmp15.z = (vs_out_attr0[0].zzzz).z; + reg_tmp15.w = (uniforms.f[81].zzzz).w; + return false; +} +bool sub_10() { + reg_tmp15 = uniforms.f[81].xxxx; + return false; +} +bool sub_6() { + reg_tmp6.xy = (reg_tmp15.zwww).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp6.xy); + if (conditional_code.y) { + sub_7(); + } else { + sub_8(); + } + return false; +} +bool sub_7() { + output_buffer.attributes[0].x = dot_s(reg_tmp3, reg_tmp11); + output_buffer.attributes[0].y = dot_s(reg_tmp3, reg_tmp12); + output_buffer.attributes[0].z = dot_s(reg_tmp3, reg_tmp13); + output_buffer.attributes[0].w = dot_s(reg_tmp3, reg_tmp14); + return false; +} +bool sub_8() { + reg_tmp6.x = dot_s(reg_tmp2, vs_out_attr5[0]); + reg_tmp6.y = dot_s(reg_tmp2, vs_out_attr6[0]); + reg_tmp6.z = dot_s(reg_tmp2, vs_out_attr7[0]); + reg_tmp6.xyz = (reg_tmp6.xyzz + vs_out_attr0[0].xyzz).xyz; + reg_tmp6.w = (uniforms.f[81].zzzz).w; + output_buffer.attributes[0].x = dot_s(reg_tmp6, reg_tmp11); + output_buffer.attributes[0].y = dot_s(reg_tmp6, reg_tmp12); + reg_tmp4.w = dot_s(reg_tmp6, reg_tmp14); + reg_tmp0.xyz = (reg_tmp9.xyzz + reg_tmp6.xyzz).xyz; + reg_tmp0.w = (uniforms.f[81].zzzz).w; + reg_tmp6.w = dot_s(reg_tmp0, reg_tmp14); + reg_tmp6.z = dot_s(reg_tmp0, -reg_tmp13); + reg_tmp6.z = (mul_s(reg_tmp4.wwww, reg_tmp6.zzzz)).z; + reg_tmp2 = vec4(rcp_s(reg_tmp6.w)); + output_buffer.attributes[0].z = (mul_s(reg_tmp6.zzzz, reg_tmp2.zzzz)).z; + output_buffer.attributes[0].w = (reg_tmp4.wwww).w; + return false; +} +// reference: 08FD94C98B1DD023, DDD543B7EFD7D3AC +// shader: 8B31, 309177F344E6BF06 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; +out vec4 vs_out_attr7; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr7 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + uint jmp_to = 0u; + while (true) { + switch (jmp_to) { + case 0u: { + reg_tmp15 = uniforms.f[5].wzyx; + conditional_code = greaterThan(uniforms.f[6].wz, reg_tmp15.xy); + if (conditional_code.y) { + { jmp_to = 30u; break; } + } + reg_tmp1.xy = (vs_in_reg4.wwww).xy; + conditional_code = lessThan(uniforms.f[89].ww, reg_tmp1.xy); + if (conditional_code.x) { + { jmp_to = 68u; break; } + } + vs_out_attr0.xyz = (vs_in_reg0.xyzz).xyz; + vs_out_attr0.w = (mul_s(uniforms.f[7].wwww, vs_in_reg2.zzzz)).w; + vs_out_attr1 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + reg_tmp0.z = (vs_in_reg3.xxxx).z; + reg_tmp0.w = (vs_in_reg3.yyyy).w; + reg_tmp1.x = (uniforms.f[8].xxxx + -vs_in_reg2.yyyy).x; + reg_tmp0.y = (reg_tmp1.xxxx + -reg_tmp0.wwww).y; + reg_tmp0.x = (vs_in_reg2.xxxx).x; + reg_tmp0.xy = (mul_s(uniforms.f[8].wzzz, reg_tmp0.xyyy)).xy; + vs_out_attr2.xy = (reg_tmp0.xyyy).xy; + reg_tmp1.xy = (-uniforms.f[90].xxxx + reg_tmp0.zwww).xy; + reg_tmp1.xy = (mul_s(uniforms.f[8].wzzz, reg_tmp1.xyyy)).xy; + vs_out_attr2.z = (reg_tmp0.xxxx + reg_tmp1.xxxx).z; + vs_out_attr2.w = (reg_tmp0.yyyy + reg_tmp1.yyyy).w; + vs_out_attr3.xy = (uniforms.f[90].wwww).xy; + vs_out_attr3.z = (vs_in_reg4.zzzz).z; + vs_out_attr3.w = (vs_in_reg4.wwww).w; + vs_out_attr4.z = (uniforms.f[9].wwww).z; + vs_out_attr4.xyw = (uniforms.f[90].wwww).xyw; + vs_out_attr5 = uniforms.f[90].wwww; + vs_out_attr6 = uniforms.f[90].wwww; + vs_out_attr7 = uniforms.f[90].wwww; + return true; + } + case 30u: { + vs_out_attr0.xyz = (vs_in_reg0.xyzz).xyz; + vs_out_attr0.w = (mul_s(uniforms.f[7].wwww, vs_in_reg2.zzzz)).w; + vs_out_attr1 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + reg_tmp1.xy = (vs_in_reg4.wwww).xy; + conditional_code = lessThan(uniforms.f[89].ww, reg_tmp1.xy); + if (conditional_code.x) { + { jmp_to = 59u; break; } + } + reg_tmp0.z = (mul_s(uniforms.f[89].wwww, vs_in_reg4.xxxx)).z; + reg_tmp0.w = (mul_s(uniforms.f[89].wwww, vs_in_reg4.yyyy)).w; + reg_tmp1.x = (uniforms.f[8].xxxx + -vs_in_reg2.yyyy).x; + reg_tmp0.y = (reg_tmp1.xxxx + -reg_tmp0.wwww).y; + reg_tmp0.x = (vs_in_reg2.xxxx).x; + reg_tmp0.xy = (mul_s(uniforms.f[8].wzzz, reg_tmp0.xyyy)).xy; + vs_out_attr2.xy = (reg_tmp0.xyyy).xy; + reg_tmp1.xy = (-uniforms.f[90].xxxx + reg_tmp0.zwww).xy; + reg_tmp1.xy = (mul_s(uniforms.f[8].wzzz, reg_tmp1.xyyy)).xy; + vs_out_attr2.z = (reg_tmp0.xxxx + reg_tmp1.xxxx).z; + vs_out_attr2.w = (reg_tmp0.yyyy + reg_tmp1.yyyy).w; + vs_out_attr3.xy = (reg_tmp0.zwww).xy; + vs_out_attr3.z = (mul_s(uniforms.f[90].zzzz, vs_in_reg3.yyyy)).z; + vs_out_attr3.w = (vs_in_reg4.wwww).w; + vs_out_attr4.x = (mul_s(uniforms.f[90].yyyy, vs_in_reg3.xxxx)).x; + vs_out_attr4.y = (mul_s(uniforms.f[91].yyyy, vs_in_reg4.zzzz)).y; + vs_out_attr4.z = (uniforms.f[9].wwww).z; + vs_out_attr4.w = (uniforms.f[90].wwww).w; + vs_out_attr5 = uniforms.f[10].wzyx; + vs_out_attr6 = uniforms.f[11].wzyx; + vs_out_attr7 = uniforms.f[12].wzyx; + return true; + } + case 59u: { + vs_out_attr2 = uniforms.f[90].wwww; + vs_out_attr3.xyz = (uniforms.f[90].wwww).xyz; + vs_out_attr3.w = (vs_in_reg4.wwww).w; + vs_out_attr4 = uniforms.f[0].wzyx; + vs_out_attr5 = uniforms.f[1].wzyx; + vs_out_attr6 = uniforms.f[2].wzyx; + vs_out_attr7 = uniforms.f[3].wzyx; + return true; + } + case 68u: { + vs_out_attr0.xyz = (vs_in_reg0.xyzz).xyz; + vs_out_attr0.w = (mul_s(uniforms.f[90].yyyy, vs_in_reg2.wwww)).w; + vs_out_attr1 = uniforms.f[90].wwww; + vs_out_attr2 = uniforms.f[90].wwww; + vs_out_attr3.x = (vs_in_reg3.xxxx).x; + vs_out_attr3.y = (vs_in_reg3.yyyy).y; + vs_out_attr3.z = (uniforms.f[90].xxxx).z; + vs_out_attr3.w = (vs_in_reg4.wwww).w; + conditional_code = equal(uniforms.f[90].ww, vs_in_reg4.zz); + if (conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + return true; + } + default: return false; + } + } + return false; +} +bool sub_1() { + vs_out_attr4 = uniforms.f[14].wzyx; + vs_out_attr5 = uniforms.f[15].wzyx; + vs_out_attr6 = uniforms.f[16].wzyx; + vs_out_attr7 = uniforms.f[17].wzyx; + return false; +} +bool sub_2() { + vs_out_attr4 = uniforms.f[18].wzyx; + vs_out_attr5 = uniforms.f[19].wzyx; + vs_out_attr6 = uniforms.f[20].wzyx; + vs_out_attr7 = uniforms.f[21].wzyx; + return false; +} +// reference: 2AE417A070FC8698, 309177F344E6BF06 +// shader: 8B30, 411AA67B9C4AA6C7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5CCCF89D77227653, 411AA67B9C4AA6C7 +// program: 309177F344E6BF06, DDD543B7EFD7D3AC, 411AA67B9C4AA6C7 +// shader: 8B31, 80D1D7D314667808 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.xy = (vs_in_reg0.xyyy).xy; + vs_out_attr0.zw = (uniforms.f[90].wzwz).zw; + reg_tmp0 = vs_in_reg0.zwzw; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + reg_tmp1.x = dot_s(uniforms.f[5].wzyx, reg_tmp0); + reg_tmp1.y = dot_s(uniforms.f[6].wzyx, reg_tmp0); + vs_out_attr1 = reg_tmp1.xyxy; + return true; +} +// reference: E11E134EB4F347AF, 80D1D7D314667808 +// shader: 8B30, 07E09BEA5420C264 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3EAB7AC436F49F59, 07E09BEA5420C264 +// program: 80D1D7D314667808, 6B49BF5FD5349480, 07E09BEA5420C264 +// shader: 8DD9, B99A1F5927E7BF45 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = vtx.attributes[5].z; + view = vec3(vtx.attributes[4].x, vtx.attributes[4].y, vtx.attributes[4].z); + texcoord2 = vec2(vtx.attributes[2].z, vtx.attributes[2].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[6](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0]); + prim_buffer[1].attributes = vec4[6](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1]); + prim_buffer[2].attributes = vec4[6](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 46D4F628ABD6EA28, B99A1F5927E7BF45 +// shader: 8B31, 270E94B55796EDB7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 5) in vec4 vs_in_reg5; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_6(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp2.x = dot_3(uniforms.f[5].wzy, vs_in_reg1.xyz); + reg_tmp2.y = dot_3(uniforms.f[6].wzy, vs_in_reg1.xyz); + reg_tmp2.z = dot_3(uniforms.f[7].wzy, vs_in_reg1.xyz); + reg_tmp1 = vs_in_reg0.xyzz; + reg_tmp1.w = (uniforms.f[94].wwww).w; + reg_tmp10 = vs_in_reg2.xyyy; + reg_tmp10.zw = (uniforms.f[95].yxyx).zw; + reg_tmp3.x = dot_3(uniforms.f[8].wzy, reg_tmp2.xyz); + reg_tmp3.y = dot_3(uniforms.f[9].wzy, reg_tmp2.xyz); + reg_tmp3.z = dot_3(uniforms.f[10].wzy, reg_tmp2.xyz); + reg_tmp8.x = dot_s(uniforms.f[5].wzyx, reg_tmp1); + reg_tmp8.y = dot_s(uniforms.f[6].wzyx, reg_tmp1); + reg_tmp8.z = dot_s(uniforms.f[7].wzyx, reg_tmp1); + reg_tmp8.w = (uniforms.f[94].wwww).w; + reg_tmp9.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + reg_tmp11 = reg_tmp10; + if (uniforms.b[0]) { + sub_1(); + } + reg_tmp9.x = rsq_s(reg_tmp9.x); + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp8); + reg_tmp9 = mul_s(reg_tmp3, reg_tmp9.xxxx); + reg_tmp9.w = (uniforms.f[94].wwww).w; + reg_tmp12.w = (mul_s(uniforms.f[94].yyyy, vs_in_reg1.wwww)).w; + conditional_code = equal(-uniforms.f[94].ww, reg_tmp9.zz); + reg_tmp4 = uniforms.f[94].wwww + reg_tmp9.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].xxxx, reg_tmp4); + if (uniforms.b[13]) { + sub_9(); + } + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].xxxx, reg_tmp9); + if (!conditional_code.x) { + sub_10(); + } else { + sub_11(); + } + if (uniforms.b[9]) { + sub_12(); + } else { + sub_14(); + } + if (uniforms.b[5]) { + sub_17(); + } + vs_out_attr2.x = dot_s(uniforms.f[33].wzyx, reg_tmp10); + vs_out_attr2.y = dot_s(uniforms.f[34].wzyx, reg_tmp10); + vs_out_attr2.z = dot_s(uniforms.f[35].wzyx, reg_tmp11); + vs_out_attr2.w = dot_s(uniforms.f[36].wzyx, reg_tmp11); + vs_out_attr4.x = dot_s(-uniforms.f[8].wzyx, reg_tmp8); + vs_out_attr4.y = dot_s(-uniforms.f[9].wzyx, reg_tmp8); + vs_out_attr4.zw = vec2(dot_s(-uniforms.f[10].wzyx, reg_tmp8)); + vs_out_attr1 = reg_tmp12; + if (uniforms.b[6]) { + sub_18(); + } else { + sub_19(); + } + return true; +} +bool sub_1() { + if (uniforms.b[1]) { + sub_2(); + } else { + sub_3(); + } + reg_tmp4 = uniforms.f[94].zzzz; + if (uniforms.b[2]) { + sub_4(); + } + if (uniforms.b[3]) { + sub_7(); + } + reg_tmp8.y = (reg_tmp8.yyyy + reg_tmp4.yyyy).y; + return false; +} +bool sub_2() { + reg_tmp6 = reg_tmp8; + return false; +} +bool sub_3() { + reg_tmp5 = uniforms.f[94].zzzz; + reg_tmp6.x = dot_s(uniforms.f[5].wzyx, reg_tmp5); + reg_tmp6.y = dot_s(uniforms.f[6].wzyx, reg_tmp5); + return false; +} +bool sub_4() { + address_registers.z = int(uniforms.i[0].y); + for (uint loop24 = 0u; loop24 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop24) { + sub_5(); + } + return false; +} +bool sub_5() { + reg_tmp3.x = dot_3(uniforms.f[12 + address_registers.z].wzy, reg_tmp6.xyz); + reg_tmp3.yz = (uniforms.f[20 + address_registers.z].wzyx).yz; + reg_tmp3.x = (fma_s(reg_tmp3.xxxx, reg_tmp3.yyyy, reg_tmp3.zzzz)).x; + { + sub_6(); + } + reg_tmp4 = fma_s(reg_tmp2.xyxx, uniforms.f[20 + address_registers.z].wwww, reg_tmp4); + return false; +} +bool sub_7() { + address_registers.z = int(uniforms.i[1].y); + for (uint loop32 = 0u; loop32 <= uniforms.i[1].x; address_registers.z += int(uniforms.i[1].z), ++loop32) { + sub_8(); + } + return false; +} +bool sub_8() { + reg_tmp5 = -uniforms.f[12 + address_registers.z].wzyx + reg_tmp6; + reg_tmp7.x = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp5.w = rcp_s(reg_tmp7.x); + reg_tmp5.xyz = (mul_s(reg_tmp5, reg_tmp7.xxxx)).xyz; + reg_tmp3.yz = (uniforms.f[20 + address_registers.z].wzyx).yz; + reg_tmp3.x = (fma_s(reg_tmp5.wwww, reg_tmp3.yyyy, reg_tmp3.zzzz)).x; + { + sub_6(); + } + reg_tmp3.x = (mul_s(-uniforms.f[12 + address_registers.z].xxxx, reg_tmp5.wwww)).x; + reg_tmp3.x = (uniforms.f[94].wwww + reg_tmp3.xxxx).x; + reg_tmp3.x = (min(uniforms.f[94].wwww, reg_tmp3.xxxx)).x; + reg_tmp3.x = (max(uniforms.f[94].zzzz, reg_tmp3.xxxx)).x; + reg_tmp7.x = (mul_s(uniforms.f[20 + address_registers.z].wwww, reg_tmp3.xxxx)).x; + reg_tmp3.x = (mul_s(reg_tmp3.xxxx, reg_tmp3.xxxx)).x; + reg_tmp5.xyz = (reg_tmp5.xyzz + -reg_tmp2.xyxx).xyz; + reg_tmp3.xyz = (fma_s(reg_tmp3.xxxx, reg_tmp5.xyzz, reg_tmp2.xyxx)).xyz; + reg_tmp4 = fma_s(reg_tmp3, reg_tmp7.xxxx, reg_tmp4); + return false; +} +bool sub_9() { + reg_tmp11.xy = (vs_in_reg5.xyxy).xy; + return false; +} +bool sub_10() { + vs_out_attr3.z = rcp_s(reg_tmp4.x); + vs_out_attr3.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + vs_out_attr3.w = (uniforms.f[94].zzzz).w; + return false; +} +bool sub_11() { + vs_out_attr3.x = (uniforms.f[94].wwww).x; + vs_out_attr3.yzw = (uniforms.f[94].zzzz).yzw; + return false; +} +bool sub_12() { + reg_tmp5 = mul_s(uniforms.f[93].wwww, vs_in_reg3); + reg_tmp1 = uniforms.f[93].zzzz + -reg_tmp5; + reg_tmp2.x = rcp_s(reg_tmp1.x); + reg_tmp2.y = rcp_s(reg_tmp1.y); + reg_tmp2.z = rcp_s(reg_tmp1.z); + reg_tmp5.xyz = (mul_s(reg_tmp5, reg_tmp2)).xyz; + reg_tmp12.xyz = (mul_s(uniforms.f[28].wzyx, reg_tmp5.xyzz)).xyz; + if (uniforms.b[4]) { + sub_13(); + } + return false; +} +bool sub_13() { + reg_tmp12.w = (reg_tmp5.wwww).w; + return false; +} +bool sub_14() { + if (uniforms.b[10]) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp11.xy = (mul_s(uniforms.f[93].yyyy, vs_in_reg3.xyxy)).xy; + reg_tmp12.xyz = (uniforms.f[29].wzyx).xyz; + return false; +} +bool sub_16() { + reg_tmp12.x = dot_s(uniforms.f[30].wzyx, reg_tmp9); + reg_tmp12.y = dot_s(uniforms.f[31].wzyx, reg_tmp9); + reg_tmp12.z = dot_s(uniforms.f[32].wzyx, reg_tmp9); + reg_tmp12.xyz = (mul_s(uniforms.f[94].xxxx, reg_tmp12)).xyz; + return false; +} +bool sub_17() { + reg_tmp1 = uniforms.f[94].xxxx; + reg_tmp11.xy = (fma_s(reg_tmp9.xyxy, reg_tmp1, reg_tmp1)).xy; + return false; +} +bool sub_18() { + vs_out_attr5.x = dot_s(uniforms.f[37].wzyx, reg_tmp8); + vs_out_attr5.y = dot_s(uniforms.f[38].wzyx, reg_tmp8); + vs_out_attr5.zw = vec2(dot_s(uniforms.f[39].wzyx, reg_tmp8)); + return false; +} +bool sub_19() { + if (uniforms.b[7]) { + sub_20(); + } else { + sub_21(); + } + return false; +} +bool sub_20() { + reg_tmp3 = -uniforms.f[40].wzyx + reg_tmp8; + reg_tmp3.w = (uniforms.f[94].zzzz).w; + reg_tmp5.x = dot_3(uniforms.f[5].wzy, vs_in_reg1.xyz); + reg_tmp5.y = dot_3(uniforms.f[6].wzy, vs_in_reg1.xyz); + reg_tmp5.z = dot_3(uniforms.f[7].wzy, vs_in_reg1.xyz); + reg_tmp4.x = dot_s(reg_tmp3, reg_tmp3); + reg_tmp4.x = rsq_s(reg_tmp4.x); + reg_tmp4 = mul_s(reg_tmp3, reg_tmp4.xxxx); + reg_tmp5.w = (uniforms.f[94].zzzz).w; + reg_tmp6.x = dot_s(reg_tmp5, reg_tmp5); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp6 = mul_s(reg_tmp5, reg_tmp6.xxxx); + reg_tmp2 = vec4(dot_3(reg_tmp4.xyz, reg_tmp6.xyz)); + reg_tmp2 = mul_s(uniforms.f[93].xxxx, reg_tmp2); + reg_tmp2 = mul_s(reg_tmp6, reg_tmp2.xxxx); + vs_out_attr5 = reg_tmp4 + -reg_tmp2; + return false; +} +bool sub_21() { + vs_out_attr5 = reg_tmp10; + return false; +} +bool sub_6() { + reg_tmp2.x = (uniforms.f[92].wwww).x; + reg_tmp2.y = (uniforms.f[94].wwww).y; + reg_tmp2.z = (uniforms.f[93].xxxx).z; + reg_tmp2.w = (uniforms.f[92].zzzz).w; + reg_tmp3.x = (mul_s(uniforms.f[92].yyyy, reg_tmp3.xxxx)).x; + reg_tmp3.y = (reg_tmp3.xxxx + -reg_tmp2.xxxx).y; + reg_tmp3.zw = (floor(reg_tmp3.xyxy)).zw; + reg_tmp3.xy = (reg_tmp3.xyyy + -reg_tmp3.zwww).xy; + reg_tmp3.xy = (fma_s(reg_tmp3.xyyy, reg_tmp2.zzzz, -reg_tmp2.yyyy)).xy; + reg_tmp3.xy = (abs(reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (fma_s(reg_tmp3.xyxy, -reg_tmp2.zzzz, reg_tmp2.wwww)).xy; + reg_tmp3.xy = (mul_s(reg_tmp3.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp3.xy = (mul_s(reg_tmp2.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (fma_s(reg_tmp3.xyyy, reg_tmp2.zzzz, -reg_tmp2.yyyy)).xy; + return false; +} +// reference: 0515C1CC64C6047E, 270E94B55796EDB7 +// shader: 8B30, 877EA791AA03C3C0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BEDBD3B568D12F1A, 877EA791AA03C3C0 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 877EA791AA03C3C0 +// shader: 8DD9, A29BAEF5C1BA44F2 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z, vtx.attributes[2].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[4].x, vtx.attributes[4].y, vtx.attributes[4].z, vtx.attributes[4].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + texcoord1 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + + texcoord0_w = vtx.attributes[5].z; + view = vec3(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z); + texcoord2 = vec2(vtx.attributes[1].z, vtx.attributes[1].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[6](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0]); + prim_buffer[1].attributes = vec4[6](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1]); + prim_buffer[2].attributes = vec4[6](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 2999884939626C3C, A29BAEF5C1BA44F2 +// shader: 8B31, 22186AF454C341E4 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; +layout(location = 9) in vec4 vs_in_reg9; +layout(location = 10) in vec4 vs_in_reg10; +layout(location = 11) in vec4 vs_in_reg11; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp2 = mul_s(uniforms.f[95].wwzz, vs_in_reg3); + reg_tmp1 = vs_in_reg0.xyzz; + reg_tmp1.w = (uniforms.f[94].wwww).w; + if (uniforms.b[14]) { + sub_1(); + } + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = mul_s(uniforms.f[6 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp14 = mul_s(uniforms.f[7 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp15 = mul_s(uniforms.f[8 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp13 = fma_s(reg_tmp2.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + if (uniforms.b[11]) { + sub_2(); + } + reg_tmp2.x = dot_3(vs_in_reg1.xyz, reg_tmp13.xyz); + reg_tmp2.y = dot_3(vs_in_reg1.xyz, reg_tmp14.xyz); + reg_tmp2.z = dot_3(vs_in_reg1.xyz, reg_tmp15.xyz); + reg_tmp8.x = dot_s(reg_tmp1, reg_tmp13); + reg_tmp8.y = dot_s(reg_tmp1, reg_tmp14); + reg_tmp8.z = dot_s(reg_tmp1, reg_tmp15); + reg_tmp8.w = (uniforms.f[94].wwww).w; + reg_tmp3.x = dot_3(uniforms.f[78].wzy, reg_tmp2.xyz); + reg_tmp3.y = dot_3(uniforms.f[79].wzy, reg_tmp2.xyz); + reg_tmp3.z = dot_3(uniforms.f[80].wzy, reg_tmp2.xyz); + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp8); + reg_tmp9.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + reg_tmp10 = vs_in_reg2.xyyy; + reg_tmp10.zw = (uniforms.f[95].yxyx).zw; + reg_tmp11 = vs_in_reg2.xyyy; + reg_tmp11.zw = (uniforms.f[95].yxyx).zw; + reg_tmp9.x = rsq_s(reg_tmp9.x); + reg_tmp9 = mul_s(reg_tmp3, reg_tmp9.xxxx); + reg_tmp9.w = (uniforms.f[94].wwww).w; + if (uniforms.b[13]) { + sub_4(); + } + if (uniforms.b[0]) { + sub_5(); + } + conditional_code = equal(-uniforms.f[94].ww, reg_tmp9.zz); + reg_tmp3 = uniforms.f[94].wwww + reg_tmp9.zzzz; + vs_out_attr1.x = dot_s(uniforms.f[82].wzyx, reg_tmp10); + vs_out_attr1.y = dot_s(uniforms.f[83].wzyx, reg_tmp10); + reg_tmp3 = mul_s(uniforms.f[94].zzzz, reg_tmp3); + vs_out_attr1.z = dot_s(uniforms.f[84].wzyx, reg_tmp11); + vs_out_attr1.w = dot_s(uniforms.f[85].wzyx, reg_tmp11); + reg_tmp3 = vec4(rsq_s(reg_tmp3.x)); + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp9); + if (!conditional_code.x) { + sub_6(); + } else { + sub_7(); + } + reg_tmp12.x = dot_s(uniforms.f[86].wzyx, reg_tmp9); + reg_tmp12.y = dot_s(uniforms.f[87].wzyx, reg_tmp9); + reg_tmp12.z = dot_s(uniforms.f[88].wzyx, reg_tmp9); + vs_out_attr3.x = dot_s(-uniforms.f[78].wzyx, reg_tmp8); + vs_out_attr3.y = dot_s(-uniforms.f[79].wzyx, reg_tmp8); + vs_out_attr3.zw = vec2(dot_s(-uniforms.f[80].wzyx, reg_tmp8)); + vs_out_attr4.w = (mul_s(uniforms.f[94].xxxx, vs_in_reg1.wwww)).w; + vs_out_attr4.xyz = (mul_s(uniforms.f[94].zzzz, reg_tmp12)).xyz; + if (uniforms.b[1]) { + sub_8(); + } else { + sub_9(); + } + return true; +} +bool sub_1() { + reg_tmp1.xyz = (fma_s(vs_in_reg8.xyzz, uniforms.f[5].wwww, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg9.xyzz, uniforms.f[5].zzzz, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg10.xyzz, uniforms.f[5].yyyy, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg11.xyzz, uniforms.f[5].xxxx, reg_tmp1)).xyz; + return false; +} +bool sub_2() { + reg_tmp2 = mul_s(uniforms.f[95].wwzz, vs_in_reg5); + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = fma_s(reg_tmp2.zzzz, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.zzzz, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.zzzz, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp2.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + if (uniforms.b[12]) { + sub_3(); + } + return false; +} +bool sub_3() { + reg_tmp2 = mul_s(uniforms.f[95].wwww, vs_in_reg6); + reg_tmp3 = mul_s(uniforms.f[95].zzzz, vs_in_reg7); + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = fma_s(reg_tmp3.xxxx, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.xxxx, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.xxxx, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp3.yyyy, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.yyyy, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.yyyy, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + address_registers.xy = ivec2(reg_tmp2.zw); + reg_tmp13 = fma_s(reg_tmp3.zzzz, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.zzzz, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.zzzz, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp3.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + return false; +} +bool sub_4() { + reg_tmp11.xy = (vs_in_reg6.xyxy).xy; + return false; +} +bool sub_5() { + reg_tmp1 = uniforms.f[94].zzzz; + reg_tmp11.xy = (fma_s(reg_tmp9.xyxy, reg_tmp1, reg_tmp1)).xy; + return false; +} +bool sub_6() { + vs_out_attr2.z = rcp_s(reg_tmp3.x); + vs_out_attr2.xy = (mul_s(reg_tmp4, reg_tmp3)).xy; + vs_out_attr2.w = (uniforms.f[94].yyyy).w; + return false; +} +bool sub_7() { + vs_out_attr2.x = (uniforms.f[94].wwww).x; + vs_out_attr2.yzw = (uniforms.f[94].yyyy).yzw; + return false; +} +bool sub_8() { + vs_out_attr5.x = dot_s(uniforms.f[89].wzyx, reg_tmp8); + vs_out_attr5.y = dot_s(uniforms.f[90].wzyx, reg_tmp8); + vs_out_attr5.zw = vec2(dot_s(uniforms.f[91].wzyx, reg_tmp8)); + return false; +} +bool sub_9() { + if (uniforms.b[2]) { + sub_10(); + } else { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp3 = -uniforms.f[92].wzyx + reg_tmp8; + reg_tmp3.w = (uniforms.f[94].yyyy).w; + reg_tmp5.x = dot_3(vs_in_reg1.xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(vs_in_reg1.xyz, reg_tmp14.xyz); + reg_tmp5.z = dot_3(vs_in_reg1.xyz, reg_tmp15.xyz); + reg_tmp4.x = dot_s(reg_tmp3, reg_tmp3); + reg_tmp4.x = rsq_s(reg_tmp4.x); + reg_tmp4 = mul_s(reg_tmp3, reg_tmp4.xxxx); + reg_tmp5.w = (uniforms.f[94].yyyy).w; + reg_tmp6.x = dot_s(reg_tmp5, reg_tmp5); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp6 = mul_s(reg_tmp5, reg_tmp6.xxxx); + reg_tmp2 = vec4(dot_3(reg_tmp4.xyz, reg_tmp6.xyz)); + reg_tmp2 = mul_s(uniforms.f[93].wwww, reg_tmp2); + reg_tmp2 = mul_s(reg_tmp6, reg_tmp2.xxxx); + vs_out_attr5 = reg_tmp4 + -reg_tmp2; + return false; +} +bool sub_11() { + vs_out_attr5 = reg_tmp10; + return false; +} +// reference: 8A2DA5208889CBBC, 22186AF454C341E4 +// shader: 8B30, 73AF4963C0D75174 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((rounded_primary_color.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texture(tex_cube, vec3(texcoord0, texcoord0_w)).rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp(min((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 646DEEC36301105B, 73AF4963C0D75174 +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, 73AF4963C0D75174 +// reference: 11992A6F12097B5D, 7974F3663498993D +// reference: D4F4BEF9BF687954, 30B703594147E54C +// shader: 8DD9, 2FFCFD3BCBB0B878 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[1].z, vtx.attributes[1].w); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 740EEEAAB290EC56, 2FFCFD3BCBB0B878 +// shader: 8B31, 618378764C54D2BC + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp1 = vec4(lessThan(vs_in_reg0.xyyy, -vs_in_reg0.xyyy)); + reg_tmp2 = vec4(lessThan(-vs_in_reg0.xyyy, vs_in_reg0.xyyy)); + reg_tmp0 = reg_tmp2 + -reg_tmp1; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + vs_out_attr0 = reg_tmp0; + reg_tmp1 = abs(vs_in_reg0.xyyy); + reg_tmp11.x = rcp_s(reg_tmp1.x); + reg_tmp11.y = rcp_s(reg_tmp1.y); + reg_tmp10 = mul_s(vs_in_reg0.zwzw, reg_tmp11.xyxy); + vs_out_attr1 = reg_tmp10.xyxy; + vs_out_attr2 = reg_tmp10.xyxy; + return true; +} +// reference: E48CD0A4ACA459CD, 618378764C54D2BC +// shader: 8B30, F63831B89ABA550B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) - (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) - (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.r); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) - (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) + (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4 * 2.0, alpha_output_4 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52A13DB13360B5D9, F63831B89ABA550B +// program: 618378764C54D2BC, 2FFCFD3BCBB0B878, F63831B89ABA550B +// shader: 8B31, B7CC05B4C0A6559A + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp1 = vec4(lessThan(vs_in_reg0.xyyy, -vs_in_reg0.xyyy)); + reg_tmp2 = vec4(lessThan(-vs_in_reg0.xyyy, vs_in_reg0.xyyy)); + reg_tmp0 = reg_tmp2 + -reg_tmp1; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + vs_out_attr0 = reg_tmp0; + reg_tmp1 = abs(vs_in_reg0.xyyy); + reg_tmp11.x = rcp_s(reg_tmp1.x); + reg_tmp11.y = rcp_s(reg_tmp1.y); + reg_tmp10 = mul_s(vs_in_reg0.zwzw, reg_tmp11.xyxy); + reg_tmp1 = reg_tmp10.xyxy; + reg_tmp2 = reg_tmp10.xyxy; + reg_tmp1 = uniforms.f[5].wzyx + reg_tmp1; + vs_out_attr1 = reg_tmp1; + vs_out_attr2 = reg_tmp2; + return true; +} +// reference: 3232E311FC98E414, B7CC05B4C0A6559A +// shader: 8B30, AE7CB40E411B6D93 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb) + (texcolor1.rgb) * (vec3(1.0) - (const_color[0].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb) + (texcolor2.rgb) * (vec3(1.0) - (const_color[1].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6C58843528F68BDC, AE7CB40E411B6D93 +// program: B7CC05B4C0A6559A, 2FFCFD3BCBB0B878, AE7CB40E411B6D93 +// program: 618378764C54D2BC, 2FFCFD3BCBB0B878, 30B703594147E54C +// shader: 8B30, CFB695EB731701B7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) + (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (texcolor2.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (texcolor0.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9137C344190B91C2, CFB695EB731701B7 +// program: 618378764C54D2BC, 2FFCFD3BCBB0B878, CFB695EB731701B7 +// shader: 8B31, 70334CCBBF56C39B + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = vs_in_reg0.xyyy; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (vs_in_reg1.xyxy).zw; + reg_tmp2 = vs_in_reg1.zwzw; + vs_out_attr0 = reg_tmp0; + vs_out_attr1 = reg_tmp1; + vs_out_attr2 = reg_tmp2; + return true; +} +// reference: 789FD29B21AAFFB6, 70334CCBBF56C39B +// shader: 8B30, 717AD08F5687F31E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor2.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb) + (texcolor1.rgb) * (vec3(1.0) - (const_color[1].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb) + (texcolor0.rgb) * (vec3(1.0) - (const_color[2].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C62A63A7F419638C, 717AD08F5687F31E +// program: 70334CCBBF56C39B, 2FFCFD3BCBB0B878, 717AD08F5687F31E +// shader: 8B30, A8E89446D7AFA4F2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor2.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb) + (texcolor1.rgb) * (vec3(1.0) - (const_color[1].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb) + (texcolor0.rgb) * (vec3(1.0) - (const_color[2].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D01084672002E480, A8E89446D7AFA4F2 +// program: 70334CCBBF56C39B, 2FFCFD3BCBB0B878, A8E89446D7AFA4F2 +// shader: 8B30, F9D61D3C0DEA79AA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D24268668D12F1A, F9D61D3C0DEA79AA +// program: 270E94B55796EDB7, B99A1F5927E7BF45, F9D61D3C0DEA79AA +// shader: 8B30, 1EC5C93FF87CE639 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D2426868466C419, 1EC5C93FF87CE639 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 1EC5C93FF87CE639 +// shader: 8B30, E24286E8F9FFA8FB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texture(tex_cube, vec3(texcoord0, texcoord0_w)); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4849B2108466C419, E24286E8F9FFA8FB +// program: 270E94B55796EDB7, B99A1F5927E7BF45, E24286E8F9FFA8FB +// shader: 8B30, D3A3921C1FC1C66D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texture(tex_cube, vec3(texcoord0, texcoord0_w)); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9A5A0F1BC39FCBBF, D3A3921C1FC1C66D +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, D3A3921C1FC1C66D +// shader: 8B30, BB7F43EB369B7B08 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 14A478AF871AEC44, BB7F43EB369B7B08 +// program: A226445F0A79E9EE, 23B87C5B1F79AE3C, BB7F43EB369B7B08 +// shader: 8B31, C2BC311B77541DBD + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = uniforms.f[4].wwww; + conditional_code = equal(uniforms.f[5].wz, reg_tmp0.xy); + if (any(conditional_code)) { + sub_1(); + } else { + sub_2(); + } + reg_tmp0 = vs_in_reg0.zwzw; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + reg_tmp2.x = dot_s(uniforms.f[6].wzyx, reg_tmp0); + reg_tmp2.y = dot_s(uniforms.f[7].wzyx, reg_tmp0); + vs_out_attr0 = reg_tmp1; + vs_out_attr1 = reg_tmp2.xyxy; + return true; +} +bool sub_1() { + reg_tmp1.xy = (vs_in_reg0.xyyy).xy; + reg_tmp1.zw = (uniforms.f[90].wzwz).zw; + return false; +} +bool sub_2() { + reg_tmp1.xy = (uniforms.f[90].yxyx).xy; + reg_tmp1.zw = (uniforms.f[90].wzwz).zw; + return false; +} +// reference: 573D524250C11774, C2BC311B77541DBD +// shader: 8B30, E7C75A2FFF03996B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0A45E4E6E9B49EAD, E7C75A2FFF03996B +// program: C2BC311B77541DBD, 6B49BF5FD5349480, E7C75A2FFF03996B +// shader: 8B30, 674BFA78A0C735D5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 14A478AF79BBAB7A, 674BFA78A0C735D5 +// program: A226445F0A79E9EE, 23B87C5B1F79AE3C, 674BFA78A0C735D5 +// shader: 8B30, 7F5D871DF255D3D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0E61E83EF748A1F4, 7F5D871DF255D3D1 +// program: A226445F0A79E9EE, 23B87C5B1F79AE3C, 7F5D871DF255D3D1 +// shader: 8B30, 451BECB7251D59E8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D242686E7C98459, 451BECB7251D59E8 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 451BECB7251D59E8 +// shader: 8B31, 7EE366499F4A080E + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp2.x = dot_3(uniforms.f[5].wzy, vs_in_reg1.xyz); + reg_tmp2.y = dot_3(uniforms.f[6].wzy, vs_in_reg1.xyz); + reg_tmp2.z = dot_3(uniforms.f[7].wzy, vs_in_reg1.xyz); + reg_tmp1 = vs_in_reg0.xyzz; + reg_tmp1.w = (uniforms.f[94].wwww).w; + reg_tmp10 = vs_in_reg2.xyyy; + reg_tmp10.zw = (uniforms.f[95].yxyx).zw; + reg_tmp3.x = dot_3(uniforms.f[8].wzy, reg_tmp2.xyz); + reg_tmp3.y = dot_3(uniforms.f[9].wzy, reg_tmp2.xyz); + reg_tmp3.z = dot_3(uniforms.f[10].wzy, reg_tmp2.xyz); + reg_tmp8.x = dot_s(uniforms.f[5].wzyx, reg_tmp1); + reg_tmp8.y = dot_s(uniforms.f[6].wzyx, reg_tmp1); + reg_tmp8.z = dot_s(uniforms.f[7].wzyx, reg_tmp1); + reg_tmp8.w = (uniforms.f[94].wwww).w; + reg_tmp9.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + vs_out_attr2.xz = vec2(dot_s(uniforms.f[12].wzyx, reg_tmp10)); + vs_out_attr2.yw = vec2(dot_s(uniforms.f[13].wzyx, reg_tmp10)); + vs_out_attr5.xz = vec2(dot_s(uniforms.f[12].wzyx, reg_tmp10)); + vs_out_attr5.yw = vec2(dot_s(uniforms.f[13].wzyx, reg_tmp10)); + reg_tmp9.x = rsq_s(reg_tmp9.x); + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp8); + reg_tmp9 = mul_s(reg_tmp3, reg_tmp9.xxxx); + reg_tmp9.w = (uniforms.f[94].wwww).w; + conditional_code = equal(-uniforms.f[94].ww, reg_tmp9.zz); + reg_tmp4 = uniforms.f[94].wwww + reg_tmp9.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + vs_out_attr3.w = (uniforms.f[94].yyyy).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp9); + if (!conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + if (uniforms.b[9]) { + sub_3(); + } else { + sub_4(); + } + vs_out_attr4.x = dot_s(-uniforms.f[8].wzyx, reg_tmp8); + vs_out_attr4.y = dot_s(-uniforms.f[9].wzyx, reg_tmp8); + vs_out_attr4.zw = vec2(dot_s(-uniforms.f[10].wzyx, reg_tmp8)); + vs_out_attr1.xyz = (mul_s(uniforms.f[94].zzzz, reg_tmp12)).xyz; + vs_out_attr1.w = (mul_s(uniforms.f[17].xxxx, reg_tmp12.wwww)).w; + return true; +} +bool sub_1() { + vs_out_attr3.z = rcp_s(reg_tmp4.x); + vs_out_attr3.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_2() { + vs_out_attr3.x = (uniforms.f[94].wwww).x; + vs_out_attr3.yzw = (uniforms.f[94].yyyy).yzw; + return false; +} +bool sub_3() { + reg_tmp5 = mul_s(uniforms.f[94].xxxx, vs_in_reg3); + reg_tmp1 = uniforms.f[93].wwww + -reg_tmp5; + reg_tmp2.x = rcp_s(reg_tmp1.x); + reg_tmp2.y = rcp_s(reg_tmp1.y); + reg_tmp2.z = rcp_s(reg_tmp1.z); + reg_tmp12.xyz = (mul_s(reg_tmp5, reg_tmp2)).xyz; + reg_tmp12.w = (reg_tmp5.wwww).w; + return false; +} +bool sub_4() { + reg_tmp12.x = dot_s(uniforms.f[14].wzyx, reg_tmp9); + reg_tmp12.y = dot_s(uniforms.f[15].wzyx, reg_tmp9); + reg_tmp12.z = dot_s(uniforms.f[16].wzyx, reg_tmp9); + reg_tmp12.w = (uniforms.f[94].wwww).w; + return false; +} +// reference: 90D70461C520AC3A, 7EE366499F4A080E +// shader: 8B30, D4ABAB02A99E56D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 502350D743DA4A19, D4ABAB02A99E56D1 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, D4ABAB02A99E56D1 +// shader: 8B30, 91E0DB69EB539CEF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B5BCFA310B7E6F5A, 91E0DB69EB539CEF +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 91E0DB69EB539CEF +// shader: 8DD9, 4BDB22C6C8A27B8E + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +in vec4 vs_out_attr7[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_14(); +bool sub_15(); +bool sub_12(); +bool sub_13(); +bool sub_9(); +bool sub_10(); +bool sub_6(); +bool sub_7(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_11(); +bool sub_8(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + uint jmp_to = 60u; + while (true) { + switch (jmp_to) { + case 60u: { + conditional_code = lessThan(uniforms.f[82].zz, vs_out_attr3[0].ww); + if (conditional_code.x) { + { jmp_to = 130u; break; } + } + reg_tmp1.xy = (reg_tmp15.xxxx).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp1.xy); + if (conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + conditional_code.x = uniforms.f[81].xxxx.x == reg_tmp15.wwww.x; + conditional_code.y = uniforms.f[81].xxxx.y != reg_tmp15.wwww.y; + if (conditional_code.x) { + { jmp_to = 97u; break; } + } + conditional_code = equal(uniforms.f[81].zw, reg_tmp15.ww); + if (conditional_code.x) { + { jmp_to = 108u; break; } + } + if (conditional_code.y) { + { jmp_to = 119u; break; } + } + reg_tmp6.xyz = (reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].xyyy).xy; + { + sub_6(); + } + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].zwww).xy; + { + sub_7(); + } + { + sub_8(); + } + return true; + } + case 97u: { + reg_tmp6.xyz = (reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].xyyy).xy; + { + sub_14(); + } + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].zwww).xy; + { + sub_15(); + } + { + sub_11(); + } + return true; + } + case 108u: { + reg_tmp6.xyz = (reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].xyyy).xy; + { + sub_12(); + } + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].zwww).xy; + { + sub_13(); + } + { + sub_11(); + } + return true; + } + case 119u: { + reg_tmp6.xyz = (reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].xyyy).xy; + { + sub_9(); + } + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + { + sub_3(); + } + output_buffer.attributes[2].xy = (vs_out_attr2[0].zwww).xy; + { + sub_10(); + } + { + sub_11(); + } + return true; + } + case 130u: { + reg_tmp11 = vs_out_attr4[0]; + reg_tmp12 = vs_out_attr5[0]; + reg_tmp13 = vs_out_attr6[0]; + reg_tmp14 = vs_out_attr7[0]; + reg_tmp15.w = (uniforms.f[81].xxxx).w; + reg_tmp15.z = (vs_out_attr0[0].wwww).z; + reg_tmp15.x = (vs_out_attr3[0].zzzz).x; + return true; + } + default: return false; + } + } + return false; +} +bool sub_1() { + reg_tmp0 = vs_out_attr3[0].xyzz; + reg_tmp0.w = (uniforms.f[81].xxxx).w; + reg_tmp0 = mul_s(reg_tmp0, vs_out_attr4[0].wwww); + return false; +} +bool sub_2() { + reg_tmp0.xyz = (vs_out_attr4[0].xyzz).xyz; + reg_tmp1.xyz = (vs_out_attr3[0].xyzz).xyz; + reg_tmp2.xyz = (mul_s(reg_tmp0.yzxx, reg_tmp1.zxyy)).xyz; + reg_tmp2.xyz = (fma_s(-reg_tmp1.yzxx, reg_tmp0.zxyy, reg_tmp2)).xyz; + reg_tmp2.w = (uniforms.f[81].xxxx).w; + reg_tmp0.x = dot_s(reg_tmp2, reg_tmp2); + reg_tmp0.x = rsq_s(reg_tmp0.x); + reg_tmp0 = mul_s(reg_tmp2, reg_tmp0.xxxx); + reg_tmp0.xyz = (mul_s(reg_tmp0.xyzz, vs_out_attr4[0].wwww)).xyz; + reg_tmp7.x = (vs_out_attr5[0].zzzz).x; + reg_tmp7.y = (vs_out_attr6[0].zzzz).y; + reg_tmp7.z = (vs_out_attr7[0].zzzz).z; + reg_tmp7.xyz = (mul_s(reg_tmp7.xyzz, reg_tmp15.zzzz)).xyz; + return false; +} +bool sub_14() { + setemit(0u, false, false); + emit(); + return false; +} +bool sub_15() { + setemit(1u, false, false); + emit(); + return false; +} +bool sub_12() { + setemit(2u, true, false); + emit(); + return false; +} +bool sub_13() { + setemit(0u, true, true); + emit(); + return false; +} +bool sub_9() { + setemit(1u, true, false); + emit(); + return false; +} +bool sub_10() { + setemit(2u, true, true); + emit(); + return false; +} +bool sub_6() { + setemit(0u, true, false); + emit(); + return false; +} +bool sub_7() { + setemit(1u, true, true); + emit(); + return false; +} +bool sub_3() { + reg_tmp1.xy = (reg_tmp15.xxxx).xy; + conditional_code = lessThan(uniforms.f[81].xx, reg_tmp1.xy); + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + output_buffer.attributes[1] = vs_out_attr1[0]; + return false; +} +bool sub_4() { + reg_tmp5.xyz = (vs_out_attr0[0].xyzz + reg_tmp6.xyzz).xyz; + reg_tmp5.w = (uniforms.f[81].zzzz).w; + output_buffer.attributes[0].x = dot_s(reg_tmp5, reg_tmp11); + output_buffer.attributes[0].y = dot_s(reg_tmp5, reg_tmp12); + output_buffer.attributes[0].z = dot_s(reg_tmp5, reg_tmp13); + output_buffer.attributes[0].w = dot_s(reg_tmp5, reg_tmp14); + return false; +} +bool sub_5() { + reg_tmp5.xyz = (vs_out_attr0[0].xyzz + reg_tmp6.xyzz).xyz; + reg_tmp5.w = (uniforms.f[81].zzzz).w; + output_buffer.attributes[0].x = dot_s(reg_tmp5, reg_tmp11); + output_buffer.attributes[0].y = dot_s(reg_tmp5, reg_tmp12); + reg_tmp1.w = dot_s(reg_tmp5, reg_tmp14); + reg_tmp2.xyz = (reg_tmp7.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp2.w = (uniforms.f[81].zzzz).w; + reg_tmp3.w = dot_s(reg_tmp2, reg_tmp14); + reg_tmp3.z = dot_s(reg_tmp2, -reg_tmp13); + reg_tmp3.z = (mul_s(reg_tmp1.wwww, reg_tmp3.zzzz)).z; + reg_tmp2 = vec4(rcp_s(reg_tmp3.w)); + output_buffer.attributes[0].z = (mul_s(reg_tmp3.zzzz, reg_tmp2.zzzz)).z; + output_buffer.attributes[0].w = (reg_tmp1.wwww).w; + return false; +} +bool sub_11() { + reg_tmp15.w = (uniforms.f[81].zzzz + reg_tmp15.wwww).w; + return false; +} +bool sub_8() { + reg_tmp15.w = (uniforms.f[81].zzzz).w; + return false; +} +// reference: D8D6DD66A6182D0A, 4BDB22C6C8A27B8E +// shader: 8B31, E4B638D2CB80E491 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; +out vec4 vs_out_attr7; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr7 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + uint jmp_to = 0u; + while (true) { + switch (jmp_to) { + case 0u: { + vs_out_attr0.xyz = (vs_in_reg0.xyzz).xyz; + vs_out_attr1 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + reg_tmp1.xy = (vs_in_reg4.xxxx).xy; + conditional_code = lessThan(uniforms.f[89].ww, reg_tmp1.xy); + if (conditional_code.x) { + { jmp_to = 41u; break; } + } + vs_out_attr0.w = (uniforms.f[90].wwww).w; + reg_tmp0 = uniforms.f[5].wzyx; + conditional_code = greaterThan(uniforms.f[6].wz, reg_tmp0.xy); + if (conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + reg_tmp0 = uniforms.f[5].wzyx; + conditional_code = greaterThan(uniforms.f[6].wz, reg_tmp0.xy); + if (conditional_code.y) { + sub_3(); + } else { + sub_4(); + } + vs_out_attr3.w = (vs_in_reg4.xxxx).w; + reg_tmp2.x = (uniforms.f[89].xxxx + vs_in_reg2.zzzz).x; + reg_tmp3 = vec4(rcp_s(uniforms.f[91].w)); + reg_tmp4.x = (uniforms.f[89].xxxx + vs_in_reg2.wwww).x; + reg_tmp4.x = (mul_s(reg_tmp4.xxxx, reg_tmp3.xxxx)).x; + reg_tmp2.x = (reg_tmp2.xxxx + reg_tmp4.xxxx).x; + reg_tmp2.x = (mul_s(uniforms.f[89].zzzz, reg_tmp2.xxxx)).x; + reg_tmp3.xyz = (-uniforms.f[8].wzyx + vs_in_reg0.xyzz).xyz; + vs_out_attr4.xyz = (reg_tmp3.xyzz).xyz; + vs_out_attr4.w = (reg_tmp2.xxxx).w; + vs_out_attr5 = uniforms.f[9].wzyx; + vs_out_attr6 = uniforms.f[10].wzyx; + vs_out_attr7 = uniforms.f[11].wzyx; + return true; + } + case 41u: { + vs_out_attr0.w = (mul_s(uniforms.f[13].wwww, vs_in_reg2.zzzz)).w; + reg_tmp0 = uniforms.f[5].wzyx; + conditional_code = greaterThan(uniforms.f[6].wz, reg_tmp0.xy); + vs_out_attr2 = uniforms.f[90].wwww; + vs_out_attr3.xy = (uniforms.f[90].wwww).xy; + vs_out_attr3.w = (uniforms.f[89].yyyy).w; + if (conditional_code.y) { + sub_5(); + } else { + sub_6(); + } + return true; + } + default: return false; + } + } + return false; +} +bool sub_1() { + reg_tmp3.xy = (vs_in_reg2.xyyy).xy; + reg_tmp3.z = (vs_in_reg3.xxxx).z; + reg_tmp3.w = (vs_in_reg3.yyyy).w; + reg_tmp3 = mul_s(uniforms.f[7].wzwz, reg_tmp3); + reg_tmp3.y = (uniforms.f[90].xxxx + -reg_tmp3.yyyy).y; + reg_tmp3.w = (uniforms.f[90].xxxx + -reg_tmp3.wwww).w; + vs_out_attr2 = reg_tmp3; + return false; +} +bool sub_2() { + vs_out_attr2 = uniforms.f[90].wwww; + return false; +} +bool sub_3() { + reg_tmp3.xyz = (vs_in_reg4.yzww).xyz; + vs_out_attr3.xyz = (mul_s(uniforms.f[90].zzzz, reg_tmp3.xyzz)).xyz; + return false; +} +bool sub_4() { + reg_tmp3.xy = (mul_s(uniforms.f[90].zzzz, vs_in_reg4.yzww)).xy; + vs_out_attr3.x = (mul_s(-uniforms.f[95].wwww, reg_tmp3.yyyy)).x; + vs_out_attr3.y = (reg_tmp3.xxxx).y; + vs_out_attr3.z = (uniforms.f[90].wwww).z; + return false; +} +bool sub_5() { + vs_out_attr3.z = (uniforms.f[90].wwww).z; + vs_out_attr4 = uniforms.f[0].wzyx; + vs_out_attr5 = uniforms.f[1].wzyx; + vs_out_attr6 = uniforms.f[2].wzyx; + vs_out_attr7 = uniforms.f[3].wzyx; + return false; +} +bool sub_6() { + vs_out_attr3.z = (uniforms.f[90].xxxx).z; + vs_out_attr4 = uniforms.f[14].wzyx; + vs_out_attr5 = uniforms.f[15].wzyx; + vs_out_attr6 = uniforms.f[16].wzyx; + vs_out_attr7 = uniforms.f[17].wzyx; + return false; +} +// reference: 6F83F52144B5D170, E4B638D2CB80E491 +// shader: 8B30, 7A2A9F5E151699CA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4609680C85818097, 7A2A9F5E151699CA +// program: E4B638D2CB80E491, 4BDB22C6C8A27B8E, 7A2A9F5E151699CA +// shader: 8B31, 79B4E5D7AC154F19 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp1 = vec4(lessThan(vs_in_reg0.xyyy, -vs_in_reg0.xyyy)); + reg_tmp2 = vec4(lessThan(-vs_in_reg0.xyyy, vs_in_reg0.xyyy)); + reg_tmp0 = reg_tmp2 + -reg_tmp1; + reg_tmp0.zw = (uniforms.f[90].wzwz).zw; + vs_out_attr0 = reg_tmp0; + reg_tmp1 = abs(vs_in_reg0.xyyy); + reg_tmp11.x = rcp_s(reg_tmp1.x); + reg_tmp11.y = rcp_s(reg_tmp1.y); + vs_out_attr1 = mul_s(vs_in_reg0.zwzw, reg_tmp11.xyxy); + return true; +} +// reference: FEB574DB55FF2CAC, 79B4E5D7AC154F19 +// shader: 8B30, ED54FBE93FC6D7EE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rrr) + (const_color[0].ggg), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(vec3(dot((last_tex_env_out.rgb) - vec3(0.5), (const_color[1].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_1 = color_output_1[0]; +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(vec3(dot((combiner_buffer.rgb) - vec3(0.5), (const_color[2].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) - (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp(vec3(dot((combiner_buffer.rgb) - vec3(0.5), (const_color[3].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.r) - (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((combiner_buffer.aaa) * (const_color[4].rgb) + (last_tex_env_out.aaa) * (vec3(1.0) - (const_color[4].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) - (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb) + (last_tex_env_out.aaa) * (vec3(1.0) - (const_color[5].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5 * 2.0, alpha_output_5 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DE3D45FDE265C750, ED54FBE93FC6D7EE +// program: 79B4E5D7AC154F19, 6B49BF5FD5349480, ED54FBE93FC6D7EE +// shader: 8B30, 71DBA48A30815B8C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BEDBD3B5E7C98459, 71DBA48A30815B8C +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 71DBA48A30815B8C +// shader: 8B31, 5CC7BD0835B1517A + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; +layout(location = 9) in vec4 vs_in_reg9; +layout(location = 10) in vec4 vs_in_reg10; +layout(location = 11) in vec4 vs_in_reg11; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp2 = mul_s(uniforms.f[95].wwzz, vs_in_reg3); + reg_tmp1 = vs_in_reg0.xyzz; + reg_tmp1.w = (uniforms.f[94].wwww).w; + if (uniforms.b[14]) { + sub_1(); + } + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = mul_s(uniforms.f[6 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp14 = mul_s(uniforms.f[7 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp15 = mul_s(uniforms.f[8 + address_registers.x].wzyx, reg_tmp2.zzzz); + reg_tmp13 = fma_s(reg_tmp2.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + if (uniforms.b[11]) { + sub_2(); + } + reg_tmp2.x = dot_3(vs_in_reg1.xyz, reg_tmp13.xyz); + reg_tmp2.y = dot_3(vs_in_reg1.xyz, reg_tmp14.xyz); + reg_tmp2.z = dot_3(vs_in_reg1.xyz, reg_tmp15.xyz); + reg_tmp8.x = dot_s(reg_tmp1, reg_tmp13); + reg_tmp8.y = dot_s(reg_tmp1, reg_tmp14); + reg_tmp8.z = dot_s(reg_tmp1, reg_tmp15); + reg_tmp8.w = (uniforms.f[94].wwww).w; + reg_tmp3.x = dot_3(uniforms.f[78].wzy, reg_tmp2.xyz); + reg_tmp3.y = dot_3(uniforms.f[79].wzy, reg_tmp2.xyz); + reg_tmp3.z = dot_3(uniforms.f[80].wzy, reg_tmp2.xyz); + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp8); + reg_tmp9.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + reg_tmp10 = vs_in_reg2.xyyy; + reg_tmp10.zw = (uniforms.f[95].yxyx).zw; + reg_tmp9.w = (uniforms.f[94].wwww).w; + reg_tmp9.x = rsq_s(reg_tmp9.x); + vs_out_attr1.xz = vec2(dot_s(uniforms.f[82].wzyx, reg_tmp10)); + vs_out_attr1.yw = vec2(dot_s(uniforms.f[83].wzyx, reg_tmp10)); + vs_out_attr5.xz = vec2(dot_s(uniforms.f[82].wzyx, reg_tmp10)); + vs_out_attr5.yw = vec2(dot_s(uniforms.f[83].wzyx, reg_tmp10)); + reg_tmp9.xyz = (mul_s(reg_tmp3, reg_tmp9.xxxx)).xyz; + if (uniforms.b[9]) { + sub_4(); + } else { + sub_5(); + } + conditional_code = equal(-uniforms.f[94].ww, reg_tmp9.zz); + reg_tmp4 = uniforms.f[94].wwww + reg_tmp9.zzzz; + vs_out_attr3.x = dot_s(-uniforms.f[78].wzyx, reg_tmp8); + vs_out_attr3.y = dot_s(-uniforms.f[79].wzyx, reg_tmp8); + vs_out_attr3.zw = vec2(dot_s(-uniforms.f[80].wzyx, reg_tmp8)); + reg_tmp4 = mul_s(uniforms.f[94].xxxx, reg_tmp4); + vs_out_attr2.w = (uniforms.f[93].wwww).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].xxxx, reg_tmp9); + if (!conditional_code.x) { + sub_6(); + } else { + sub_7(); + } + vs_out_attr4.xyz = (mul_s(uniforms.f[94].xxxx, reg_tmp12)).xyz; + vs_out_attr4.w = (mul_s(uniforms.f[87].xxxx, reg_tmp12.wwww)).w; + return true; +} +bool sub_1() { + reg_tmp1.xyz = (fma_s(vs_in_reg8.xyzz, uniforms.f[5].wwww, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg9.xyzz, uniforms.f[5].zzzz, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg10.xyzz, uniforms.f[5].yyyy, reg_tmp1)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg11.xyzz, uniforms.f[5].xxxx, reg_tmp1)).xyz; + return false; +} +bool sub_2() { + reg_tmp2 = mul_s(uniforms.f[95].wwzz, vs_in_reg5); + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = fma_s(reg_tmp2.zzzz, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.zzzz, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.zzzz, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp2.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp2.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp2.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + if (uniforms.b[12]) { + sub_3(); + } + return false; +} +bool sub_3() { + reg_tmp2 = mul_s(uniforms.f[95].wwww, vs_in_reg6); + reg_tmp3 = mul_s(uniforms.f[95].zzzz, vs_in_reg7); + address_registers.xy = ivec2(reg_tmp2.xy); + reg_tmp13 = fma_s(reg_tmp3.xxxx, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.xxxx, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.xxxx, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp3.yyyy, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.yyyy, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.yyyy, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + address_registers.xy = ivec2(reg_tmp2.zw); + reg_tmp13 = fma_s(reg_tmp3.zzzz, uniforms.f[6 + address_registers.x].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.zzzz, uniforms.f[7 + address_registers.x].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.zzzz, uniforms.f[8 + address_registers.x].wzyx, reg_tmp15); + reg_tmp13 = fma_s(reg_tmp3.wwww, uniforms.f[6 + address_registers.y].wzyx, reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.wwww, uniforms.f[7 + address_registers.y].wzyx, reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.wwww, uniforms.f[8 + address_registers.y].wzyx, reg_tmp15); + return false; +} +bool sub_4() { + reg_tmp5 = mul_s(uniforms.f[94].zzzz, vs_in_reg4.xyzz); + reg_tmp1 = uniforms.f[94].yyyy + -reg_tmp5; + reg_tmp2.x = rcp_s(reg_tmp1.x); + reg_tmp2.y = rcp_s(reg_tmp1.y); + reg_tmp2.z = rcp_s(reg_tmp1.z); + reg_tmp12.xyz = (mul_s(reg_tmp5, reg_tmp2)).xyz; + reg_tmp12.w = (mul_s(uniforms.f[94].zzzz, vs_in_reg4.wwww)).w; + return false; +} +bool sub_5() { + reg_tmp12.x = dot_s(uniforms.f[84].wzyx, reg_tmp9); + reg_tmp12.y = dot_s(uniforms.f[85].wzyx, reg_tmp9); + reg_tmp12.z = dot_s(uniforms.f[86].wzyx, reg_tmp9); + reg_tmp12.w = (uniforms.f[94].wwww).w; + return false; +} +bool sub_6() { + vs_out_attr2.z = rcp_s(reg_tmp4.x); + vs_out_attr2.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_7() { + vs_out_attr2.x = (uniforms.f[94].wwww).x; + vs_out_attr2.yzw = (uniforms.f[93].wwww).yzw; + return false; +} +// reference: 506C74DFEA43E7D3, 5CC7BD0835B1517A +// shader: 8B30, 297727BBE447797C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BACD22F75A4F2AC2, 297727BBE447797C +// program: 5CC7BD0835B1517A, A29BAEF5C1BA44F2, 297727BBE447797C +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, 71DBA48A30815B8C +// program: 309177F344E6BF06, DDD543B7EFD7D3AC, 7A2A9F5E151699CA +// reference: D4F4BEF94A4476CD, 7974F3663498993D +// program: A226445F0A79E9EE, 23B87C5B1F79AE3C, 7974F3663498993D +// shader: 8B30, 44776903C2844A30 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4609680CDF9A30CA, 44776903C2844A30 +// program: 309177F344E6BF06, DDD543B7EFD7D3AC, 44776903C2844A30 +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B31, E45928C189BB7782 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + uint jmp_to = 0u; + while (true) { + switch (jmp_to) { + case 0u: { + reg_tmp14.z = (mul_s(uniforms.f[5].wwww, vs_in_reg2.zzzz)).z; + reg_tmp15 = uniforms.f[6].wzyx; + reg_tmp0 = vs_in_reg0.xyzz; + reg_tmp0.w = (uniforms.f[95].wwww).w; + vs_out_attr1 = mul_s(uniforms.f[90].zzzz, vs_in_reg1); + conditional_code = greaterThan(uniforms.f[7].wz, reg_tmp15.xy); + if (conditional_code.y) { + { jmp_to = 20u; break; } + } + reg_tmp0.z = (reg_tmp0.zzzz + reg_tmp14.zzzz).z; + vs_out_attr0.x = dot_s(uniforms.f[8].wzyx, reg_tmp0); + vs_out_attr0.y = dot_s(uniforms.f[9].wzyx, reg_tmp0); + vs_out_attr0.z = dot_s(uniforms.f[10].wzyx, reg_tmp0); + vs_out_attr0.w = dot_s(uniforms.f[11].wzyx, reg_tmp0); + if (conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + return true; + } + case 20u: { + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp4.x = (mul_s(uniforms.f[12].yyyy, reg_tmp14.zzzz)).x; + reg_tmp4.y = (mul_s(uniforms.f[13].yyyy, reg_tmp14.zzzz)).y; + reg_tmp4.z = (mul_s(uniforms.f[14].yyyy, reg_tmp14.zzzz)).z; + reg_tmp0.xyz = (reg_tmp4.xyzz + reg_tmp0.xyzz).xyz; + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp0); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp0); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp0); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp0); + return true; + } + default: return false; + } + } + return false; +} +bool sub_1() { + reg_tmp1.xy = (vs_in_reg2.xyyy).xy; + reg_tmp1.xy = (mul_s(uniforms.f[90].yyyy, reg_tmp1.xyyy)).xy; + reg_tmp1.y = (uniforms.f[95].wwww + -reg_tmp1.yyyy).y; + vs_out_attr2 = reg_tmp1.xyyy; + return false; +} +bool sub_2() { + vs_out_attr2 = uniforms.f[90].wwww; + return false; +} +bool sub_3() { + reg_tmp5.xy = (vs_in_reg2.xyyy).xy; + reg_tmp5.xy = (mul_s(uniforms.f[90].yyyy, reg_tmp5.xyyy)).xy; + reg_tmp5.y = (uniforms.f[95].wwww + -reg_tmp5.yyyy).y; + vs_out_attr2 = reg_tmp5.xyyy; + return false; +} +bool sub_4() { + vs_out_attr2 = uniforms.f[90].wwww; + return false; +} +// reference: 2D9C866F9D939A31, E45928C189BB7782 +// program: E45928C189BB7782, 219384019281D7FD, 411AA67B9C4AA6C7 +// program: E45928C189BB7782, 219384019281D7FD, 44776903C2844A30 +// shader: 8B30, F774779BBD8E6096 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - secondary_fragment_color.aaa) + (const_color[3].rgb) * (vec3(1.0) - (vec3(1.0) - secondary_fragment_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 055EAA5015F760CB, F774779BBD8E6096 +// program: 5CC7BD0835B1517A, A29BAEF5C1BA44F2, F774779BBD8E6096 +// reference: 2B886BCB68D12F1A, 877EA791AA03C3C0 +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, 877EA791AA03C3C0 +// reference: BEDBD3B5631D759F, 877EA791AA03C3C0 +// shader: 8B30, 4E8D8A49AFC9A1EC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B224C165FCA388D0, 4E8D8A49AFC9A1EC +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 4E8D8A49AFC9A1EC +// shader: 8B30, EA721EDD4221079F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 58CAB345E536E80B, EA721EDD4221079F +// program: 7EE366499F4A080E, B99A1F5927E7BF45, EA721EDD4221079F +// shader: 8B30, 9CC71355BFDFA6E2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 58CAB3451AB72F65, 9CC71355BFDFA6E2 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 9CC71355BFDFA6E2 +// shader: 8B30, 6E2D24D7557911DC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[6].position + view); +spot_dir = light_src[6].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[6].diffuse * dot_product) + light_src[6].ambient) * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[6].specular_0) + (refl_value * light_src[6].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE5F93D67B9ED975, 6E2D24D7557911DC +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 6E2D24D7557911DC +// shader: 8B30, 858B3CFA95220147 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[6].position + view); +spot_dir = light_src[6].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[6].diffuse * dot_product) + light_src[6].ambient) * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[6].specular_0) + (refl_value * light_src[6].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CA496294C61877EE, 858B3CFA95220147 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 858B3CFA95220147 +// shader: 8B30, 6969E9C06F34C939 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[6].position + view); +spot_dir = light_src[6].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[6].diffuse * dot_product) + light_src[6].ambient) * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[6].specular_0) + (refl_value * light_src[6].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 24B1E1F6620BB9AE, 6969E9C06F34C939 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 6969E9C06F34C939 +// shader: 8B30, D2678E5E4F13AE42 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F2760F80A823DEDE, D2678E5E4F13AE42 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, D2678E5E4F13AE42 +// shader: 8B30, C6B68E1201B48B54 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 18987DA0B1B6BE05, C6B68E1201B48B54 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, C6B68E1201B48B54 +// shader: 8B30, F10D64245BB87D12 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B63230274125264B, F10D64245BB87D12 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, F10D64245BB87D12 +// shader: 8B30, 5EB4C771F2DE8F2B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 867BE95A1AB72F65, 5EB4C771F2DE8F2B +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 5EB4C771F2DE8F2B +// shader: 8B30, D0DFD890B7B33F09 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4D3F7EE15A4F2AC2, D0DFD890B7B33F09 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, D0DFD890B7B33F09 +// shader: 8B30, DF90EE487F6AB0ED +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 49298FA3E7C98459, DF90EE487F6AB0ED +// program: 270E94B55796EDB7, B99A1F5927E7BF45, DF90EE487F6AB0ED +// shader: 8B30, 212B12454E345657 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 44363F0AB092F0F6, 212B12454E345657 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 212B12454E345657 +// shader: 8B30, A2D5028A5CC13822 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 86430F02E7C98459, A2D5028A5CC13822 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, A2D5028A5CC13822 +// program: 5CC7BD0835B1517A, A29BAEF5C1BA44F2, 4E8D8A49AFC9A1EC +// shader: 8B30, 21866DEB634BC6D3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - secondary_fragment_color.aaa) + (const_color[3].rgb) * (vec3(1.0) - (vec3(1.0) - secondary_fragment_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1340BE7E520E6F6D, 21866DEB634BC6D3 +// program: 5CC7BD0835B1517A, A29BAEF5C1BA44F2, 21866DEB634BC6D3 +// shader: 8B30, 710FA45137FA54A7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3D967FE52F2820BC, 710FA45137FA54A7 +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, 710FA45137FA54A7 +// shader: 8DD9, 36482B4E295C6EDF + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = vtx.attributes[3].z; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E0848BBF5E0215D9, 36482B4E295C6EDF +// shader: 8B31, 62717CCBAEE1596E + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp1 = vs_in_reg0.xyzz; + reg_tmp1.w = (uniforms.f[95].wwww).w; + reg_tmp8.x = dot_s(uniforms.f[5].wzyx, reg_tmp1); + reg_tmp8.y = dot_s(uniforms.f[6].wzyx, reg_tmp1); + reg_tmp8.z = dot_s(uniforms.f[7].wzyx, reg_tmp1); + reg_tmp8.w = (uniforms.f[95].wwww).w; + if (uniforms.b[0]) { + sub_1(); + } else { + sub_4(); + } + if (uniforms.b[9]) { + sub_5(); + } else { + sub_6(); + } + vs_out_attr1.xyz = (mul_s(uniforms.f[94].wwww, reg_tmp0)).xyz; + vs_out_attr1.w = (reg_tmp0).w; + reg_tmp3 = vs_in_reg2.xyyy; + reg_tmp3.z = (uniforms.f[95].zzzz).z; + reg_tmp3.w = (uniforms.f[95].wwww).w; + reg_tmp4.xz = vec2(dot_s(uniforms.f[17].wzyx, reg_tmp3)); + reg_tmp4.yw = vec2(dot_s(uniforms.f[18].wzyx, reg_tmp3)); + vs_out_attr2 = reg_tmp4; + vs_out_attr3.x = dot_s(uniforms.f[19].wzyx, reg_tmp8); + vs_out_attr3.y = dot_s(uniforms.f[20].wzyx, reg_tmp8); + vs_out_attr3.zw = vec2(dot_s(uniforms.f[21].wzyx, reg_tmp8)); + return true; +} +bool sub_1() { + reg_tmp9 = uniforms.f[4].wzyx; + conditional_code = lessThanEqual(uniforms.f[95].zz, reg_tmp9.xx); + if (conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + return false; +} +bool sub_2() { + vs_out_attr0.x = dot_s(uniforms.f[8].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[9].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[10].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[11].wzyx, reg_tmp8); + return false; +} +bool sub_3() { + vs_out_attr0.x = dot_s(uniforms.f[12].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[13].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[14].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[15].wzyx, reg_tmp8); + return false; +} +bool sub_4() { + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp8); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp8); + vs_out_attr0.z = dot_s(-uniforms.f[2].wzyx, reg_tmp8); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp8); + return false; +} +bool sub_5() { + reg_tmp5 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + reg_tmp1 = uniforms.f[95].xxxx + -reg_tmp5; + reg_tmp2.x = rcp_s(reg_tmp1.x); + reg_tmp2.y = rcp_s(reg_tmp1.y); + reg_tmp2.z = rcp_s(reg_tmp1.z); + reg_tmp0.xyz = (mul_s(reg_tmp5, reg_tmp2)).xyz; + reg_tmp0.w = (reg_tmp5.wwww).w; + reg_tmp0 = mul_s(uniforms.f[16].wzyx, reg_tmp0); + return false; +} +bool sub_6() { + reg_tmp0 = uniforms.f[16].wzyx; + return false; +} +// reference: D07428F494C33EF2, 62717CCBAEE1596E +// shader: 8B30, A67039B44C511A38 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68BE49DB53, A67039B44C511A38 +// program: 62717CCBAEE1596E, 36482B4E295C6EDF, A67039B44C511A38 +// shader: 8B30, 368343E4872EF846 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BEDBD3B50B7E6F5A, 368343E4872EF846 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 368343E4872EF846 +// shader: 8B30, 8248F761E8AD9131 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A7D10CC1AF6DA11A, 8248F761E8AD9131 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 8248F761E8AD9131 +// shader: 8B30, 23D502FC26D85786 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((secondary_fragment_color.aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D2426860B7E6F5A, 23D502FC26D85786 +// program: 270E94B55796EDB7, B99A1F5927E7BF45, 23D502FC26D85786 +// shader: 8B30, C3E154630569B198 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[6].position + view); +spot_dir = light_src[6].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[6].diffuse * dot_product) + light_src[6].ambient) * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[6].specular_0) + (refl_value * light_src[6].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(22, clamp(light_src[6].dist_atten_scale * length(-view - light_src[6].position) + light_src[6].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE5F93D697293276, C3E154630569B198 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, C3E154630569B198 +// shader: 8B30, 376E355BD03305B3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 44363F0A5C251BF5, 376E355BD03305B3 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 376E355BD03305B3 +// shader: 8B30, A9AA8727F2CA1EA1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AED84D2A45B07B2E, A9AA8727F2CA1EA1 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, A9AA8727F2CA1EA1 +// shader: 8B30, 487BB4DD8C75868F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 58CAB345F600C466, 487BB4DD8C75868F +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 487BB4DD8C75868F +// shader: 8B30, 14F9769A96C4A000 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B224C165101463D3, 14F9769A96C4A000 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 14F9769A96C4A000 +// shader: 8B30, C678AA9C007F3050 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F2760F80449435DD, C678AA9C007F3050 +// program: 7EE366499F4A080E, B99A1F5927E7BF45, C678AA9C007F3050 +// shader: 8B30, AEEE721E425549F3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - secondary_fragment_color.aaa) + (const_color[3].rgb) * (vec3(1.0) - (vec3(1.0) - secondary_fragment_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 055EAA50F9408BC8, AEEE721E425549F3 +// program: 5CC7BD0835B1517A, A29BAEF5C1BA44F2, AEEE721E425549F3 +// shader: 8B30, 5DB59807762FDF92 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = texcolor0; +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(normal, normalize(half_vector)), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].aaa) + (const_color[1].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (primary_fragment_color.rgb), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.aaa) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(1.0)) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((combiner_buffer.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2B886BCB8466C419, 5DB59807762FDF92 +// program: 22186AF454C341E4, A29BAEF5C1BA44F2, 5DB59807762FDF92 +// shader: 8B30, 76073C74C0A1879B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (refl_value * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[3].position + view); +spot_dir = light_src[3].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[3].diffuse * dot_product) + light_src[3].ambient) * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[3].specular_0) + (refl_value * light_src[3].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(19, clamp(light_src[3].dist_atten_scale * length(-view - light_src[3].position) + light_src[3].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[4].position + view); +spot_dir = light_src[4].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[4].diffuse * dot_product) + light_src[4].ambient) * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[4].specular_0) + (refl_value * light_src[4].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(20, clamp(light_src[4].dist_atten_scale * length(-view - light_src[4].position) + light_src[4].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[5].position + view); +spot_dir = light_src[5].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[5].diffuse * dot_product) + light_src[5].ambient) * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[5].specular_0) + (refl_value * light_src[5].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(21, clamp(light_src[5].dist_atten_scale * length(-view - light_src[5].position) + light_src[5].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 58CAB34509810308, 76073C74C0A1879B +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 76073C74C0A1879B +// shader: 8B30, 3B1367380A54499F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rrr) + (const_color[0].ggg), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(vec3(dot((last_tex_env_out.rgb) - vec3(0.5), (const_color[1].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_1 = color_output_1[0]; +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(vec3(dot((combiner_buffer.rgb) - vec3(0.5), (const_color[2].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) + (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp(vec3(dot((combiner_buffer.rgb) - vec3(0.5), (const_color[3].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.r) + (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((combiner_buffer.aaa) * (const_color[4].rgb) + (last_tex_env_out.aaa) * (vec3(1.0) - (const_color[4].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) + (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb) + (last_tex_env_out.aaa) * (vec3(1.0) - (const_color[5].rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FC3997D9C4D2CB6D, 3B1367380A54499F +// program: 79B4E5D7AC154F19, 6B49BF5FD5349480, 3B1367380A54499F +// shader: 8B30, CEE6A8A19928F7CF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5B216ACFFCE3678F, CEE6A8A19928F7CF +// program: 7EE366499F4A080E, B99A1F5927E7BF45, CEE6A8A19928F7CF +// shader: 8B30, 260BF812931108BE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5B216ACF10548C8C, 260BF812931108BE +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 260BF812931108BE +// shader: 8B30, 818C128B7E7AA1DD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = (lut_scale_rr * LookupLightingLUTUnsigned(6, max(dot(light_vector, normal), 0.0))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (refl_value * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (texcolor2.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((const_color[2].a) * (secondary_fragment_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (last_tex_env_out.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor1.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B1CF18EF09C1EC57, 818C128B7E7AA1DD +// program: 7EE366499F4A080E, B99A1F5927E7BF45, 818C128B7E7AA1DD +// reference: 8D242686631D759F, F9D61D3C0DEA79AA +// reference: FC7C509996560D3F, A67039B44C511A38 diff --git a/cache/0004000000053700.shader.meta b/cache/0004000000053700.shader.meta new file mode 100644 index 00000000000..11c7e890e52 --- /dev/null +++ b/cache/0004000000053700.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 94 +reference: 101 +program: 73 diff --git a/cache/000400000005DE00.shader b/cache/000400000005DE00.shader new file mode 100644 index 00000000000..11077f5e8bb --- /dev/null +++ b/cache/000400000005DE00.shader @@ -0,0 +1,2054 @@ +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B31, B2A4DF9B10CB7385 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = uniforms.f[95].xxxz; + reg_tmp0.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp0.xy = (uniforms.f[70].xyyy + reg_tmp0.xyyy).xy; + reg_tmp1 = reg_tmp0; + reg_tmp1.x = dot_s(uniforms.f[4], reg_tmp0); + reg_tmp1.y = dot_s(uniforms.f[5], reg_tmp0); + reg_tmp0.x = dot_s(uniforms.f[0], reg_tmp1); + reg_tmp0.y = dot_s(uniforms.f[1], reg_tmp1); + reg_tmp0.x = (-reg_tmp0.xxxx).x; + reg_tmp0 = reg_tmp0.yxzw; + vs_out_attr0 = reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[94].yyyy, vs_in_reg2); + vs_out_attr1 = mul_s(uniforms.f[60], reg_tmp0); + vs_out_attr2 = vs_in_reg1.xyxy; + return true; +} +// reference: B29C626A5213A9BE, B2A4DF9B10CB7385 +// shader: 8B30, 78572544498D44D2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6639CA4C98688439, 78572544498D44D2 +// program: B2A4DF9B10CB7385, 219384019281D7FD, 78572544498D44D2 +// shader: 8B30, 19F3A98C2D1790AA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C474CA8E95B78B0B, 19F3A98C2D1790AA +// program: B2A4DF9B10CB7385, 219384019281D7FD, 19F3A98C2D1790AA +// reference: 0000000098688439, 78572544498D44D2 +// shader: 8DD9, 9A2BCD15773D44BE + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7FA618D8C5CEE1F2, 9A2BCD15773D44BE +// shader: 8B31, C7F39283A817CF09 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp12 = uniforms.f[95].xxxz; + reg_tmp15 = uniforms.f[95].xxxz; + reg_tmp14 = uniforms.f[95].xxxz; + if (uniforms.b[3]) { + sub_1(); + } else { + sub_2(); + } + vs_out_attr2 = uniforms.f[16] + vs_in_reg1.xyyy; + reg_tmp0 = mul_s(uniforms.f[95].wwww, vs_in_reg3.zyxw); + if (uniforms.b[2]) { + sub_5(); + } + reg_tmp0 = mul_s(uniforms.f[14], reg_tmp0); + if (uniforms.b[1]) { + sub_6(); + } + vs_out_attr1 = reg_tmp0; + return true; +} +bool sub_1() { + reg_tmp12 = uniforms.f[95].xxxz; + reg_tmp12.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp12.x = (-reg_tmp12.xxxx).x; + reg_tmp12 = reg_tmp12.yxzw; + vs_out_attr0 = reg_tmp12; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + if (uniforms.b[0]) { + sub_3(); + } else { + sub_4(); + } + reg_tmp15.x = dot_s(uniforms.f[4], reg_tmp12); + reg_tmp15.y = dot_s(uniforms.f[5], reg_tmp12); + reg_tmp15.z = dot_s(uniforms.f[6], reg_tmp12); + reg_tmp15.w = dot_s(uniforms.f[7], reg_tmp12); + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp15); + vs_out_attr3 = -reg_tmp15; + return false; +} +bool sub_3() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg5.xyyy)).xy; + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp1 = uniforms.f[20 + address_registers.y]; + reg_tmp2 = uniforms.f[20 + address_registers.x] + -reg_tmp1; + reg_tmp2 = fma_s(reg_tmp2, vs_in_reg6.xxxx, reg_tmp1); + reg_tmp1 = uniforms.f[21 + address_registers.y]; + reg_tmp3 = uniforms.f[21 + address_registers.x] + -reg_tmp1; + reg_tmp3 = fma_s(reg_tmp3, vs_in_reg6.xxxx, reg_tmp1); + reg_tmp1 = uniforms.f[22 + address_registers.y]; + reg_tmp4 = uniforms.f[22 + address_registers.x] + -reg_tmp1; + reg_tmp4 = fma_s(reg_tmp4, vs_in_reg6.xxxx, reg_tmp1); + reg_tmp12.x = dot_s(vs_in_reg0, reg_tmp2); + reg_tmp12.y = dot_s(vs_in_reg0, reg_tmp3); + reg_tmp12.z = dot_s(vs_in_reg0, reg_tmp4); + return false; +} +bool sub_4() { + reg_tmp12.x = dot_s(uniforms.f[8], vs_in_reg0); + reg_tmp12.y = dot_s(uniforms.f[9], vs_in_reg0); + reg_tmp12.z = dot_s(uniforms.f[10], vs_in_reg0); + return false; +} +bool sub_5() { + reg_tmp0.xyz = (uniforms.f[93].yyyy).xyz; + return false; +} +bool sub_6() { + reg_tmp0 = mul_s(uniforms.f[15], reg_tmp0); + return false; +} +// reference: CACCAAAA12E80A13, C7F39283A817CF09 +// shader: 8B30, 1A0C335CCAEFADDC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0000000022AE5C39, 1A0C335CCAEFADDC +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 1A0C335CCAEFADDC +// shader: 8B30, 0A6018AA27C60B11 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1AC5909195B78B0B, 0A6018AA27C60B11 +// program: B2A4DF9B10CB7385, 219384019281D7FD, 0A6018AA27C60B11 +// reference: 1AC59091CCDB068A, 0A6018AA27C60B11 +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 0A6018AA27C60B11 +// shader: 8B30, 19982EBFBBD8F63F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 56891C7B574B4DF3, 19982EBFBBD8F63F +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 19982EBFBBD8F63F +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 78572544498D44D2 +// reference: 00000000C10409B8, 78572544498D44D2 +// reference: 000000007BC2D1B8, 1A0C335CCAEFADDC +// reference: C474CA8ECCDB068A, 19F3A98C2D1790AA +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 19F3A98C2D1790AA +// shader: 8B30, 9A5AF21EE287585D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) - (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 650573269CEBF582, 9A5AF21EE287585D +// program: B2A4DF9B10CB7385, 219384019281D7FD, 9A5AF21EE287585D +// shader: 8B30, 2DB864998A6BD166 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1AC590916053078E, 2DB864998A6BD166 +// program: B2A4DF9B10CB7385, 219384019281D7FD, 2DB864998A6BD166 +// reference: 1AC59091393F8A0F, 2DB864998A6BD166 +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 2DB864998A6BD166 +// shader: 8B30, 22B1E226098DF6CD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(vec3(dot((last_tex_env_out.rgb) - vec3(0.5), (const_color[3].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 96B9A01358B36109, 22B1E226098DF6CD +// program: B2A4DF9B10CB7385, 219384019281D7FD, 22B1E226098DF6CD +// shader: 8B30, 8E75232E311D5889 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(vec3(dot((last_tex_env_out.rgb) - vec3(0.5), (const_color[3].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 96B9A013AD57ED8C, 8E75232E311D5889 +// program: B2A4DF9B10CB7385, 219384019281D7FD, 8E75232E311D5889 +// reference: 56891C7B0E27C072, 19982EBFBBD8F63F +// shader: 8B30, 9428B0283AF13FD0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 000000006D8C08BC, 9428B0283AF13FD0 +// program: C7F39283A817CF09, 9A2BCD15773D44BE, 9428B0283AF13FD0 diff --git a/cache/000400000005DE00.shader.meta b/cache/000400000005DE00.shader.meta new file mode 100644 index 00000000000..f52e32cd9c4 --- /dev/null +++ b/cache/000400000005DE00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 14 +reference: 21 +program: 14 diff --git a/cache/000400000008FE00.shader b/cache/000400000008FE00.shader new file mode 100644 index 00000000000..a3a8d10018b --- /dev/null +++ b/cache/000400000008FE00.shader @@ -0,0 +1,542 @@ +// shader: 8DD9, 6ABDA25F3FF910CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z, vtx.attributes[2].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E57938FA9E46D0AE, 6ABDA25F3FF910CD +// shader: 8B31, F9543D43C2B3E096 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp10.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp10.w = (uniforms.f[92].yyyy).w; + conditional_code = equal(uniforms.f[4].xx, reg_tmp10.ww); + if (!conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp10); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp10); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp10); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp10); + vs_out_attr1 = vs_in_reg2; + vs_out_attr3 = -reg_tmp10; + vs_out_attr2 = uniforms.f[92].xxxx; + return true; +} +bool sub_1() { + reg_tmp10.x = (reg_tmp10.xxxx + vs_in_reg4.xxxx).x; + return false; +} +bool sub_2() { + reg_tmp10.x = (reg_tmp10.xxxx + -vs_in_reg4.xxxx).x; + return false; +} +// reference: BFAF50543B47F256, F9543D43C2B3E096 +// shader: 8B30, 123AEB0EDF90A3FE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E683AC5214B, 123AEB0EDF90A3FE +// program: F9543D43C2B3E096, 6ABDA25F3FF910CD, 123AEB0EDF90A3FE +// shader: 8DD9, 24CFA9CD0C9C43C4 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[4].x, vtx.attributes[4].y, vtx.attributes[4].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 8D2B248358E40AB0, 24CFA9CD0C9C43C4 +// shader: 8B31, EC3BAFA855289E1F + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp10.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp10.w = (uniforms.f[92].yyyy).w; + conditional_code = equal(uniforms.f[4].xx, reg_tmp10.ww); + if (!conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp10); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp10); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp10); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp10); + vs_out_attr1 = vs_in_reg2; + vs_out_attr2 = vs_in_reg1.xyyy; + vs_out_attr4 = -reg_tmp10; + vs_out_attr3 = uniforms.f[92].xxxx; + return true; +} +bool sub_1() { + reg_tmp10.x = (reg_tmp10.xxxx + vs_in_reg4.xxxx).x; + return false; +} +bool sub_2() { + reg_tmp10.x = (reg_tmp10.xxxx + -vs_in_reg4.xxxx).x; + return false; +} +// reference: 632F9952C2854885, EC3BAFA855289E1F +// program: EC3BAFA855289E1F, 24CFA9CD0C9C43C4, 123AEB0EDF90A3FE +// reference: 15A698DF3B47F256, F9543D43C2B3E096 +// reference: C92651D9C2854885, EC3BAFA855289E1F diff --git a/cache/000400000008FE00.shader.meta b/cache/000400000008FE00.shader.meta new file mode 100644 index 00000000000..eb7bf503b6d --- /dev/null +++ b/cache/000400000008FE00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 5 +reference: 7 +program: 2 diff --git a/cache/0004000000090700.shader b/cache/0004000000090700.shader new file mode 100644 index 00000000000..7465edc2a4f --- /dev/null +++ b/cache/0004000000090700.shader @@ -0,0 +1,21073 @@ +// shader: 8DD9, 0D30074279C2FEED + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[6].x, vtx.attributes[6].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: FC74FA4ACA1C8C74, 0D30074279C2FEED +// shader: 8B31, 7C1C6E186A32E365 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_21(); +bool sub_4(); +bool sub_9(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_10(); +bool sub_20(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_6(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_44(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_45(); +bool sub_46(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_55(); +bool sub_57(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_56(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_66(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + { + sub_1(); + } + { + sub_30(); + } + { + sub_45(); + } + { + sub_59(); + } + { + sub_66(); + } + return true; +} +bool sub_21() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_4() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_9() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_23(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_3(); + } else { + sub_7(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_4(); + } + if (uniforms.b[8]) { + sub_5(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_5() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_4(); + } + return false; +} +bool sub_7() { + if (all(conditional_code)) { + sub_8(); + } else { + sub_20(); + } + return false; +} +bool sub_8() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_9(); + } + if (uniforms.b[8]) { + sub_10(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_20() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_21(); + } + if (uniforms.b[8]) { + sub_22(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_22() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_21(); + } + return false; +} +bool sub_23() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_24(); + } else { + sub_25(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_27(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_24() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_25() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_26() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_27() { + if (all(conditional_code)) { + sub_28(); + } else { + sub_29(); + } + return false; +} +bool sub_28() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_11(); + } + return false; +} +bool sub_29() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_6() { + uint jmp_to = 212u; + while (true) { + switch (jmp_to) { + case 212u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 228u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 228u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 228u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + uint jmp_to = 229u; + while (true) { + switch (jmp_to) { + case 229u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 304u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 266u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 304u; break; } + } + } + case 266u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_12(); + } else { + sub_17(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 304u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_12() { + if (conditional_code.y) { + sub_13(); + } else { + sub_14(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_14() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_17() { + if (conditional_code.y) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_19() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_30() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_31(); + } + if (uniforms.b[12]) { + sub_33(); + } + if (uniforms.b[5]) { + sub_42(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_44(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_31() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_32(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_32() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_44() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_33() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop325 = 0u; loop325 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop325) { + sub_34(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_34() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[81 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[83 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_35(); + } else { + sub_36(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_41(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_35() { + reg_tmp6.x = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_36() { + reg_tmp4 = uniforms.f[81 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_37(); + } + reg_tmp5 = uniforms.f[82 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_38(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_37() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[83 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_38() { + reg_tmp5.x = dot_3(uniforms.f[82 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[84 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_39(); + } else { + sub_40(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_39() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_40() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[84 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_41() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[80 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_42() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_43(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_43() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_46(); + } else { + sub_52(); + } + return false; +} +bool sub_46() { + { + sub_47(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_52() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_53(); + } else { + sub_54(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_53() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_54() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + { + sub_56(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_57() { + { + sub_58(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_49(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_48() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_49() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_50(); + } else { + sub_51(); + } + return false; +} +bool sub_50() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_56() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_58() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_59() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_60(); + } else { + sub_61(); + } + return false; +} +bool sub_60() { + { + sub_47(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_61() { + if (uniforms.b[13]) { + sub_62(); + } else { + sub_65(); + } + return false; +} +bool sub_62() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_63(); + } else { + sub_64(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_63() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_64() { + { + sub_58(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_65() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_66() { + reg_tmp0.xy = (uniforms.f[10].zzzz).xy; + if (uniforms.b[11]) { + sub_67(); + } else { + sub_68(); + } + return false; +} +bool sub_67() { + { + sub_47(); + } + reg_tmp5.x = dot_s(uniforms.f[17].xywz, reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18].xywz, reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_68() { + if (uniforms.b[14]) { + sub_69(); + } else { + sub_70(); + } + return false; +} +bool sub_69() { + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp5.zw = (reg_tmp6.zwww).zw; + { + sub_58(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_70() { + vs_out_attr6 = uniforms.f[93].xxxx; + return false; +} +// reference: 64A15765A31C960B, 7C1C6E186A32E365 +// shader: 8B30, 1A48563EE40699E2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10807477801C7747, 1A48563EE40699E2 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 1A48563EE40699E2 +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B31, FC7F4467554D34E5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.x = (ivec2(vs_in_reg0.xy)).x; + reg_tmp0 = uniforms.f[6 + address_registers.x].wzyx; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (uniforms.f[5].xyxy).zw; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp2.xw = (uniforms.f[64 + address_registers.y].wwyy).xw; + reg_tmp2.yz = (uniforms.f[5].xxxx).yz; + reg_tmp4.x = dot_s(reg_tmp1, reg_tmp2); + reg_tmp2.yw = (uniforms.f[64 + address_registers.y].zzxx).yw; + reg_tmp2.xz = (uniforms.f[5].xxxx).xz; + reg_tmp4.y = dot_s(reg_tmp1, reg_tmp2); + reg_tmp4.zw = (reg_tmp1.zwzw).zw; + reg_tmp3.x = dot_s(uniforms.f[32 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.y = dot_s(uniforms.f[33 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.z = dot_s(uniforms.f[34 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp4.z = (uniforms.f[34 + address_registers.x].xxxx).z; + reg_tmp4.z = (abs(reg_tmp4.zzzz)).z; + reg_tmp4.z = (uniforms.f[4].yyyy + reg_tmp4.zzzz).z; + reg_tmp4.x = (uniforms.f[4].wwww).x; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp4.xz); + if (all(conditional_code)) { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + conditional_code = greaterThanEqual(uniforms.f[5].yy, reg_tmp0.ww); + if (all(conditional_code)) { + sub_2(); + } else { + sub_3(); + } + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_8(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_9(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_10(); + } + if (all(conditional_code)) { + sub_11(); + } + reg_tmp8 = uniforms.f[5].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop64 = 0u; loop64 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop64) { + sub_12(); + } + vs_out_attr2 = reg_tmp5; + vs_out_attr3 = reg_tmp6; + vs_out_attr4 = reg_tmp7; + return true; +} +bool sub_1() { + reg_tmp4.x = (uniforms.f[4].wwww).x; + reg_tmp4.y = (-uniforms.f[4].zzzz + reg_tmp4.zzzz).y; + reg_tmp4.z = rcp_s(reg_tmp4.z); + reg_tmp4.z = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).z; + reg_tmp3.x = (fma_s(reg_tmp4.xxxx, reg_tmp4.zzzz, reg_tmp3.xxxx)).x; + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[5].yyyy).xyz; + vs_out_attr1.w = (reg_tmp0.wwww).w; + return false; +} +bool sub_3() { + address_registers.y = (ivec2(reg_tmp0.ww)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_4(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_5(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_6(); + } + if (all(conditional_code)) { + sub_7(); + } + return false; +} +bool sub_4() { + vs_out_attr1 = uniforms.f[32 + address_registers.y].wzyx; + return false; +} +bool sub_5() { + vs_out_attr1 = uniforms.f[33 + address_registers.y].wzyx; + return false; +} +bool sub_6() { + vs_out_attr1 = uniforms.f[34 + address_registers.y].wzyx; + return false; +} +bool sub_7() { + vs_out_attr1 = uniforms.f[35 + address_registers.y].wzyx; + return false; +} +bool sub_8() { + reg_tmp5 = uniforms.f[5].xyyy; + reg_tmp6 = uniforms.f[5].xyyy; + reg_tmp7 = uniforms.f[5].xyyy; + return false; +} +bool sub_9() { + reg_tmp5 = uniforms.f[5].yyyy; + reg_tmp6 = uniforms.f[5].yyyy; + reg_tmp7 = uniforms.f[5].yyyy; + return false; +} +bool sub_10() { + reg_tmp5 = uniforms.f[5].xxyy; + reg_tmp6 = uniforms.f[5].xxyy; + reg_tmp7 = uniforms.f[5].xxyy; + return false; +} +bool sub_11() { + reg_tmp5 = uniforms.f[5].yxyy; + reg_tmp6 = uniforms.f[5].yxyy; + reg_tmp7 = uniforms.f[5].yxyy; + return false; +} +bool sub_12() { + conditional_code = equal(uniforms.f[5].yy, reg_tmp8.xy); + if (all(conditional_code)) { + sub_13(); + } + conditional_code = lessThan(uniforms.f[5].ww, reg_tmp8.xy); + if (all(conditional_code)) { + sub_18(); + } + reg_tmp8 = uniforms.f[5].yyyy + reg_tmp8; + return false; +} +bool sub_13() { + address_registers.y = (ivec2(reg_tmp0.zz)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_14(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_15(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_16(); + } + if (all(conditional_code)) { + sub_17(); + } + return false; +} +bool sub_14() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wzzz).xy; + return false; +} +bool sub_15() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yzzz).xy; + return false; +} +bool sub_16() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wxxx).xy; + return false; +} +bool sub_17() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yxxx).xy; + return false; +} +bool sub_18() { + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_19(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_20(); + } + return false; +} +bool sub_19() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].yxxx).xy; + return false; +} +bool sub_20() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].wzzz).xy; + return false; +} +// reference: 456A7DE6F31AC733, FC7F4467554D34E5 +// shader: 8B30, 056C410B097A43B3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508A7ABA43A2, 056C410B097A43B3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 056C410B097A43B3 +// shader: 8B30, 0F330690027B8AF1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].aaa) + (const_color[4].rgb) * (vec3(1.0) - (const_color[4].aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 86CC29AC7692578E, 0F330690027B8AF1 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 0F330690027B8AF1 +// shader: 8B30, 319A75B55DC76BD9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor2.aaa) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0CC6364863D67BC1, 319A75B55DC76BD9 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 319A75B55DC76BD9 +// shader: 8B30, B9EACEA367252001 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CD329183326CBADD, B9EACEA367252001 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, B9EACEA367252001 +// shader: 8B30, 41315D0D596D9317 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.aaa) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (vec3(1.0) - last_tex_env_out.rgb); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0133760156AC92B7, 41315D0D596D9317 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 41315D0D596D9317 +// shader: 8B30, B46E074A6051B3B3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (vec3(1.0) - last_tex_env_out.rgb); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C46FE5CFC26B294C, B46E074A6051B3B3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, B46E074A6051B3B3 +// shader: 8B30, 9F61C8291ACA4ECF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3DA8C52FDEDB51DE, 9F61C8291ACA4ECF +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 9F61C8291ACA4ECF +// shader: 8B30, 7D5E0B9DF6F59291 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CD329183DEDB51DE, 7D5E0B9DF6F59291 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 7D5E0B9DF6F59291 +// shader: 8B30, B0BFEBCCCB769DBF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2EAF2D8AEC0AA969, B0BFEBCCCB769DBF +// program: 7C1C6E186A32E365, 0D30074279C2FEED, B0BFEBCCCB769DBF +// shader: 8B30, 74E4F6441286CCF5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D00FA8315840966A, 74E4F6441286CCF5 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 74E4F6441286CCF5 +// shader: 8DD9, 075A5034223F1416 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 91BCC71FEF9EA286, 075A5034223F1416 +// shader: 8B31, FC532C8E2B755EBE + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + reg_tmp15 = uniforms.f[4] + vs_in_reg1; + vs_out_attr1 = reg_tmp15.xyxy; + reg_tmp15 = uniforms.f[4] + vs_in_reg2; + vs_out_attr2 = reg_tmp15.xyxy; + return true; +} +// reference: 5432473E5FC402B5, FC532C8E2B755EBE +// shader: 8B30, 9C18FCF63420900F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0B41BDA8DBAD0753, 9C18FCF63420900F +// program: FC532C8E2B755EBE, 075A5034223F1416, 9C18FCF63420900F +// shader: 8B30, E5C645B4FC84C278 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].r); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 629D2E23623B757A, E5C645B4FC84C278 +// program: FC532C8E2B755EBE, 075A5034223F1416, E5C645B4FC84C278 +// shader: 8B30, D9B2C60702A7EDC7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].r); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BDE6B76F782BBF54, D9B2C60702A7EDC7 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D9B2C60702A7EDC7 +// shader: 8B30, D50B16A048A12667 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].r); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 727E5390F9D4A9EE, D50B16A048A12667 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D50B16A048A12667 +// shader: 8B30, 828B17C8889F4FA8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF94D2020B6, 828B17C8889F4FA8 +// program: 0000000000000000, 0000000000000000, 828B17C8889F4FA8 +// shader: 8B30, EE9D59D3D057292A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9ADE6A77E, EE9D59D3D057292A +// program: 0000000000000000, 0000000000000000, EE9D59D3D057292A +// shader: 8B30, F789075555A6DC0C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3A146E84CBA07E21, F789075555A6DC0C +// program: 0000000000000000, 0000000000000000, F789075555A6DC0C +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF91254EF14, B35EFE43E319BB63 +// program: 0000000000000000, 0000000000000000, B35EFE43E319BB63 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF95606D6C7, DC12E218392F9BDB +// program: 0000000000000000, 0000000000000000, DC12E218392F9BDB +// shader: 8B30, F7DF9C81A6227B53 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F17006129910608F, F7DF9C81A6227B53 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F7DF9C81A6227B53 +// shader: 8DD9, 0CB5B5B0F7196203 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 1EA377C1D7B39071, 0CB5B5B0F7196203 +// shader: 8B31, BBBD32DA6508CA65 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp12.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp12.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp12.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp12.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_s(uniforms.f[90], reg_tmp12); + reg_tmp13.y = dot_s(uniforms.f[91], reg_tmp12); + reg_tmp13.z = dot_s(uniforms.f[92], reg_tmp12); + reg_tmp13.w = (uniforms.f[93].yyyy).w; + vs_out_attr2 = -reg_tmp13; + reg_tmp11.x = dot_3(uniforms.f[7].xyz, vs_in_reg1.xyz); + reg_tmp11.y = dot_3(uniforms.f[8].xyz, vs_in_reg1.xyz); + reg_tmp11.z = dot_3(uniforms.f[9].xyz, vs_in_reg1.xyz); + reg_tmp14.x = dot_3(uniforms.f[90].xyz, reg_tmp11.xyz); + reg_tmp14.y = dot_3(uniforms.f[91].xyz, reg_tmp11.xyz); + reg_tmp14.z = dot_3(uniforms.f[92].xyz, reg_tmp11.xyz); + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp13); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp13); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp13); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp13); + reg_tmp3.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp14 = mul_s(reg_tmp14, reg_tmp3.xxxx); + conditional_code = equal(-uniforms.f[93].yy, reg_tmp14.zz); + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + vs_out_attr1.w = (uniforms.f[93].xxxx).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (!conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + return false; +} +bool sub_2() { + vs_out_attr1.z = rcp_s(reg_tmp4.x); + vs_out_attr1.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_3() { + vs_out_attr1 = uniforms.f[93].yxxx; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp15.x = dot_s(uniforms.f[10], vs_in_reg2); + reg_tmp15.y = dot_s(uniforms.f[11], vs_in_reg2); + vs_out_attr3 = reg_tmp15.xyxy; + return true; +} +// reference: 05CC69F582DA9168, BBBD32DA6508CA65 +// shader: 8B30, C4FE998A08F2971E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 271E905BA9D0D31A, C4FE998A08F2971E +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, C4FE998A08F2971E +// shader: 8B30, C3FC74E9CF29CDFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 271E905B013501CA, C3FC74E9CF29CDFA +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, C3FC74E9CF29CDFA +// shader: 8B30, 4B843F28173B34D8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 64215FE6FAD57073, 4B843F28173B34D8 +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, 4B843F28173B34D8 +// shader: 8B30, E7C75A2FFF03996B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0A45E4E6E876F49A, E7C75A2FFF03996B +// program: FC532C8E2B755EBE, 075A5034223F1416, E7C75A2FFF03996B +// shader: 8B30, 33BEF95C5DAD2C92 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].r); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6399776D51E086B3, 33BEF95C5DAD2C92 +// program: FC532C8E2B755EBE, 075A5034223F1416, 33BEF95C5DAD2C92 +// reference: 1080747781DE1D70, 1A48563EE40699E2 +// shader: 8B30, CA0D09B0E9CA5118 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((primary_fragment_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - texcolor1.aaa) * (vec3(1.0) - const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((vec3(1.0) - last_tex_env_out.rgb) + (const_color[3].aaa), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 80775073AA543EDA, CA0D09B0E9CA5118 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, CA0D09B0E9CA5118 +// shader: 8B30, FF0CAA2E11326C11 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.aaa) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp(min((last_tex_env_out.rgb) + (texcolor0.rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 36A69DB23BC52AA4, FF0CAA2E11326C11 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, FF0CAA2E11326C11 +// shader: 8B30, 7478A05700CC67A0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp(min((texcolor0.rgb) + (last_tex_env_out.rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6C748B5CD456D0CC, 7478A05700CC67A0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 7478A05700CC67A0 +// shader: 8DD9, ADE263AEDE96DB07 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].w; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[6].x, vtx.attributes[6].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[3] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[4] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[5] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[6] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = uniforms.f[93].xxxx; + reg_tmp1 = uniforms.f[93].yyyy; + reg_tmp1.x = (uniforms.f[6].wwww).x; + output_buffer.attributes[6] = mul_s(uniforms.f[93].xxyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[4]).xyz; + output_buffer.attributes[5] = uniforms.f[5].xyyy; + output_buffer.attributes[0] = uniforms.f[0]; + output_buffer.attributes[1] = uniforms.f[1]; + output_buffer.attributes[2] = uniforms.f[2]; + output_buffer.attributes[3] = uniforms.f[3]; + setemit(0u, false, false); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].xyyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[4]).xyz; + output_buffer.attributes[5] = uniforms.f[5].xyyy; + reg_tmp0.xy = (uniforms.f[6].xyyy).xy; + reg_tmp0.xy = (mul_s(uniforms.f[6].zzzz, reg_tmp0)).xy; + output_buffer.attributes[0] = uniforms.f[0] + reg_tmp0; + output_buffer.attributes[1] = uniforms.f[1]; + output_buffer.attributes[2] = uniforms.f[2]; + output_buffer.attributes[3] = uniforms.f[3]; + setemit(1u, false, false); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].zxyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[11]).xyz; + output_buffer.attributes[5] = uniforms.f[12].xyyy; + output_buffer.attributes[0] = uniforms.f[7]; + output_buffer.attributes[1] = uniforms.f[8]; + output_buffer.attributes[2] = uniforms.f[9]; + output_buffer.attributes[3] = uniforms.f[10]; + setemit(2u, true, false); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].zyyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[11]).xyz; + output_buffer.attributes[5] = uniforms.f[12].xyyy; + reg_tmp0.xy = (uniforms.f[13].xyyy).xy; + reg_tmp0.xy = (mul_s(uniforms.f[13].zzzz, reg_tmp0)).xy; + output_buffer.attributes[0] = uniforms.f[7] + reg_tmp0; + output_buffer.attributes[1] = uniforms.f[8]; + output_buffer.attributes[2] = uniforms.f[9]; + output_buffer.attributes[3] = uniforms.f[10]; + setemit(0u, true, true); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].xxyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[18]).xyz; + output_buffer.attributes[5] = uniforms.f[19].xyyy; + output_buffer.attributes[0] = uniforms.f[14]; + output_buffer.attributes[1] = uniforms.f[15]; + output_buffer.attributes[2] = uniforms.f[16]; + output_buffer.attributes[3] = uniforms.f[17]; + setemit(1u, true, false); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].xyyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[18]).xyz; + output_buffer.attributes[5] = uniforms.f[19].xyyy; + reg_tmp0.xy = (uniforms.f[20].xyyy).xy; + reg_tmp0.xy = (mul_s(uniforms.f[20].zzzz, reg_tmp0)).xy; + output_buffer.attributes[0] = uniforms.f[14] + reg_tmp0; + output_buffer.attributes[1] = uniforms.f[15]; + output_buffer.attributes[2] = uniforms.f[16]; + output_buffer.attributes[3] = uniforms.f[17]; + setemit(2u, true, true); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].zxyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[4]).xyz; + output_buffer.attributes[5] = uniforms.f[5].xyyy; + output_buffer.attributes[0] = uniforms.f[0]; + output_buffer.attributes[1] = uniforms.f[1]; + output_buffer.attributes[2] = uniforms.f[2]; + output_buffer.attributes[3] = uniforms.f[3]; + setemit(0u, true, false); + emit(); + output_buffer.attributes[6] = mul_s(uniforms.f[93].zyyy, reg_tmp1); + output_buffer.attributes[4].xyz = (uniforms.f[4]).xyz; + output_buffer.attributes[5] = uniforms.f[5].xyyy; + reg_tmp0.xy = (uniforms.f[6].xyyy).xy; + reg_tmp0.xy = (mul_s(uniforms.f[6].zzzz, reg_tmp0)).xy; + output_buffer.attributes[0] = uniforms.f[0] + reg_tmp0; + output_buffer.attributes[1] = uniforms.f[1]; + output_buffer.attributes[2] = uniforms.f[2]; + output_buffer.attributes[3] = uniforms.f[3]; + setemit(1u, true, true); + emit(); + return true; +} +// reference: 5590F125974A5335, ADE263AEDE96DB07 +// shader: 8B31, 07071F6851963C31 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; +layout(location = 9) in vec4 vs_in_reg9; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_21(); +bool sub_4(); +bool sub_9(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_10(); +bool sub_20(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_6(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_44(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_45(); +bool sub_46(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_55(); +bool sub_57(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_56(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_21() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_4() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_9() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_23(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_3(); + } else { + sub_7(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_4(); + } + if (uniforms.b[8]) { + sub_5(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_5() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_4(); + } + return false; +} +bool sub_7() { + if (all(conditional_code)) { + sub_8(); + } else { + sub_20(); + } + return false; +} +bool sub_8() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_9(); + } + if (uniforms.b[8]) { + sub_10(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_20() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_21(); + } + if (uniforms.b[8]) { + sub_22(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_22() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_21(); + } + return false; +} +bool sub_23() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_24(); + } else { + sub_25(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_27(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_24() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_25() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_26() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_27() { + if (all(conditional_code)) { + sub_28(); + } else { + sub_29(); + } + return false; +} +bool sub_28() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_11(); + } + return false; +} +bool sub_29() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_6() { + uint jmp_to = 218u; + while (true) { + switch (jmp_to) { + case 218u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 234u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 234u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 234u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + uint jmp_to = 235u; + while (true) { + switch (jmp_to) { + case 235u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 310u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 272u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 310u; break; } + } + } + case 272u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_12(); + } else { + sub_17(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 310u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_12() { + if (conditional_code.y) { + sub_13(); + } else { + sub_14(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_14() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_17() { + if (conditional_code.y) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_19() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_30() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_31(); + } + if (uniforms.b[12]) { + sub_33(); + } + if (uniforms.b[5]) { + sub_42(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_44(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_31() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_32(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_32() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_44() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_33() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop331 = 0u; loop331 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop331) { + sub_34(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_34() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[81 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[83 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_35(); + } else { + sub_36(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_41(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_35() { + reg_tmp6.x = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_36() { + reg_tmp4 = uniforms.f[81 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_37(); + } + reg_tmp5 = uniforms.f[82 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_38(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_37() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[83 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_38() { + reg_tmp5.x = dot_3(uniforms.f[82 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[84 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_39(); + } else { + sub_40(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_39() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_40() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[84 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_41() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[80 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_42() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_43(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_43() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_46(); + } else { + sub_52(); + } + return false; +} +bool sub_46() { + { + sub_47(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_52() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_53(); + } else { + sub_54(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_53() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_54() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + { + sub_56(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_57() { + { + sub_58(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_49(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_48() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_49() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_50(); + } else { + sub_51(); + } + return false; +} +bool sub_50() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_56() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_58() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_59() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_60(); + } else { + sub_61(); + } + return false; +} +bool sub_60() { + { + sub_47(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_61() { + if (uniforms.b[13]) { + sub_62(); + } else { + sub_65(); + } + return false; +} +bool sub_62() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_63(); + } else { + sub_64(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_63() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_64() { + { + sub_58(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_65() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_0() { + { + sub_1(); + } + { + sub_30(); + } + { + sub_45(); + } + { + sub_59(); + } + reg_tmp0.x = dot_3(uniforms.f[86].xyz, reg_tmp14.xyz); + reg_tmp0.y = dot_3(uniforms.f[87].xyz, reg_tmp14.xyz); + reg_tmp0.z = (mul_s(uniforms.f[84].xxxx, vs_in_reg9.xxxx)).z; + reg_tmp0.w = (uniforms.f[84].yyyy).w; + vs_out_attr6 = reg_tmp0; + return true; +} +// reference: 0732E132FFC392E6, 07071F6851963C31 +// shader: 8B30, ED0ABCDE9C5CA9FC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor2.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor1.aaa) * (vec3(1.0) - const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((vec3(1.0) - last_tex_env_out.rgb) + (const_color[4].aaa), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 156E271A11EB9E6C, ED0ABCDE9C5CA9FC +// program: 07071F6851963C31, ADE263AEDE96DB07, ED0ABCDE9C5CA9FC +// shader: 8B31, 8E8F088494A2C9DF + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; +layout(location = 9) in vec4 vs_in_reg9; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_21(); +bool sub_4(); +bool sub_9(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_10(); +bool sub_20(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_6(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_44(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_45(); +bool sub_46(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_55(); +bool sub_57(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_56(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_66(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + { + sub_1(); + } + { + sub_30(); + } + { + sub_45(); + } + { + sub_59(); + } + { + sub_66(); + } + return true; +} +bool sub_21() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_4() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_9() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp0 = mul_s(uniforms.f[84], vs_in_reg9.xxxx); + reg_tmp0 = mul_s(uniforms.f[84].zzzz, reg_tmp0); + reg_tmp1 = mul_s(vs_in_reg1, reg_tmp0.yyyy); + reg_tmp15.xyz = (reg_tmp15 + reg_tmp1).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_23(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_3(); + } else { + sub_7(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_4(); + } + if (uniforms.b[8]) { + sub_5(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_5() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_4(); + } + return false; +} +bool sub_7() { + if (all(conditional_code)) { + sub_8(); + } else { + sub_20(); + } + return false; +} +bool sub_8() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_9(); + } + if (uniforms.b[8]) { + sub_10(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_20() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_21(); + } + if (uniforms.b[8]) { + sub_22(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_22() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_21(); + } + return false; +} +bool sub_23() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_24(); + } else { + sub_25(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_27(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_24() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_25() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp15 = reg_tmp10; + reg_tmp10 = mul_s(uniforms.f[85], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_26() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_27() { + if (all(conditional_code)) { + sub_28(); + } else { + sub_29(); + } + return false; +} +bool sub_28() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_11(); + } + return false; +} +bool sub_29() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_6() { + uint jmp_to = 216u; + while (true) { + switch (jmp_to) { + case 216u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 232u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 232u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 232u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + uint jmp_to = 233u; + while (true) { + switch (jmp_to) { + case 233u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 308u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 270u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 308u; break; } + } + } + case 270u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_12(); + } else { + sub_17(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 308u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_12() { + if (conditional_code.y) { + sub_13(); + } else { + sub_14(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_14() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_17() { + if (conditional_code.y) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_19() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_30() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_31(); + } + if (uniforms.b[12]) { + sub_33(); + } + if (uniforms.b[5]) { + sub_42(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_44(); + } + reg_tmp0 = uniforms.f[84].xxxx; + reg_tmp9.w = (mul_s(uniforms.f[84].xxxx, reg_tmp0.xxxx)).w; + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_31() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_32(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_32() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_44() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_33() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop331 = 0u; loop331 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop331) { + sub_34(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_34() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[79 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[81 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_35(); + } else { + sub_36(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_41(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_35() { + reg_tmp6.x = dot_3(uniforms.f[79 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_36() { + reg_tmp4 = uniforms.f[79 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_37(); + } + reg_tmp5 = uniforms.f[80 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_38(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_37() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_38() { + reg_tmp5.x = dot_3(uniforms.f[80 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[82 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_39(); + } else { + sub_40(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_39() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_40() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[82 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_41() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[77 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[78 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_42() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_43(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_43() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_46(); + } else { + sub_52(); + } + return false; +} +bool sub_46() { + { + sub_47(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_52() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_53(); + } else { + sub_54(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_53() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_54() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + { + sub_56(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_57() { + { + sub_58(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_49(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_48() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_49() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_50(); + } else { + sub_51(); + } + return false; +} +bool sub_50() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_56() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_58() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_59() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_60(); + } else { + sub_61(); + } + return false; +} +bool sub_60() { + { + sub_47(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_61() { + if (uniforms.b[13]) { + sub_62(); + } else { + sub_65(); + } + return false; +} +bool sub_62() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_63(); + } else { + sub_64(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_63() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_64() { + { + sub_58(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_65() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_66() { + reg_tmp0.xy = (uniforms.f[10].zzzz).xy; + if (uniforms.b[11]) { + sub_67(); + } else { + sub_68(); + } + return false; +} +bool sub_67() { + { + sub_47(); + } + reg_tmp5.x = dot_s(uniforms.f[17].xywz, reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18].xywz, reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_68() { + if (uniforms.b[14]) { + sub_69(); + } else { + sub_70(); + } + return false; +} +bool sub_69() { + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp5.zw = (reg_tmp6.zwww).zw; + { + sub_58(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_70() { + vs_out_attr6 = uniforms.f[93].xxxx; + return false; +} +// reference: B2EE6F8EE02937B5, 8E8F088494A2C9DF +// shader: 8B30, 2DE0D2291093BD05 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor2.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((vec3(1.0) - texcolor1.aaa) * (vec3(1.0) - const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp(min((vec3(1.0) - last_tex_env_out.rgb) + (const_color[5].aaa), vec3(1.0)) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CA359365778AEBAF, 2DE0D2291093BD05 +// program: 8E8F088494A2C9DF, 0D30074279C2FEED, 2DE0D2291093BD05 +// reference: EFBDBFF627FE37C2, 9C18FCF63420900F +// reference: 86612C7D9E6845EB, E5C645B4FC84C278 +// shader: 8B30, 9D5AE522276B3166 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) + (vec3(1.0) - const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6E7420D79BB7384C, 9D5AE522276B3166 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 9D5AE522276B3166 +// shader: 8B30, B5AD018DB0C89E09 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) + (vec3(1.0) - const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40D22C5060D3669E, B5AD018DB0C89E09 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B5AD018DB0C89E09 +// shader: 8B30, D1C502CFC9711184 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) + (vec3(1.0) - const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8F4AC8AFE12C7024, D1C502CFC9711184 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D1C502CFC9711184 +// shader: 8DD9, B326B1D273D9548B + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +in vec4 vs_out_attr7[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[3] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[4] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[5] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + vs_out_attr6[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].xyyy).xy; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].zwww).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(0u, false, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + -vs_out_attr7[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].xyyy).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(1u, false, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + vs_out_attr7[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].zwww).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(2u, true, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + -vs_out_attr6[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + output_buffer.attributes[4] = vs_out_attr4[0]; + output_buffer.attributes[5] = vs_out_attr4[0]; + setemit(0u, true, true); + emit(); + return true; +} +// reference: 2058CD462268FCFB, B326B1D273D9548B +// shader: 8B31, 59B04B6EAAAB8C6A + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; +out vec4 vs_out_attr7; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr7 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = vs_in_reg2; + reg_tmp0 = uniforms.f[39] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[84].xxxx, reg_tmp0); + reg_tmp1 = floor(reg_tmp0); + reg_tmp12 = reg_tmp0 + -reg_tmp1; + reg_tmp0 = vs_in_reg1; + reg_tmp0 = mul_s(reg_tmp0, vs_in_reg8); + reg_tmp13 = mul_s(uniforms.f[38], reg_tmp0); + if (uniforms.b[1]) { + sub_1(); + } + if (uniforms.b[3]) { + sub_2(); + } else { + sub_3(); + } + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp15.xyz = (uniforms.f[6] + vs_in_reg0).xyz; + reg_tmp10.x = dot_s(uniforms.f[34], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[35], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[36], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = mul_s(uniforms.f[37].xxxx, reg_tmp6); + reg_tmp1 = mul_s(uniforms.f[37].yyyy, reg_tmp7); + reg_tmp15.xyz = (reg_tmp15 + -reg_tmp0).xyz; + reg_tmp15.xyz = (reg_tmp15 + -reg_tmp1).xyz; + vs_out_attr1 = uniforms.f[93].xxxx; + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + vs_out_attr3.xyz = (vs_in_reg3.xyzz).xyz; + vs_out_attr3.w = (vs_in_reg4.xxxx).w; + reg_tmp0 = mul_s(uniforms.f[84].xxxx, vs_in_reg7); + reg_tmp1 = floor(reg_tmp0); + reg_tmp3 = reg_tmp0 + -reg_tmp1; + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp0.z = (mul_s(reg_tmp3.xxxx, reg_tmp3.xxxx)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp3.xxxx)).y; + reg_tmp0.x = (fma_s(reg_tmp0.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp1 = mul_s(vs_in_reg6.xyxy, reg_tmp0.yxxy); + reg_tmp1.x = (-reg_tmp1.xxxx).x; + reg_tmp2.x = (-uniforms.f[94].zzzz + -vs_in_reg5.xxxx).x; + reg_tmp2.y = (-uniforms.f[94].zzzz + vs_in_reg5.yyyy).y; + reg_tmp0 = mul_s(reg_tmp1, reg_tmp2.yyxx); + reg_tmp2.xy = (uniforms.f[94].zzzz + reg_tmp0.xyyy).xy; + reg_tmp0.xy = (reg_tmp0.zwww + reg_tmp2.xyyy).xy; + reg_tmp2.xy = (reg_tmp0).xy; + reg_tmp2.zw = (uniforms.f[93].xxxy).zw; + reg_tmp0.x = dot_s(uniforms.f[11], reg_tmp2); + reg_tmp0.y = dot_s(uniforms.f[12], reg_tmp2); + reg_tmp0.z = dot_s(uniforms.f[13], reg_tmp2); + vs_out_attr4 = reg_tmp0; + reg_tmp2.xy = (reg_tmp1.xyyy).xy; + reg_tmp0.x = dot_3(uniforms.f[11].xyz, reg_tmp2.xyz); + reg_tmp0.y = dot_3(uniforms.f[12].xyz, reg_tmp2.xyz); + vs_out_attr5.xy = (reg_tmp0.xyyy).xy; + reg_tmp2.xy = (reg_tmp1.zwww).xy; + reg_tmp0.x = dot_3(uniforms.f[11].xyz, reg_tmp2.xyz); + reg_tmp0.y = dot_3(uniforms.f[12].xyz, reg_tmp2.xyz); + vs_out_attr5.zw = (reg_tmp0.xxxy).zw; + reg_tmp0.xyz = (reg_tmp6.xyzz + reg_tmp7.xyzz).xyz; + vs_out_attr6.x = dot_3(uniforms.f[86].xyz, reg_tmp0.xyz); + vs_out_attr6.y = dot_3(uniforms.f[87].xyz, reg_tmp0.xyz); + vs_out_attr6.z = dot_3(uniforms.f[88].xyz, reg_tmp0.xyz); + vs_out_attr6.w = dot_3(uniforms.f[89].xyz, reg_tmp0.xyz); + reg_tmp0.xyz = (reg_tmp6.xyzz + -reg_tmp7.xyzz).xyz; + vs_out_attr7.x = dot_3(uniforms.f[86].xyz, reg_tmp0.xyz); + vs_out_attr7.y = dot_3(uniforms.f[87].xyz, reg_tmp0.xyz); + vs_out_attr7.z = dot_3(uniforms.f[88].xyz, reg_tmp0.xyz); + vs_out_attr7.w = dot_3(uniforms.f[89].xyz, reg_tmp0.xyz); + return true; +} +bool sub_1() { + reg_tmp9 = uniforms.f[93].xxxx; + reg_tmp10 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp3 = mul_s(reg_tmp12, reg_tmp12); + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp5 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.xxxx)).y; + reg_tmp0.x = (fma_s(reg_tmp3.xxxx, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp4.xy = (reg_tmp0).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.yyyy)).y; + reg_tmp0.x = (fma_s(reg_tmp3.yyyy, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp4.zw = (reg_tmp0.xxxy).zw; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.zzzz)).y; + reg_tmp0.x = (fma_s(reg_tmp3.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp11.x = (-reg_tmp4.wwww).x; + reg_tmp9.x = (mul_s(reg_tmp0.xxxx, reg_tmp4.zzzz)).x; + reg_tmp10.x = (mul_s(reg_tmp0.yyyy, reg_tmp4.zzzz)).x; + reg_tmp11.y = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).y; + reg_tmp11.z = (mul_s(reg_tmp4.xxxx, reg_tmp4.zzzz)).z; + reg_tmp1.xy = (mul_s(reg_tmp4.xyyy, reg_tmp0.yxxx)).xy; + reg_tmp9.y = (fma_s(reg_tmp1.yyyy, reg_tmp4.wwww, -reg_tmp1.xxxx)).y; + reg_tmp10.z = (fma_s(reg_tmp1.xxxx, reg_tmp4.wwww, -reg_tmp1.yyyy)).z; + reg_tmp1.xy = (mul_s(reg_tmp4.yxxx, reg_tmp0.yxxx)).xy; + reg_tmp9.z = (fma_s(reg_tmp1.yyyy, reg_tmp4.wwww, reg_tmp1.xxxx)).z; + reg_tmp10.y = (fma_s(reg_tmp1.xxxx, reg_tmp4.wwww, reg_tmp1.yyyy)).y; + return false; +} +bool sub_2() { + reg_tmp6.yz = (uniforms.f[93].xxxx).yz; + reg_tmp7.xz = (uniforms.f[93].xxxx).xz; + reg_tmp6.xw = (uniforms.f[93].yyyy).xw; + reg_tmp7.yw = (uniforms.f[93].yyyy).yw; + reg_tmp6.xyz = (mul_s(reg_tmp6, reg_tmp13.xxxx)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp7, reg_tmp13.yyyy)).xyz; + reg_tmp0.x = dot_3(reg_tmp6.xyz, reg_tmp9.xyz); + reg_tmp0.y = dot_3(reg_tmp6.xyz, reg_tmp10.xyz); + reg_tmp0.z = dot_3(reg_tmp6.xyz, reg_tmp11.xyz); + reg_tmp6 = reg_tmp0; + reg_tmp1.x = dot_3(reg_tmp7.xyz, reg_tmp9.xyz); + reg_tmp1.y = dot_3(reg_tmp7.xyz, reg_tmp10.xyz); + reg_tmp1.z = dot_3(reg_tmp7.xyz, reg_tmp11.xyz); + reg_tmp7 = reg_tmp1; + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + return false; +} +bool sub_3() { + if (uniforms.b[2]) { + sub_4(); + } else { + sub_5(); + } + return false; +} +bool sub_4() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp6 = uniforms.f[93].xxxx; + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp7.y = (uniforms.f[93].yyyy).y; + reg_tmp0.x = dot_3(reg_tmp6.xyz, reg_tmp9.xyz); + reg_tmp0.y = dot_3(reg_tmp6.xyz, reg_tmp10.xyz); + reg_tmp0.z = dot_3(reg_tmp6.xyz, reg_tmp11.xyz); + reg_tmp6 = reg_tmp0; + reg_tmp1.x = dot_3(reg_tmp7.xyz, reg_tmp9.xyz); + reg_tmp1.y = dot_3(reg_tmp7.xyz, reg_tmp10.xyz); + reg_tmp1.z = dot_3(reg_tmp7.xyz, reg_tmp11.xyz); + reg_tmp7 = reg_tmp1; + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp8.xyz = (mul_s(reg_tmp0.yzxx, reg_tmp7.zxyy)).xyz; + reg_tmp8.xyz = (fma_s(-reg_tmp7.yzxx, reg_tmp0.zxyy, reg_tmp8)).xyz; + reg_tmp1 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp3 = vec4(rsq_s(reg_tmp1.x)); + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + reg_tmp0 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp1.xxxx); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp3.xxxx); + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp13.xxxx); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp13.yyyy); + return false; +} +bool sub_5() { + if (uniforms.b[4]) { + sub_6(); + } else { + sub_7(); + } + reg_tmp0 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp1.xxxx); + reg_tmp0 = vec4(dot_3(reg_tmp7.xyz, reg_tmp7.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp1.xxxx); + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp13.xxxx); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp13.yyyy); + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp0.z = (mul_s(reg_tmp12.zzzz, reg_tmp12.zzzz)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.zzzz)).y; + reg_tmp0.x = (fma_s(reg_tmp0.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp0.z = (-reg_tmp0.yyyy).z; + reg_tmp1 = mul_s(reg_tmp0.xzyx, reg_tmp6.xyxy); + reg_tmp6.xy = (reg_tmp1.xzzz + reg_tmp1.ywww).xy; + reg_tmp6.zw = (uniforms.f[93].xxxx).zw; + reg_tmp1 = mul_s(reg_tmp0.xzyx, reg_tmp7.xyxy); + reg_tmp7.xy = (reg_tmp1.xzzz + reg_tmp1.ywww).xy; + reg_tmp7.zw = (uniforms.f[93].xxxx).zw; + return false; +} +bool sub_6() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp7.xz = (uniforms.f[93].xxxx).xz; + reg_tmp7.yw = (uniforms.f[93].yyyy).yw; + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp8.yzxx, reg_tmp0.zxyy)).xyz; + reg_tmp7.xyz = (fma_s(-reg_tmp0.yzxx, reg_tmp8.zxyy, reg_tmp7)).xyz; + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + return false; +} +bool sub_7() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp7.x = (uniforms.f[28].yyyy).x; + reg_tmp7.y = (uniforms.f[29].yyyy).y; + reg_tmp7.z = (uniforms.f[30].yyyy).z; + reg_tmp0 = vec4(dot_3(reg_tmp7.xyz, reg_tmp7.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp1.xxxx); + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp8.yzxx, reg_tmp0.zxyy)).xyz; + reg_tmp7.xyz = (fma_s(-reg_tmp0.yzxx, reg_tmp8.zxyy, reg_tmp7)).xyz; + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + return false; +} +// reference: AC36BCBAAA6A6345, 59B04B6EAAAB8C6A +// shader: 8B30, 5B9100C39C7AE9AD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((rounded_primary_color.rgb) + (texcolor0.rgb), vec3(1.0)) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B24FC9AF4217DF7E, 5B9100C39C7AE9AD +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 5B9100C39C7AE9AD +// shader: 8B30, BAD913FED9CCF457 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rrr), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.ggg) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor2.rgb) * (rounded_primary_color.bbb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6C2094FC9C966923, BAD913FED9CCF457 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, BAD913FED9CCF457 +// shader: 8B30, C910B77CB248A4D0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp(min((texcolor0.aaa) + (const_color[1].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D99880D707DDF7B8, C910B77CB248A4D0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, C910B77CB248A4D0 +// shader: 8B30, E1FCDA69FC09E459 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 91675F5A3F349DC3, E1FCDA69FC09E459 +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, E1FCDA69FC09E459 +// shader: 8B30, B34A52D0044184E6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 91675F5A97D14F13, B34A52D0044184E6 +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, B34A52D0044184E6 +// shader: 8B30, 8C0376603B15EE41 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D25890E76C313EAA, 8C0376603B15EE41 +// program: BBBD32DA6508CA65, 0CB5B5B0F7196203, 8C0376603B15EE41 +// reference: BC3C2BE727FE37C2, E7C75A2FFF03996B +// reference: D5E0B86C9E6845EB, 33BEF95C5DAD2C92 +// shader: 8B30, A96CC636150E8965 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2FC15C0DA1852B99, A96CC636150E8965 +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, A96CC636150E8965 +// shader: 8B30, F6046CCED45BE570 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9C64C71CA52D7E32, F6046CCED45BE570 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F6046CCED45BE570 +// shader: 8B30, 7C2EA4FFA656A334 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb) + (const_color[0].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E3E638F3C8D42CF8, 7C2EA4FFA656A334 +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C2EA4FFA656A334 +// shader: 8B30, 441F63DB535DFBD0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) + (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 49D2EE72762A0321, 441F63DB535DFBD0 +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DB535DFBD0 +// reference: 49D2EE72A1852B99, 441F63DB535DFBD0 +// shader: 8B30, 9DE32D8778BC56B0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) + (vec3(1.0) - const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40D22C502E2BEF84, 9DE32D8778BC56B0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9DE32D8778BC56B0 +// shader: 8B30, F5AE26271A408889 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508A3442CAB8, F5AE26271A408889 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F5AE26271A408889 +// shader: 8B30, 15586A7B4B24FD5A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CEFFB475FB455518, 15586A7B4B24FD5A +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 15586A7B4B24FD5A +// shader: 8B30, CF274BC5581E3660 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CEFFB475B5BDDC02, CF274BC5581E3660 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, CF274BC5581E3660 +// shader: 8B30, E9FB532B3CD79C43 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (texcolor0.rgb); +float alpha_output_3 = (texcolor1.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (last_tex_env_out.rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (last_tex_env_out.a) + (combiner_buffer.a) * (1.0 - (last_tex_env_out.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DB0C6C89F7897D4D, E9FB532B3CD79C43 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, E9FB532B3CD79C43 +// shader: 8B30, 1296E267F9208249 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2FC15C0D81DE1D70, 1296E267F9208249 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 1296E267F9208249 +// shader: 8B30, 5EC6C091DB5CC893 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52C0D063D01D2D4D, 5EC6C091DB5CC893 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 5EC6C091DB5CC893 +// shader: 8B30, A68D1175BD8FF201 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B1A2474BE0A1E199, A68D1175BD8FF201 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A68D1175BD8FF201 +// shader: 8B30, 5EECE514DBFC1A45 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.ggg) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1BB2BF85F26CEF60, 5EECE514DBFC1A45 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 5EECE514DBFC1A45 +// shader: 8B30, 5A253E94C2D02A9C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1CD79006764AD76C, 5A253E94C2D02A9C +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 5A253E94C2D02A9C +// shader: 8B30, F40A3670A01FAF7C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (1.0 - texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 244C478D03B2F2A7, F40A3670A01FAF7C +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F40A3670A01FAF7C +// shader: 8B30, C2B86734C11837F5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_1) * geo_factor)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_1) * geo_factor)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor1.rgb) - (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3EE0EEA194E9B397, C2B86734C11837F5 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, C2B86734C11837F5 +// shader: 8B30, B08BD469AF77F95F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.bbb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((texcolor1.rgb) - (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10CA7B351048BE7E, B08BD469AF77F95F +// program: 7C1C6E186A32E365, 0D30074279C2FEED, B08BD469AF77F95F +// shader: 8B30, D44F38EF62FE1E08 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AD2D9B7E6F94CC0C, D44F38EF62FE1E08 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, D44F38EF62FE1E08 +// shader: 8B30, 0DA07F1CD1B60BB1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D1608DCD3DD24947, 0DA07F1CD1B60BB1 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 0DA07F1CD1B60BB1 +// shader: 8B30, 9E059DDF96050BD8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.ggg) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D20305B3D01D2D4D, 9E059DDF96050BD8 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 9E059DDF96050BD8 +// shader: 8B30, F002EADBAF401317 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3754BD9BC53D317D, F002EADBAF401317 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F002EADBAF401317 +// shader: 8B30, F471CB1E60529158 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5BC25C1C338FD9AA, F471CB1E60529158 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F471CB1E60529158 +// reference: 064FF49D4D64E9F8, F40A3670A01FAF7C +// shader: 8B30, 238989C7D599F527 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(8, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(8, dot(light_vector, spot_dir))); +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.bbb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9446C92A338FD9AA, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// shader: 8B30, 138FE672F07061E0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor0).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position + view); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(16, clamp(light_src[0].dist_atten_scale * length(-view - light_src[0].position) + light_src[0].dist_atten_bias, 0.0, 1.0)) * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (secondary_fragment_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D2A97152B0E7315A, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// shader: 8B30, 98B92A4493D4C2C4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (rounded_primary_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E6A2750715FF174E, 98B92A4493D4C2C4 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 98B92A4493D4C2C4 +// shader: 8B30, F3A26454AF33D94D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 82D2472627CF7AE8, F3A26454AF33D94D +// program: 7C1C6E186A32E365, 0D30074279C2FEED, F3A26454AF33D94D +// reference: 5BC25C1CAEC03AEF, F471CB1E60529158 +// shader: 8B30, 26214404AED0483A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTUnsigned(9, max(dot(light_vector, spot_dir), 0.0))); +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (secondary_fragment_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8F7ACA3CCCE7FDE9, 26214404AED0483A +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 26214404AED0483A +// reference: 4E77384C49193389, 7478A05700CC67A0 +// reference: 376D940A8CA47D29, ED0ABCDE9C5CA9FC +// reference: E8362075EAC508EA, 2DE0D2291093BD05 +// shader: 8B30, 7C8AF55DE5C69CC6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E3E638F3E33A5DDF, 7C8AF55DE5C69CC6 +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// shader: 8B30, 441F63DBCC1F6F4A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F1700612A1852B99, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// shader: 8B30, 801FD427A7E2731F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 104EEE6ADB1E63F1, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// shader: 8B30, C8CD1340CA3429C1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DFD60A955AE1754B, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// reference: 52C0D0634D52CE08, 5EC6C091DB5CC893 +// reference: B1A2474B7DEE02DC, A68D1175BD8FF201 +// reference: 1BB2BF8521F5177A, 5EECE514DBFC1A45 +// reference: 1CD79006A5D32F76, 5A253E94C2D02A9C +// reference: 244C478DD02B0ABD, F40A3670A01FAF7C +// reference: 3EE0EEA147704B8D, C2B86734C11837F5 +// reference: 10CA7B35C3D14664, B08BD469AF77F95F +// reference: AD2D9B7EBC0D3416, D44F38EF62FE1E08 +// reference: D1608DCDEE4BB15D, 0DA07F1CD1B60BB1 +// reference: D20305B30384D557, 9E059DDF96050BD8 +// reference: 3754BD9B16A4C967, F002EADBAF401317 +// reference: 5BC25C1CE01621B0, F471CB1E60529158 +// reference: 064FF49D9EFD11E2, F40A3670A01FAF7C +// reference: 9446C92AE01621B0, 238989C7D599F527 +// shader: 8B30, 68FAD84B35BC74C5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 02D8D08B99A115B7, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// shader: 8B30, 0C92DB094C05FB48 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CD403474185E030D, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// shader: 8B30, 3B8BF159D10007D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BD8D5A24FB455518, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// shader: 8B30, E5E0586BDE7927A5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 254A8B7614B058DB, E5E0586BDE7927A5 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E5E0586BDE7927A5 +// reference: 254A8B765A664384, E5E0586BDE7927A5 +// shader: 8B30, 9D53AC6FD16DFD85 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) + (vec3(1.0) - const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FC3826FEE12C7024, 9D53AC6FD16DFD85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// shader: 8B30, 850B3AB6D34A117A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DA5380CBFBD83329, 850B3AB6D34A117A +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 850B3AB6D34A117A +// reference: 7614F88BA31C960B, 7C1C6E186A32E365 +// reference: FDD61A83F31AC733, FC7F4467554D34E5 +// reference: AFC5A17E82DA9168, BBBD32DA6508CA65 +// reference: 28CA57D8974A5335, ADE263AEDE96DB07 +// reference: A05BC060E02937B5, 8E8F088494A2C9DF +// reference: 5D026BBB2268FCFB, B326B1D273D9548B +// reference: 9EA25AB3974A5335, ADE263AEDE96DB07 +// reference: EB6A66D02268FCFB, B326B1D273D9548B +// reference: E3F8FC4E974A5335, ADE263AEDE96DB07 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 850B3AB6D34A117A +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 850B3AB6D34A117A +// reference: 9630C02D2268FCFB, B326B1D273D9548B +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// program: 0000000000000000, 0000000000000000, ED0ABCDE9C5CA9FC +// program: 0000000000000000, 0000000000000000, 5B9100C39C7AE9AD +// reference: 1CE35DB194E9B397, C2B86734C11837F5 +// reference: 32C9C8251048BE7E, B08BD469AF77F95F +// shader: 8B30, 164F6FA6C959E1F0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F3633EDD3DD24947, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// shader: 8B30, 93712046C48C1445 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 15570E8BC53D317D, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// shader: 8B30, E76687C479A7A23E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rrr) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 79C1EF0C338FD9AA, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// reference: 244C478D4D64E9F8, F40A3670A01FAF7C +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// shader: 8B30, 70A6A667A9021915 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) * (rounded_primary_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C4A1C61715FF174E, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// shader: 8B30, 3A564A2535EA8AF3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A0D1F43627CF7AE8, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// reference: 79C1EF0CAEC03AEF, E76687C479A7A23E +// shader: 8B30, A6E657ED2926E507 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position + view); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(17, clamp(light_src[1].dist_atten_scale * length(-view - light_src[1].position) + light_src[1].dist_atten_bias, 0.0, 1.0)) * (lut_scale_sp * LookupLightingLUTSigned(9, dot(light_vector, spot_dir))); +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (secondary_fragment_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AD79792CCCE7FDE9, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// reference: 6C748B5C49193389, 7478A05700CC67A0 +// reference: 156E271A8CA47D29, ED0ABCDE9C5CA9FC +// reference: CA359365EAC508EA, 2DE0D2291093BD05 +// shader: 8B30, 8193B750BBE43D8F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) * (texcolor1.rgb) + (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 94DCA10155CD037C, 8193B750BBE43D8F +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// reference: 1CE35DB147704B8D, C2B86734C11837F5 +// reference: 32C9C825C3D14664, B08BD469AF77F95F +// reference: F3633EDDEE4BB15D, 164F6FA6C959E1F0 +// reference: 15570E8B16A4C967, 93712046C48C1445 +// reference: 79C1EF0CE01621B0, E76687C479A7A23E +// reference: 244C478D9EFD11E2, F40A3670A01FAF7C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// shader: 8B30, 4478AF439B54EBFE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb) + (const_color[0].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 02D8D08BB24F6490, 4478AF439B54EBFE +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4478AF439B54EBFE +// shader: 8B30, 2010AC01E2ED6473 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb) + (const_color[0].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CD40347433B0722A, 2010AC01E2ED6473 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 2010AC01E2ED6473 +// shader: 8B30, F53B4E1DE1501E36 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CEFFB475DB1E63F1, F53B4E1DE1501E36 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F53B4E1DE1501E36 +// shader: 8B30, 6C296D4A56AD11EF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508A5AE1754B, 6C296D4A56AD11EF +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 6C296D4A56AD11EF +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4478AF439B54EBFE +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 2010AC01E2ED6473 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4478AF439B54EBFE +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 2010AC01E2ED6473 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F53B4E1DE1501E36 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 6C296D4A56AD11EF +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4478AF439B54EBFE +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 2010AC01E2ED6473 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 164F6FA6C959E1F0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 93712046C48C1445 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, E76687C479A7A23E +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 238989C7D599F527 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 138FE672F07061E0 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 70A6A667A9021915 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 3A564A2535EA8AF3 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, A6E657ED2926E507 +// program: 7C1C6E186A32E365, 0D30074279C2FEED, 8193B750BBE43D8F +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 441F63DBCC1F6F4A +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, 7C8AF55DE5C69CC6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 68FAD84B35BC74C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0C92DB094C05FB48 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3B8BF159D10007D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 801FD427A7E2731F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C8CD1340CA3429C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9D53AC6FD16DFD85 diff --git a/cache/0004000000090700.shader.meta b/cache/0004000000090700.shader.meta new file mode 100644 index 00000000000..d931a60ca49 --- /dev/null +++ b/cache/0004000000090700.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 101 +reference: 150 +program: 90 diff --git a/cache/00040000000B3500.shader b/cache/00040000000B3500.shader new file mode 100644 index 00000000000..6d0f7a644f2 --- /dev/null +++ b/cache/00040000000B3500.shader @@ -0,0 +1,4582 @@ +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B31, 5FDE023DED8BD8D9 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp0 = uniforms.f[5]; + reg_tmp0.w = (mul_s(uniforms.f[94].xxxx, reg_tmp0.wwww)).w; + reg_tmp15.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp15.y = dot_s(vs_in_reg0, reg_tmp0); + reg_tmp15.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp15.w = dot_s(uniforms.f[7], vs_in_reg0); + reg_tmp12 = uniforms.f[14]; + reg_tmp12 = uniforms.f[15] + reg_tmp12; + reg_tmp12 = mul_s(-uniforms.f[94].zzzz, reg_tmp12); + vs_out_attr0.x = dot_s(uniforms.f[12], reg_tmp15); + vs_out_attr0.y = dot_s(reg_tmp15, reg_tmp0); + vs_out_attr0.z = dot_s(reg_tmp15, reg_tmp12); + vs_out_attr0.w = dot_s(uniforms.f[15], reg_tmp15); + return false; +} +bool sub_0() { + { + sub_1(); + } + vs_out_attr1 = vs_in_reg1; + vs_out_attr2 = vs_in_reg2; + return true; +} +// reference: 6C535BFC9E07FE54, 5FDE023DED8BD8D9 +// shader: 8B30, 122AF7252C3959A4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287ACE247572, 122AF7252C3959A4 +// program: 5FDE023DED8BD8D9, 219384019281D7FD, 122AF7252C3959A4 +// shader: 8B30, 64E327B99004DED3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBF5E0C2CF, 64E327B99004DED3 +// program: 5FDE023DED8BD8D9, 219384019281D7FD, 64E327B99004DED3 +// reference: 3F41287A9748F8F3, 122AF7252C3959A4 +// shader: 8B30, 569F0C24FD954D9F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68F5E0C2CF, 569F0C24FD954D9F +// program: 5FDE023DED8BD8D9, 219384019281D7FD, 569F0C24FD954D9F +// shader: 8DD9, 6B49BF5FD5349480 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E0A3E62E72D05152, 6B49BF5FD5349480 +// shader: 8B31, AEEB3BFD499AC881 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + return true; +} +// reference: 9F7707B155F94CCF, AEEB3BFD499AC881 +// shader: 8B30, 1E1DA7BD14376D7D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A5606D6C7, 1E1DA7BD14376D7D +// program: AEEB3BFD499AC881, 6B49BF5FD5349480, 1E1DA7BD14376D7D +// shader: 8B31, 0803AFE644452D2F + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + vs_out_attr1 = mul_s(uniforms.f[90], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + reg_tmp10 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + reg_tmp10.z = (uniforms.f[93].xxxx).z; + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp11.x = dot_s(uniforms.f[24], reg_tmp10); + reg_tmp11.y = dot_s(uniforms.f[25], reg_tmp10); + vs_out_attr2 = reg_tmp11; + return true; +} +// reference: F92C9D494D9D2472, 0803AFE644452D2F +// shader: 8B30, 77A0240D939DC4D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EB53DF9257, 77A0240D939DC4D1 +// program: 0803AFE644452D2F, 219384019281D7FD, 77A0240D939DC4D1 +// shader: 8B30, 2EC9F4ACA5A3A7B9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E684D2020B6, 2EC9F4ACA5A3A7B9 +// program: 0000000000000000, 0000000000000000, 2EC9F4ACA5A3A7B9 +// shader: 8B30, EE9D59D3D057292A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9ADE6A77E, EE9D59D3D057292A +// program: 0000000000000000, 0000000000000000, EE9D59D3D057292A +// shader: 8B30, F789075555A6DC0C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3A146E84CBA07E21, F789075555A6DC0C +// program: 0000000000000000, 0000000000000000, F789075555A6DC0C +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF91254EF14, B35EFE43E319BB63 +// program: 0000000000000000, 0000000000000000, B35EFE43E319BB63 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF95606D6C7, DC12E218392F9BDB +// program: 0000000000000000, 0000000000000000, DC12E218392F9BDB +// shader: 8B30, 828B17C8889F4FA8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF94D2020B6, 828B17C8889F4FA8 +// program: 0000000000000000, 0000000000000000, 828B17C8889F4FA8 +// reference: 393F874199613147, 828B17C8889F4FA8 +// shader: 8DD9, 0CB5B5B0F7196203 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 1EA377C1D7B39071, 0CB5B5B0F7196203 +// shader: 8B31, BED7F6700F066F61 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp12.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp12.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp12.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp12.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp13 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + vs_out_attr2 = -reg_tmp13; + reg_tmp14.x = dot_3(uniforms.f[4].xyz, vs_in_reg1.xyz); + reg_tmp14.y = dot_3(uniforms.f[5].xyz, vs_in_reg1.xyz); + reg_tmp14.z = dot_3(uniforms.f[6].xyz, vs_in_reg1.xyz); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp13.xxxx); + reg_tmp0 = fma_s(reg_tmp13.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp13.zzzz, uniforms.f[2], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp13.wwww, uniforms.f[3], reg_tmp0); + vs_out_attr0.x = dot_s(uniforms.f[12], reg_tmp0); + vs_out_attr0.y = dot_s(uniforms.f[13], reg_tmp0); + vs_out_attr0.z = dot_s(uniforms.f[14], reg_tmp0); + vs_out_attr0.w = dot_s(uniforms.f[15], reg_tmp0); + reg_tmp3.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp14 = mul_s(reg_tmp14, reg_tmp3.xxxx); + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + vs_out_attr1.w = (uniforms.f[93].xxxx).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (!conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + reg_tmp15.x = dot_s(uniforms.f[24], vs_in_reg2); + reg_tmp15.y = dot_s(uniforms.f[25], vs_in_reg2); + vs_out_attr3 = reg_tmp15.xyxy; + return true; +} +bool sub_1() { + vs_out_attr1.z = rcp_s(reg_tmp4.x); + vs_out_attr1.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[93].yxxx).xyz; + return false; +} +// reference: 56E1EBAD1E286F01, BED7F6700F066F61 +// shader: 8B30, 3F95FA4CDF49A5CC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F5948199253F255D, 3F95FA4CDF49A5CC +// program: BED7F6700F066F61, 0CB5B5B0F7196203, 3F95FA4CDF49A5CC +// shader: 8B30, B2D9632ABBEDDF7C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F59481998DDAF78D, B2D9632ABBEDDF7C +// program: BED7F6700F066F61, 0CB5B5B0F7196203, B2D9632ABBEDDF7C +// reference: C84F815321A1D33E, 64E327B99004DED3 +// reference: D28A11C24309E902, 122AF7252C3959A4 +// reference: C84F8153879E83A6, 77A0240D939DC4D1 +// shader: 8B31, FF41EB28B75E0357 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp7.xyz = (mul_s(uniforms.f[95].zzzz, vs_in_reg1.xyzz)).xyz; + address_registers.xy = ivec2(vs_in_reg7.xy); + reg_tmp2 = mul_s(uniforms.f[95].yyyy, vs_in_reg6); + reg_tmp3.x = dot_s(uniforms.f[16 + address_registers.x], vs_in_reg0); + reg_tmp3.y = dot_s(uniforms.f[17 + address_registers.x], vs_in_reg0); + reg_tmp3.z = dot_s(uniforms.f[18 + address_registers.x], vs_in_reg0); + reg_tmp4.x = dot_s(uniforms.f[16 + address_registers.y], vs_in_reg0); + reg_tmp4.y = dot_s(uniforms.f[17 + address_registers.y], vs_in_reg0); + reg_tmp4.z = dot_s(uniforms.f[18 + address_registers.y], vs_in_reg0); + reg_tmp8.x = dot_3(uniforms.f[16 + address_registers.x].xyz, reg_tmp7.xyz); + reg_tmp0 = mul_s(reg_tmp3, reg_tmp2.xxxx); + reg_tmp8.y = dot_3(uniforms.f[17 + address_registers.x].xyz, reg_tmp7.xyz); + reg_tmp8.z = dot_3(uniforms.f[18 + address_registers.x].xyz, reg_tmp7.xyz); + reg_tmp0 = fma_s(reg_tmp4, reg_tmp2.yyyy, reg_tmp0); + address_registers.xy = ivec2(vs_in_reg7.zw); + reg_tmp5.x = dot_s(uniforms.f[16 + address_registers.x], vs_in_reg0); + reg_tmp5.y = dot_s(uniforms.f[17 + address_registers.x], vs_in_reg0); + reg_tmp5.z = dot_s(uniforms.f[18 + address_registers.x], vs_in_reg0); + reg_tmp6.x = dot_s(uniforms.f[16 + address_registers.y], vs_in_reg0); + reg_tmp6.y = dot_s(uniforms.f[17 + address_registers.y], vs_in_reg0); + reg_tmp6.z = dot_s(uniforms.f[18 + address_registers.y], vs_in_reg0); + vs_out_attr1.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = fma_s(reg_tmp5, reg_tmp2.zzzz, reg_tmp0); + reg_tmp0 = fma_s(reg_tmp6, reg_tmp2.wwww, reg_tmp0); + reg_tmp1 = mul_s(uniforms.f[4], reg_tmp8.xxxx); + reg_tmp1 = fma_s(reg_tmp8.yyyy, uniforms.f[5], reg_tmp1); + reg_tmp8 = fma_s(reg_tmp8.zzzz, uniforms.f[6], reg_tmp1); + reg_tmp1 = mul_s(uniforms.f[8], reg_tmp8.xxxx); + reg_tmp1 = fma_s(reg_tmp8.yyyy, uniforms.f[9], reg_tmp1); + reg_tmp1 = fma_s(reg_tmp8.zzzz, uniforms.f[10], reg_tmp1); + reg_tmp1.w = (uniforms.f[93].xxxx).w; + reg_tmp14.x = dot_s(reg_tmp1, reg_tmp1); + reg_tmp14.x = rsq_s(reg_tmp14.x); + reg_tmp14 = mul_s(reg_tmp1, reg_tmp14.xxxx); + reg_tmp1 = mul_s(uniforms.f[4], reg_tmp0.xxxx); + reg_tmp1 = fma_s(reg_tmp0.yyyy, uniforms.f[5], reg_tmp1); + reg_tmp1 = fma_s(reg_tmp0.zzzz, uniforms.f[6], reg_tmp1); + reg_tmp12 = uniforms.f[7] + reg_tmp1; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + reg_tmp5.x = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[12]); + reg_tmp5.y = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[13]); + reg_tmp5.z = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[14]); + vs_out_attr2 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + reg_tmp5.xyz = (mul_s(uniforms.f[15].yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp5.xyz = (min(uniforms.f[93].yyyy, reg_tmp5.xyzz)).xyz; + vs_out_attr1.xyz = (max(uniforms.f[15].xxxx, reg_tmp5.xyzz)).xyz; + return true; +} +// reference: F92C9D49FB91BF5B, FF41EB28B75E0357 +// shader: 8B30, 0C1A07FE5F49464A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0C3B4BDD5D9ADF91, 0C1A07FE5F49464A +// program: FF41EB28B75E0357, 219384019281D7FD, 0C1A07FE5F49464A +// shader: 8DD9, 86F5543306698380 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z, vtx.attributes[2].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5144ABDD19096853, 86F5543306698380 +// shader: 8B31, 40365C0F18D9BEA4 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp7.xyz = (mul_s(uniforms.f[95].zzzz, vs_in_reg1.xyzz)).xyz; + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[4], reg_tmp7.xxxx); + reg_tmp0 = fma_s(reg_tmp7.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp7 = fma_s(reg_tmp7.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp7.xxxx); + reg_tmp0 = fma_s(reg_tmp7.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp7.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp0.w = (uniforms.f[93].xxxx).w; + reg_tmp14.x = dot_s(reg_tmp0, reg_tmp0); + reg_tmp14.x = rsq_s(reg_tmp14.x); + reg_tmp14 = mul_s(reg_tmp0, reg_tmp14.xxxx); + vs_out_attr1 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + vs_out_attr2.w = (uniforms.f[93].yyyy).w; + reg_tmp5.x = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[12]); + reg_tmp5.y = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[13]); + reg_tmp5.z = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[14]); + reg_tmp0.w = (uniforms.f[93].xxxx).w; + reg_tmp0.xyz = (uniforms.f[93].xxxx + -reg_tmp15.xyzz).xyz; + reg_tmp9 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp9 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp9); + reg_tmp9 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp9); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp9); + reg_tmp1.x = dot_s(reg_tmp0, reg_tmp0); + reg_tmp1.x = rsq_s(reg_tmp1.x); + reg_tmp1 = mul_s(reg_tmp0, reg_tmp1.xxxx); + reg_tmp5.xyz = (max(uniforms.f[93].xxxx, reg_tmp5.xyzz)).xyz; + reg_tmp0 = reg_tmp14 + reg_tmp1; + reg_tmp0.w = (uniforms.f[93].xxxx).w; + reg_tmp3.x = dot_s(reg_tmp0, reg_tmp0); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp3 = mul_s(reg_tmp0, reg_tmp3.xxxx); + reg_tmp4.x = dot_3(reg_tmp14.xyz, reg_tmp3.xyz); + reg_tmp4.x = (-uniforms.f[15].zzzz + reg_tmp4.xxxx).x; + reg_tmp4.x = (max(uniforms.f[93].xxxx, reg_tmp4.xxxx)).x; + reg_tmp4.x = (mul_s(uniforms.f[15].wwww, reg_tmp4.xxxx)).x; + reg_tmp4.x = (min(uniforms.f[93].yyyy, reg_tmp4.xxxx)).x; + reg_tmp5.xyz = (mul_s(uniforms.f[15].yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp5.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp8.xyz = (reg_tmp5.xyzz + reg_tmp7.xyzz).xyz; + reg_tmp8.xyz = (min(uniforms.f[93].yyyy, reg_tmp8.xyzz)).xyz; + vs_out_attr2.xyz = (max(uniforms.f[15].xxxx, reg_tmp8.xyzz)).xyz; + return true; +} +// reference: 303395F651B0C9D2, 40365C0F18D9BEA4 +// program: 40365C0F18D9BEA4, 86F5543306698380, 0C1A07FE5F49464A +// reference: E1F0726589DBCE60, 0C1A07FE5F49464A +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B31, E851AE1EF9626EE7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0 = vs_in_reg0; + vs_out_attr1 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + vs_out_attr2 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + vs_out_attr3 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + vs_out_attr4 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + return true; +} +// reference: 0D684DCB7AE6429F, E851AE1EF9626EE7 +// shader: 8B30, E33B80A6E6D92009 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.aaa) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5626548898C55D77, E33B80A6E6D92009 +// program: E851AE1EF9626EE7, 1C4CBC8096EA16CD, E33B80A6E6D92009 +// shader: 8DD9, 075A5034223F1416 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 91BCC71FEF9EA286, 075A5034223F1416 +// shader: 8B31, 256927667DA3C709 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + vs_out_attr2 = mul_s(uniforms.f[94].yyyy, vs_in_reg5); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + return true; +} +// reference: 2807BE1C0E9C4ABF, 256927667DA3C709 +// shader: 8B30, F504B7991F770129 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E1F07265D2C02B09, F504B7991F770129 +// program: 256927667DA3C709, 075A5034223F1416, F504B7991F770129 +// shader: 8B31, 5643621281810DD4 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + reg_tmp10 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + reg_tmp10.z = (uniforms.f[93].xxxx).z; + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp11.x = dot_s(uniforms.f[24], reg_tmp10); + reg_tmp11.y = dot_s(uniforms.f[25], reg_tmp10); + vs_out_attr2 = reg_tmp11; + return true; +} +// reference: F92C9D498D463A13, 5643621281810DD4 +// program: 5643621281810DD4, 219384019281D7FD, 77A0240D939DC4D1 +// shader: 8DD9, 277EE8E572ED8EC1 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[6].x, vtx.attributes[6].y, vtx.attributes[6].z, vtx.attributes[6].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: B7A1AA8AEE71524D, 277EE8E572ED8EC1 +// shader: 8B31, CEB471B0A58E3862 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp6 = vs_in_reg0; + reg_tmp7.x = (mul_s(reg_tmp6.xxxx, reg_tmp6.zzzz)).x; + reg_tmp7.y = (mul_s(uniforms.f[95].zzzz, reg_tmp7.xxxx)).y; + reg_tmp7.y = (abs(reg_tmp7.yyyy)).y; + reg_tmp7.z = (floor(reg_tmp7.yyyy)).z; + reg_tmp7.z = (uniforms.f[94].zzzz + reg_tmp7.zzzz).z; + reg_tmp7.y = (reg_tmp7.yyyy + -reg_tmp7.zzzz).y; + reg_tmp7.z = (floor(reg_tmp7.yyyy)).z; + reg_tmp7.z = (uniforms.f[94].zzzz + reg_tmp7.zzzz).z; + reg_tmp7.y = (reg_tmp7.yyyy + reg_tmp7.zzzz).y; + reg_tmp0.z = (mul_s(uniforms.f[90].wwww, reg_tmp7.yyyy)).z; + reg_tmp6.y = (reg_tmp6.yyyy + reg_tmp0.zzzz).y; + reg_tmp0 = mul_s(uniforms.f[4], reg_tmp6.xxxx); + reg_tmp0 = fma_s(reg_tmp6.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp6.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = fma_s(reg_tmp6.wwww, uniforms.f[7], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + reg_tmp4.x = dot_3(vs_in_reg1.xyz, vs_in_reg1.xyz); + reg_tmp5.x = rsq_s(reg_tmp4.x); + reg_tmp4.x = rcp_s(reg_tmp5.x); + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg1.xxxx); + reg_tmp0 = fma_s(vs_in_reg1.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp8 = fma_s(vs_in_reg1.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp8.xxxx); + reg_tmp0 = fma_s(reg_tmp8.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp14 = fma_s(reg_tmp8.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp14.w = (uniforms.f[93].xxxx).w; + reg_tmp5.x = dot_s(reg_tmp14, reg_tmp14); + reg_tmp5.x = rsq_s(reg_tmp5.x); + reg_tmp5 = mul_s(reg_tmp14, reg_tmp5.xxxx); + reg_tmp14 = mul_s(reg_tmp5, reg_tmp4.xxxx); + reg_tmp14 = mul_s(uniforms.f[95].zzzz, reg_tmp14); + vs_out_attr2 = -reg_tmp15; + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + conditional_code = equal(-uniforms.f[93].yy, reg_tmp14.zz); + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + vs_out_attr1.w = (uniforms.f[93].xxxx).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (!conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + reg_tmp6 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + reg_tmp7.x = (uniforms.f[93].yyyy + reg_tmp0.zzzz).x; + reg_tmp7.x = (mul_s(uniforms.f[94].wwww, reg_tmp7.xxxx)).x; + reg_tmp6.xyz = (mul_s(reg_tmp6.xyzz, reg_tmp7.xxxx)).xyz; + vs_out_attr6 = reg_tmp6; + reg_tmp10 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + reg_tmp10.z = (uniforms.f[93].xxxx).z; + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp11.x = dot_s(uniforms.f[24], reg_tmp10); + reg_tmp11.y = dot_s(uniforms.f[25], reg_tmp10); + reg_tmp10 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + reg_tmp10.z = (uniforms.f[93].xxxx).z; + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp12.x = dot_s(uniforms.f[28], reg_tmp10); + reg_tmp12.y = dot_s(uniforms.f[29], reg_tmp10); + vs_out_attr3 = reg_tmp11; + vs_out_attr4 = reg_tmp12; + vs_out_attr5 = mul_s(uniforms.f[94].yyyy, vs_in_reg5); + return true; +} +bool sub_1() { + vs_out_attr1.z = rcp_s(reg_tmp4.x); + vs_out_attr1.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[93].yxxx).xyz; + return false; +} +// reference: 7D4399FD470FB30A, CEB471B0A58E3862 +// shader: 8B30, 37CA7C39D707153B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor2.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((primary_fragment_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 513D510B6019E9B0, 37CA7C39D707153B +// program: CEB471B0A58E3862, 277EE8E572ED8EC1, 37CA7C39D707153B +// reference: 460D306D67E7DC2E, 77A0240D939DC4D1 +// reference: 8279FAE3BDE38019, 0C1A07FE5F49464A +// shader: 8B31, D5B7307F2C60FE41 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = mul_s(uniforms.f[4], vs_in_reg0.xxxx); + reg_tmp0 = fma_s(vs_in_reg0.yyyy, uniforms.f[5], reg_tmp0); + reg_tmp0 = fma_s(vs_in_reg0.zzzz, uniforms.f[6], reg_tmp0); + reg_tmp12 = uniforms.f[7] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[8], reg_tmp12.xxxx); + reg_tmp0 = fma_s(reg_tmp12.yyyy, uniforms.f[9], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp12.zzzz, uniforms.f[10], reg_tmp0); + reg_tmp15 = fma_s(reg_tmp12.wwww, uniforms.f[11], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[95].yyyy, vs_in_reg3); + reg_tmp0 = mul_s(uniforms.f[0], reg_tmp15.xxxx); + reg_tmp0 = fma_s(reg_tmp15.yyyy, uniforms.f[1], reg_tmp0); + reg_tmp0 = fma_s(reg_tmp15.zzzz, uniforms.f[2], reg_tmp0); + vs_out_attr0 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp0); + vs_out_attr2 = mul_s(uniforms.f[93].wwww, vs_in_reg4); + return true; +} +// reference: F92C9D490551A430, D5B7307F2C60FE41 +// program: D5B7307F2C60FE41, 219384019281D7FD, 77A0240D939DC4D1 diff --git a/cache/00040000000B3500.shader.meta b/cache/00040000000B3500.shader.meta new file mode 100644 index 00000000000..3fe0432821e --- /dev/null +++ b/cache/00040000000B3500.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 35 +reference: 43 +program: 20 diff --git a/cache/00040000000DA000.shader b/cache/00040000000DA000.shader new file mode 100644 index 00000000000..c552f25d842 --- /dev/null +++ b/cache/00040000000DA000.shader @@ -0,0 +1,2200 @@ +// shader: 8B31, B8BC03A278E845A7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp0.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp0.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp0.w = dot_s(uniforms.f[7], vs_in_reg0); + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp0); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp0); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp0); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[95].xxxx, vs_in_reg1.wzyx); + vs_out_attr2 = vs_in_reg2; + return true; +} +// reference: B9CFB6D82FCD13CF, B8BC03A278E845A7 +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B30, 12433E7DDE265EFC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A1254EF14, 12433E7DDE265EFC +// program: B8BC03A278E845A7, 219384019281D7FD, 12433E7DDE265EFC +// reference: E52EE676AC3875BD, B8BC03A278E845A7 +// shader: 8B30, 4DFD84F1D4CE3747 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 66BB775680AB8AE4, 4DFD84F1D4CE3747 +// program: B8BC03A278E845A7, 219384019281D7FD, 4DFD84F1D4CE3747 +// shader: 8B30, 6934EFAB6214C050 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 66BB7756754F0661, 6934EFAB6214C050 +// program: B8BC03A278E845A7, 219384019281D7FD, 6934EFAB6214C050 +// shader: 8B30, 122AF7252C3959A4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A12097B5D, 122AF7252C3959A4 +// program: 0000000000000000, 0000000000000000, 122AF7252C3959A4 +// shader: 8B31, B3BA993F3884A0DD + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + vs_out_attr1 = vs_in_reg1.xyxy; + return true; +} +// reference: 168B249F85084B30, B3BA993F3884A0DD +// shader: 8DD9, CA7A5FBE4D339F65 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[1].z, vtx.attributes[1].w); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 4A90D8FC4D93BB15, CA7A5FBE4D339F65 +// program: B3BA993F3884A0DD, CA7A5FBE4D339F65, 12433E7DDE265EFC +// reference: 4A6A743106FD2D42, B3BA993F3884A0DD +// shader: 8B30, 2C483463ACBF24A9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287ABAB13DC4, 2C483463ACBF24A9 +// program: B3BA993F3884A0DD, CA7A5FBE4D339F65, 2C483463ACBF24A9 +// shader: 8B30, C5B689A94B459F54 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +float ProcTexLookupLUT(int offset, float coord) { + coord *= 128.0; + float index_i = clamp(floor(coord), 0.0, 127.0); + float index_f = coord - index_i; // fract() cannot be used here because 128.0 needs to be + // extracted as index_i = 127.0 and index_f = 1.0 + vec2 entry = texelFetch(texture_buffer_lut_rg, int(index_i) + offset).rg; + return clamp(entry.r + entry.g * index_f, 0.0, 1.0); +} + vec4 SampleProcTexColor(float lut_coord, int level) { +int lut_width = 255 >> level; +int lut_offsets[8] = int[](0, 128, 192, 224, 0xF0, 0xF8, 0xFC, 0xFE); +int lut_offset = lut_offsets[level]; +lut_coord *= float(lut_width - 1); +lut_coord += float(lut_offset); +return texelFetch(texture_buffer_lut_rgba, int(round(lut_coord)) + proctex_lut_offset); +} +vec4 ProcTex() { +vec2 uv = abs(texcoord2); +float u_shift = 0.0; +float v_shift = 0.0; +float u = uv.x + u_shift; +float v = uv.y + v_shift; +u = mix(u, 0.0, u > 1.0); +v = mix(v, 0.0, v > 1.0); +float lut_coord = ProcTexLookupLUT(proctex_color_map_offset, u); +vec4 final_color = SampleProcTexColor(lut_coord, 0); +return final_color; +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) - (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) + (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((combiner_buffer.r) - (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 1.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((ProcTex().rgb) * (last_tex_env_out.aaa) + (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (vec3(1.0) - (last_tex_env_out.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((combiner_buffer.r) - (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3 * 1.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.aaa) + (combiner_buffer.rgb) * (vec3(1.0) - (last_tex_env_out.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((rounded_primary_color.a) - (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 1.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) + (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) != alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F08419E0664CA7E7, C5B689A94B459F54 +// program: 0000000000000000, 0000000000000000, C5B689A94B459F54 +// shader: 8B30, 4F691F5A00C1A34B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287ADFA24D27, 4F691F5A00C1A34B +// program: 0000000000000000, 0000000000000000, 4F691F5A00C1A34B +// reference: 3F41287A4B65F6DC, 122AF7252C3959A4 +// shader: 8B30, EAD385646656F9C4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) - (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) + (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rrr) + (combiner_buffer.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3 * 1.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rrr) + (combiner_buffer.bbb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 4.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((1.0 - last_tex_env_out.a) * (last_tex_env_out.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52EE755D3ED2276A, EAD385646656F9C4 +// program: 0000000000000000, 0000000000000000, EAD385646656F9C4 +// reference: 3F41287A4B386295, 12433E7DDE265EFC +// reference: 3F41287AE3DDB045, 2C483463ACBF24A9 +// shader: 8B30, BEE6D99B785EA1A0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rrr) + (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.b); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 1.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 82BF8CF159E7107B, BEE6D99B785EA1A0 +// program: 0000000000000000, 0000000000000000, BEE6D99B785EA1A0 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF90F6A5B46, DC12E218392F9BDB +// program: 0000000000000000, 0000000000000000, DC12E218392F9BDB +// shader: 8B30, ECACC28486ECD4F1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((combiner_buffer.rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) - (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) + (last_tex_env_out.g), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((combiner_buffer.b) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0A58247ACA2506B4, ECACC28486ECD4F1 +// program: 0000000000000000, 0000000000000000, ECACC28486ECD4F1 +// reference: 66BB7756D9C70765, 4DFD84F1D4CE3747 diff --git a/cache/00040000000DA000.shader.meta b/cache/00040000000DA000.shader.meta new file mode 100644 index 00000000000..f533dbb7a39 --- /dev/null +++ b/cache/00040000000DA000.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 15 +reference: 21 +program: 12 diff --git a/cache/00040000000F4F00.shader b/cache/00040000000F4F00.shader new file mode 100644 index 00000000000..9631b8ecd45 --- /dev/null +++ b/cache/00040000000F4F00.shader @@ -0,0 +1,10421 @@ +// shader: 8B31, FFE98BFD78A1887A + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + vs_out_attr1 = vs_in_reg1; + vs_out_attr2.xy = (vs_in_reg2).xy; + vs_out_attr2.zw = (uniforms.f[95].zzzz).zw; + return true; +} +// reference: 1F81254758BF01C1, FFE98BFD78A1887A +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B30, 569F0C24FD954D9F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68BF687954, 569F0C24FD954D9F +// program: FFE98BFD78A1887A, 219384019281D7FD, 569F0C24FD954D9F +// shader: 8B31, 13C529912A6257B9 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + vs_out_attr1 = vs_in_reg1; + return true; +} +// reference: 73095C9B3869B819, 13C529912A6257B9 +// shader: 8DD9, CBBC43C38774091B + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 6D98C2C476DC3F58, CBBC43C38774091B +// shader: 8B30, 55DC97714BEADD97 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9FEBE905E, 55DC97714BEADD97 +// program: 13C529912A6257B9, CBBC43C38774091B, 55DC97714BEADD97 +// reference: 3D5DA3DBBB9CDE6B, 13C529912A6257B9 +// shader: 8B30, B0DCFFF3C0FF493B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E6853DF9257, B0DCFFF3C0FF493B +// program: FFE98BFD78A1887A, 219384019281D7FD, B0DCFFF3C0FF493B +// shader: 8B31, E556587907894A6B + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_1(); +bool sub_0(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_5() { + address_registers.y = (ivec2(reg_tmp11.zz)).y; + reg_tmp13 = floor(reg_tmp0.xxxx); + reg_tmp13 = reg_tmp0.xxxx + -reg_tmp13; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_6(); + } + conditional_code = lessThanEqual(uniforms.f[5].yy, reg_tmp11.xy); + if (!conditional_code.y) { + sub_15(); + } else { + sub_22(); + } + return false; +} +bool sub_6() { + reg_tmp12.xy = (uniforms.f[5].xyyy + vs_in_reg0.zwww).xy; + reg_tmp14.xy = (uniforms.f[6].wzzz).xy; + reg_tmp13.xy = (mul_s(uniforms.f[5].zzzz, reg_tmp0.xxxx)).xy; + reg_tmp13.y = (floor(reg_tmp13)).y; + reg_tmp13.x = (reg_tmp13.xxxx + -reg_tmp13.yyyy).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_7(); + } + reg_tmp14.xy = (mul_s(reg_tmp14, reg_tmp2)).xy; + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_8(); + } + if (conditional_code.x) { + sub_9(); + } + reg_tmp14.xy = (uniforms.f[5].yyyy + -reg_tmp14.xyyy).xy; + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_10(); + } + if (conditional_code.x) { + sub_11(); + } + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_12(); + } + if (conditional_code.x) { + sub_13(); + } + reg_tmp13.xy = (mul_s(uniforms.f[5].zzzz, reg_tmp0.xxxx)).xy; + reg_tmp13.y = (floor(reg_tmp13)).y; + reg_tmp13.x = (reg_tmp13.xxxx + -reg_tmp13.yyyy).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_14(); + } + reg_tmp12.y = (uniforms.f[5].yyyy + -reg_tmp12.yyyy).y; + return false; +} +bool sub_7() { + reg_tmp14.xy = (reg_tmp14.yxxx).xy; + return false; +} +bool sub_8() { + reg_tmp12.x = (mul_s(reg_tmp12.xxxx, reg_tmp14.xxxx)).x; + return false; +} +bool sub_9() { + reg_tmp12.y = (fma_s(reg_tmp12.yyyy, reg_tmp14.yyyy, uniforms.f[5].yyyy)).y; + reg_tmp12.y = (reg_tmp12.yyyy + -reg_tmp14.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp12.x = (reg_tmp12.xxxx + reg_tmp14.xxxx).x; + return false; +} +bool sub_11() { + reg_tmp12.y = (reg_tmp12.yyyy + -reg_tmp14.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp12.x = (uniforms.f[5].yyyy + -reg_tmp12.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp12.y = (uniforms.f[5].yyyy + -reg_tmp12.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp12.xy = (uniforms.f[5].yyyy + -reg_tmp12.yxxx).xy; + return false; +} +bool sub_15() { + reg_tmp13.x = (floor(reg_tmp0.xxxx)).x; + reg_tmp13.x = (reg_tmp0.xxxx + -reg_tmp13).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + reg_tmp13 = uniforms.f[32 + address_registers.y].wzyx; + if (conditional_code.x) { + sub_16(); + } else { + sub_17(); + } + reg_tmp11.z = (uniforms.f[5].yyyy + reg_tmp11.zzzz).z; + return false; +} +bool sub_16() { + reg_tmp11.xy = (fma_s(reg_tmp12.xyyy, reg_tmp13.xyyy, reg_tmp13.zwww)).xy; + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp14.zwww)).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_17() { + conditional_code = notEqual(uniforms.f[5].xx, vs_in_reg0.zw); + if (!conditional_code.x) { + sub_18(); + } else { + sub_19(); + } + if (!conditional_code.y) { + sub_20(); + } else { + sub_21(); + } + return false; +} +bool sub_18() { + reg_tmp11.x = (reg_tmp13.xxxx).x; + return false; +} +bool sub_19() { + reg_tmp11.x = (reg_tmp13.zzzz).x; + return false; +} +bool sub_20() { + reg_tmp11.y = (reg_tmp13.yyyy).y; + return false; +} +bool sub_21() { + reg_tmp11.y = (reg_tmp13.wwww).y; + return false; +} +bool sub_22() { + if (!conditional_code.x) { + sub_23(); + } else { + sub_32(); + } + reg_tmp11.z = (uniforms.f[5].zzzz + reg_tmp11.zzzz).z; + return false; +} +bool sub_23() { + reg_tmp13.x = (floor(reg_tmp0.xxxx)).x; + reg_tmp13.x = (reg_tmp0.xxxx + -reg_tmp13).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_24(); + } else { + sub_25(); + } + return false; +} +bool sub_24() { + reg_tmp12.zw = (uniforms.f[5].xxxy).zw; + reg_tmp11.x = dot_s(uniforms.f[32 + address_registers.y].wzyx, reg_tmp12); + reg_tmp11.y = dot_s(uniforms.f[33 + address_registers.y].wzyx, reg_tmp12); + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp14.zwww)).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_25() { + reg_tmp14 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp13 = uniforms.f[33 + address_registers.y].wzyx; + conditional_code = notEqual(uniforms.f[5].xx, vs_in_reg0.zw); + if (!conditional_code.y) { + sub_26(); + } else { + sub_29(); + } + return false; +} +bool sub_26() { + if (!conditional_code.x) { + sub_27(); + } else { + sub_28(); + } + return false; +} +bool sub_27() { + reg_tmp11.xy = (reg_tmp14.xyyy).xy; + return false; +} +bool sub_28() { + reg_tmp11.xy = (reg_tmp13.zwww).xy; + return false; +} +bool sub_29() { + if (!conditional_code.x) { + sub_30(); + } else { + sub_31(); + } + return false; +} +bool sub_30() { + reg_tmp11.xy = (reg_tmp13.xyyy).xy; + return false; +} +bool sub_31() { + reg_tmp11.xy = (reg_tmp14.zwww).xy; + return false; +} +bool sub_32() { + reg_tmp11.x = dot_s(uniforms.f[32 + address_registers.y].wzyx, reg_tmp1); + reg_tmp11.y = dot_s(uniforms.f[33 + address_registers.y].wzyx, reg_tmp1); + return false; +} +bool sub_1() { + uint jmp_to = 97u; + while (true) { + switch (jmp_to) { + case 97u: { + reg_tmp3.x = dot_s(uniforms.f[32 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.y = dot_s(uniforms.f[33 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.z = dot_s(uniforms.f[34 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp11 = uniforms.f[4].wzyx; + reg_tmp11.z = (-uniforms.f[34 + address_registers.x].xxxx + reg_tmp11.zzzz).z; + conditional_code.x = uniforms.f[5].xxxx.x != reg_tmp11.xzzz.x; + conditional_code.y = uniforms.f[5].xxxx.y < reg_tmp11.xzzz.y; + if (any(not(conditional_code))) { + { jmp_to = 108u; break; } + } + reg_tmp11.z = rcp_s(reg_tmp11.z); + reg_tmp3.x = (reg_tmp3.xxxx + reg_tmp11.xxxx).x; + reg_tmp3.x = (fma_s(-reg_tmp11.yyyy, reg_tmp11.zzzz, reg_tmp3.xxxx)).x; + } + case 108u: { + } + default: return false; + } + } + return false; +} +bool sub_0() { + uint jmp_to = 109u; + while (true) { + switch (jmp_to) { + case 109u: { + address_registers.x = (ivec2(vs_in_reg0.xx)).x; + reg_tmp0 = uniforms.f[9 + address_registers.x].wzyx; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (uniforms.f[5].xyxy).zw; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp2 = uniforms.f[32 + address_registers.y].wzyx; + if (uniforms.b[0]) { + { jmp_to = 191u; break; } + } + reg_tmp4 = uniforms.f[31 + address_registers.x].wzyx; + reg_tmp1.xy = (fma_s(reg_tmp1.xyyy, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + conditional_code = greaterThanEqual(uniforms.f[5].yy, reg_tmp0.ww); + if (all(conditional_code)) { + sub_2(); + } else { + sub_3(); + } + reg_tmp11.z = (reg_tmp0.zzzz).z; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp0.zzzz); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[6].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[1]) { + sub_33(); + } + if (uniforms.b[2]) { + sub_34(); + } + vs_out_attr2 = reg_tmp11.xyyy; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp9.xxxx); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[7].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[3]) { + sub_35(); + } + if (uniforms.b[4]) { + sub_36(); + } + vs_out_attr3 = reg_tmp11.xyyy; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp9.xxxx); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[8].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[5]) { + sub_37(); + } + if (uniforms.b[6]) { + sub_38(); + } + vs_out_attr4 = reg_tmp11.xyyy; + return true; + } + case 191u: { + reg_tmp1.xy = (mul_s(uniforms.f[36 + address_registers.x].wzzz, reg_tmp1.xyyy)).xy; + reg_tmp14 = uniforms.f[35 + address_registers.x].wzyx; + reg_tmp1.xy = (fma_s(reg_tmp1.xyyy, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp14.x = (fma_s(reg_tmp14.xxxx, vs_in_reg0.wwww, reg_tmp14.xxxx)).x; + reg_tmp1.xy = (uniforms.f[36 + address_registers.x].yxxx + reg_tmp1.xyyy).xy; + reg_tmp11.y = (fma_s(reg_tmp2.yyyy, uniforms.f[36 + address_registers.x].zzzz, -reg_tmp2.yyyy)).y; + reg_tmp1.x = (reg_tmp1.xxxx + reg_tmp14.xxxx).x; + reg_tmp1.y = (reg_tmp1.yyyy + reg_tmp11.yyyy).y; + { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + if (uniforms.b[2]) { + sub_39(); + } else { + sub_40(); + } + vs_out_attr2 = reg_tmp9; + reg_tmp8 = reg_tmp8 + -reg_tmp7; + vs_out_attr3 = reg_tmp9; + vs_out_attr1 = fma_s(reg_tmp8, reg_tmp11.yyyy, reg_tmp7); + vs_out_attr4 = reg_tmp9; + return true; + } + default: return false; + } + } + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[5].yyyy).xyz; + vs_out_attr1.w = (reg_tmp0.wwww).w; + return false; +} +bool sub_3() { + address_registers.y = (ivec2(reg_tmp0.ww)).y; + reg_tmp7 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp8 = uniforms.f[33 + address_registers.y].wzyx; + reg_tmp9 = uniforms.f[34 + address_registers.y].wzyx; + reg_tmp10 = uniforms.f[35 + address_registers.y].wzyx; + reg_tmp11.xy = (vs_in_reg0.zwww).xy; + reg_tmp14.x = (floor(reg_tmp0.yyyy)).x; + reg_tmp14.x = (reg_tmp0.yyyy + -reg_tmp14.xxxx).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp14.xx); + if (conditional_code.x) { + sub_4(); + } + reg_tmp11.xy = (abs(reg_tmp11.xyyy)).xy; + reg_tmp8 = reg_tmp8 + -reg_tmp7; + reg_tmp8 = fma_s(reg_tmp8, reg_tmp11.xxxx, reg_tmp7); + reg_tmp10 = reg_tmp10 + -reg_tmp9; + reg_tmp10 = fma_s(reg_tmp10, reg_tmp11.xxxx, reg_tmp9); + reg_tmp10 = reg_tmp10 + -reg_tmp8; + reg_tmp10 = fma_s(reg_tmp10, reg_tmp11.yyyy, reg_tmp8); + vs_out_attr1 = reg_tmp10; + return false; +} +bool sub_4() { + reg_tmp11.z = rcp_s(reg_tmp4.x); + reg_tmp11.w = rcp_s(reg_tmp4.y); + reg_tmp11.xy = (reg_tmp1.xyyy + -reg_tmp4.zwww).xy; + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp11.zwww)).xy; + return false; +} +bool sub_33() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_34() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_35() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_36() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_37() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_38() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_39() { + reg_tmp11 = abs(vs_in_reg0.zwzw); + address_registers.xy = ivec2(reg_tmp0.zx); + reg_tmp9.xy = (mul_s(uniforms.f[32 + address_registers.x].yxxx, reg_tmp11)).xy; + reg_tmp11.zw = (vec4(lessThan(reg_tmp11, uniforms.f[5].yyyy))).zw; + reg_tmp7 = uniforms.f[37 + address_registers.y].wzyx; + reg_tmp9.xy = (fma_s(reg_tmp11.zwww, uniforms.f[32 + address_registers.x].wzzz, reg_tmp9.xyyy)).xy; + reg_tmp8 = uniforms.f[38 + address_registers.y].wzyx; + reg_tmp9.y = (uniforms.f[5].yyyy + -reg_tmp9.yyyy).y; + return false; +} +bool sub_40() { + reg_tmp11 = abs(vs_in_reg0.zwzw); + address_registers.xy = ivec2(reg_tmp0.zw); + reg_tmp9.xy = (mul_s(uniforms.f[32 + address_registers.x].yxxx, reg_tmp11)).xy; + reg_tmp11.zw = (vec4(lessThan(reg_tmp11, uniforms.f[5].yyyy))).zw; + reg_tmp7 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp9.xy = (fma_s(reg_tmp11.zwww, uniforms.f[32 + address_registers.x].wzzz, reg_tmp9.xyyy)).xy; + reg_tmp8 = uniforms.f[33 + address_registers.y].wzyx; + reg_tmp9.y = (uniforms.f[5].yyyy + -reg_tmp9.yyyy).y; + return false; +} +// reference: CEB8602353667F8C, E556587907894A6B +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B30, 2B730240EE2A8461 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1F78A60766D02152, 2B730240EE2A8461 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 2B730240EE2A8461 +// reference: D4F4BEF9FF7CFA69, 55DC97714BEADD97 +// reference: 80EC9F63D09319FE, E556587907894A6B +// reference: CE312E68BEAA1363, 569F0C24FD954D9F +// shader: 8B31, 0CE520D37808507E + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 7) in vec4 vs_in_reg7; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_6(); +bool sub_7(); +bool sub_17(); +bool sub_5(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_28(); +bool sub_27(); +bool sub_29(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_2(); + } else { + sub_3(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_4(); + } else { + sub_6(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_2() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_3() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_4() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_5(); + } + return false; +} +bool sub_6() { + if (all(conditional_code)) { + sub_7(); + } else { + sub_17(); + } + return false; +} +bool sub_7() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_8(); + } + return false; +} +bool sub_17() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_5() { + uint jmp_to = 73u; + while (true) { + switch (jmp_to) { + case 73u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 89u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 89u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 89u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_8() { + uint jmp_to = 90u; + while (true) { + switch (jmp_to) { + case 90u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 165u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 127u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 165u; break; } + } + } + case 127u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_9(); + } else { + sub_14(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 165u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_9() { + if (conditional_code.y) { + sub_10(); + } else { + sub_11(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_10() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_11() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_12(); + } else { + sub_13(); + } + return false; +} +bool sub_12() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_14() { + if (conditional_code.y) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_18() { + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9 = uniforms.f[21]; + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (conditional_code.y) { + sub_19(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_19() { + if (uniforms.b[7]) { + sub_20(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_20() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_21() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_22(); + } else { + sub_23(); + } + return false; +} +bool sub_22() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_23() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_24(); + } else { + sub_25(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_24() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_25() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_28(); + } + return false; +} +bool sub_26() { + { + sub_27(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_28() { + { + sub_29(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_27() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_29() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_0() { + { + sub_1(); + } + { + sub_18(); + } + { + sub_21(); + } + return true; +} +// reference: E89BB720A6CF8513, 0CE520D37808507E +// shader: 8DD9, D7255673101445A5 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: CD8210802464D9AE, D7255673101445A5 +// shader: 8B30, 7A80AFF5AE16D1CE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68154432C2, 7A80AFF5AE16D1CE +// program: 0CE520D37808507E, D7255673101445A5, 7A80AFF5AE16D1CE +// reference: A6CF4860253AE361, 0CE520D37808507E +// shader: 8B31, 309449F9A45EF787 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_20(); +bool sub_3(); +bool sub_8(); +bool sub_1(); +bool sub_2(); +bool sub_4(); +bool sub_6(); +bool sub_7(); +bool sub_9(); +bool sub_19(); +bool sub_21(); +bool sub_5(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_30(); +bool sub_32(); +bool sub_31(); +bool sub_33(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_20() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_3() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_8() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_2(); + } else { + sub_6(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_2() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_3(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_3(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_3(); + } + if (uniforms.b[8]) { + sub_4(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_5(); + } + return false; +} +bool sub_4() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_3(); + } + return false; +} +bool sub_6() { + if (all(conditional_code)) { + sub_7(); + } else { + sub_19(); + } + return false; +} +bool sub_7() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_8(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_8(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_8(); + } + if (uniforms.b[8]) { + sub_9(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_10(); + } + return false; +} +bool sub_9() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_8(); + } + return false; +} +bool sub_19() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_20(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_20(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_20(); + } + if (uniforms.b[8]) { + sub_21(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_21() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_20(); + } + return false; +} +bool sub_5() { + uint jmp_to = 139u; + while (true) { + switch (jmp_to) { + case 139u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 155u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 155u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 155u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_10() { + uint jmp_to = 156u; + while (true) { + switch (jmp_to) { + case 156u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 231u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 193u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 231u; break; } + } + } + case 193u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_11(); + } else { + sub_16(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 231u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + if (conditional_code.y) { + sub_12(); + } else { + sub_13(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_12() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_13() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_14(); + } else { + sub_15(); + } + return false; +} +bool sub_14() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_15() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_16() { + if (conditional_code.y) { + sub_17(); + } else { + sub_18(); + } + return false; +} +bool sub_17() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_22() { + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9 = uniforms.f[21]; + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (conditional_code.y) { + sub_23(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_23() { + if (uniforms.b[7]) { + sub_24(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_24() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_25() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_26(); + } else { + sub_27(); + } + return false; +} +bool sub_26() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_27() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_28(); + } else { + sub_29(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_28() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_29() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_30(); + } else { + sub_32(); + } + return false; +} +bool sub_30() { + { + sub_31(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_32() { + { + sub_33(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_31() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_33() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_0() { + { + sub_1(); + } + { + sub_22(); + } + { + sub_25(); + } + return true; +} +// reference: 352F3389001BFA6A, 309449F9A45EF787 +// shader: 8B30, 8068A56094A9B82F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(view)))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(light_vector, normal), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FCD8E8B4D1FA5534, 8068A56094A9B82F +// program: 309449F9A45EF787, D7255673101445A5, 8068A56094A9B82F +// reference: 7B7BCCC983EE9C18, 309449F9A45EF787 +// reference: B251E31DB8835E51, 8068A56094A9B82F +// program: 0CE520D37808507E, D7255673101445A5, 8068A56094A9B82F +// shader: 8B30, 1F0FF69FE90D4A93 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F1700612154432C2, 1F0FF69FE90D4A93 +// program: 0CE520D37808507E, D7255673101445A5, 1F0FF69FE90D4A93 +// shader: 8B30, 61C2DBAB611E2111 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1F78A6079D3050EB, 61C2DBAB611E2111 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 61C2DBAB611E2111 +// shader: 8B30, 61C2DBABF0A11390 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].aaa); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2FC0B94CAD11BE3E, 61C2DBABF0A11390 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 61C2DBABF0A11390 +// shader: 8B30, E102F57E63D9B6D2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1F78A607E20B2914, E102F57E63D9B6D2 +// program: E556587907894A6B, 1C4CBC8096EA16CD, E102F57E63D9B6D2 +// reference: 1F78A6070EBCC217, 2B730240EE2A8461 +// reference: 14F394AE3168D00B, 569F0C24FD954D9F +// reference: 1F78A6078A67CA51, E102F57E63D9B6D2 +// shader: 8B31, DE3C612504843B43 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 7) in vec4 vs_in_reg7; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_6(); +bool sub_7(); +bool sub_17(); +bool sub_5(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_28(); +bool sub_27(); +bool sub_29(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_2(); + } else { + sub_3(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_4(); + } else { + sub_6(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_2() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_3() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_4() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_5(); + } + return false; +} +bool sub_6() { + if (all(conditional_code)) { + sub_7(); + } else { + sub_17(); + } + return false; +} +bool sub_7() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_8(); + } + return false; +} +bool sub_17() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_5() { + uint jmp_to = 73u; + while (true) { + switch (jmp_to) { + case 73u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 89u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 89u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 89u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_8() { + uint jmp_to = 90u; + while (true) { + switch (jmp_to) { + case 90u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[3]) { + { jmp_to = 165u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 127u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 165u; break; } + } + } + case 127u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_9(); + } else { + sub_14(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 165u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_9() { + if (conditional_code.y) { + sub_10(); + } else { + sub_11(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_10() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_11() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_12(); + } else { + sub_13(); + } + return false; +} +bool sub_12() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_14() { + if (conditional_code.y) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_18() { + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9 = uniforms.f[21]; + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (conditional_code.y) { + sub_19(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_19() { + if (uniforms.b[7]) { + sub_20(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_20() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_21() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_22(); + } else { + sub_23(); + } + return false; +} +bool sub_22() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_23() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_24(); + } else { + sub_25(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_24() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_25() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_28(); + } + return false; +} +bool sub_26() { + { + sub_27(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_28() { + { + sub_29(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_27() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_29() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_30() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_31(); + } else { + sub_32(); + } + return false; +} +bool sub_31() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_32() { + if (uniforms.b[13]) { + sub_33(); + } else { + sub_36(); + } + return false; +} +bool sub_33() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_34(); + } else { + sub_35(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_34() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_35() { + { + sub_29(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_36() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_0() { + { + sub_1(); + } + { + sub_18(); + } + { + sub_21(); + } + { + sub_30(); + } + return true; +} +// reference: C22707A864FE6046, DE3C612504843B43 +// shader: 8DD9, 8D88DA9FC6C2B5D9 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[6](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0]); + prim_buffer[1].attributes = vec4[6](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1]); + prim_buffer[2].attributes = vec4[6](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 46A0C2E6B155D5CD, 8D88DA9FC6C2B5D9 +// shader: 8B30, EDFE4D29A2228D1D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 187F32654444EADC, EDFE4D29A2228D1D +// program: DE3C612504843B43, 8D88DA9FC6C2B5D9, EDFE4D29A2228D1D +// shader: 8B30, D6FA0068212AA82E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 01EA52BED85F9839, D6FA0068212AA82E +// program: 0CE520D37808507E, D7255673101445A5, D6FA0068212AA82E +// shader: 8B30, 41B070A1A5436AF1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 01EA52BE34E8733A, 41B070A1A5436AF1 +// program: 0CE520D37808507E, D7255673101445A5, 41B070A1A5436AF1 +// shader: 8B30, 3AB1ACF7CE11D7A6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(view)))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(light_vector, normal), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8AC222B176F8E7DA, 3AB1ACF7CE11D7A6 +// program: 309449F9A45EF787, D7255673101445A5, 3AB1ACF7CE11D7A6 +// reference: C44B291876F8E7DA, 3AB1ACF7CE11D7A6 +// program: 0CE520D37808507E, D7255673101445A5, 3AB1ACF7CE11D7A6 +// reference: 8AC222B11F81ECBF, 3AB1ACF7CE11D7A6 +// shader: 8B30, 8F9EFEC2ADD2ABAC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(view)))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(light_vector, normal), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((secondary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C44B29189A4F0CD9, 8F9EFEC2ADD2ABAC +// program: 309449F9A45EF787, D7255673101445A5, 8F9EFEC2ADD2ABAC +// shader: 8B31, 236A5600D7718995 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_7(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_7() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp2 = uniforms.f[85]; + reg_tmp2.xz = (-uniforms.f[5 + address_registers.x].xzzz + reg_tmp2.xzzz).xz; + reg_tmp2.yw = (uniforms.f[0].xxxx).yw; + reg_tmp3.x = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp2.xyz = (mul_s(reg_tmp2.xyzz, reg_tmp3.xxxx)).xyz; + reg_tmp4 = uniforms.f[0].xzxx; + reg_tmp5.xyz = (mul_s(reg_tmp2.yzxx, reg_tmp4.zxyy)).xyz; + reg_tmp5.xyz = (fma_s(-reg_tmp4.yzxx, reg_tmp2.zxyy, reg_tmp5)).xyz; + reg_tmp3.x = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp5.xyz = (mul_s(reg_tmp5.xyzz, reg_tmp3.xxxx)).xyz; + reg_tmp6.x = (-reg_tmp5.xxxx).x; + reg_tmp6.y = (-reg_tmp5.yyyy).y; + reg_tmp6.z = (-reg_tmp5.zzzz).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (reg_tmp4.xxxx).x; + reg_tmp7.y = (reg_tmp4.yyyy).y; + reg_tmp7.z = (reg_tmp4.zzzz).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (-reg_tmp2.xxxx).x; + reg_tmp8.y = (-reg_tmp2.yyyy).y; + reg_tmp8.z = (-reg_tmp2.zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + { + sub_2(); + } + reg_tmp14.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp14.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp14.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp14.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp2 = reg_tmp14; + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_7(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: D09FB1D69D4FCB42, 236A5600D7718995 +// shader: 8DD9, 13A54CCD8AA1DDA2 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: A55C6948CCF76B42, 13A54CCD8AA1DDA2 +// shader: 8B30, 010E81557E3052CE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 638DD0E7C5B0CB8F, 010E81557E3052CE +// program: 236A5600D7718995, 13A54CCD8AA1DDA2, 010E81557E3052CE +// shader: 8B31, B7D7D9A3231FFAF5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_6(); +bool sub_4(); +bool sub_5(); +bool sub_0(); +bool sub_2(); +bool sub_3(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_6() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_4() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_5() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp2 = reg_tmp10.xzyw; + reg_tmp2.z = (-reg_tmp2.zzzz).z; + reg_tmp6 = uniforms.f[8 + address_registers.x]; + reg_tmp7 = uniforms.f[9 + address_registers.x]; + reg_tmp8 = uniforms.f[10 + address_registers.x]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5 + address_registers.x].xxxx).w; + reg_tmp7.w = (uniforms.f[5 + address_registers.x].yyyy).w; + reg_tmp8.w = (uniforms.f[5 + address_registers.x].zzzz).w; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_4(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_5(); + } + { + sub_6(); + } + return true; +} +bool sub_2() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_3() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: E3845B87A43FF990, B7D7D9A3231FFAF5 +// program: B7D7D9A3231FFAF5, 13A54CCD8AA1DDA2, 010E81557E3052CE +// shader: 8B30, 0A5EAA1973DA23D0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rrr) * (texcolor0.rrr), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].ggg) + (texcolor0.ggg), vec3(1.0)) * (last_tex_env_out.rrr), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp(min((const_color[1].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8DEA9DF413E2758D, 0A5EAA1973DA23D0 +// program: FFE98BFD78A1887A, 219384019281D7FD, 0A5EAA1973DA23D0 +// reference: E3BB29D41F81ECBF, 3AB1ACF7CE11D7A6 +// reference: 8AC222B1F33607BC, 8F9EFEC2ADD2ABAC +// reference: C44B29181F81ECBF, 3AB1ACF7CE11D7A6 +// shader: 8B30, 8639DF2B4D1FBE60 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].ggg) + (texcolor0.ggg), vec3(1.0)) * (last_tex_env_out.rrr), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp(min((const_color[1].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9C65DD28E857DB72, 8639DF2B4D1FBE60 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 8639DF2B4D1FBE60 +// shader: 8B30, 9DFC1EFFF67EE1B3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp(min((const_color[1].ggg) + (texcolor0.ggg), vec3(1.0)) * (last_tex_env_out.rrr), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp(min((const_color[1].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9C65DD2813B7AACB, 9DFC1EFFF67EE1B3 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 9DFC1EFFF67EE1B3 +// shader: 8B30, 64DBEBE16DD7A5DA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].aaa); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 75C5920D31209980, 64DBEBE16DD7A5DA +// program: E556587907894A6B, 1C4CBC8096EA16CD, 64DBEBE16DD7A5DA +// shader: 8B30, 5F7655DF4F13125E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 457D8D46928DE5A9, 5F7655DF4F13125E +// program: E556587907894A6B, 1C4CBC8096EA16CD, 5F7655DF4F13125E +// shader: 8B31, E9173C43C4058D27 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_6(); +bool sub_4(); +bool sub_5(); +bool sub_0(); +bool sub_2(); +bool sub_3(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_6() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_4() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_5() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp6 = uniforms.f[8 + address_registers.x]; + reg_tmp7 = uniforms.f[9 + address_registers.x]; + reg_tmp8 = uniforms.f[10 + address_registers.x]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5 + address_registers.x].xxxx).w; + reg_tmp7.w = (uniforms.f[5 + address_registers.x].yyyy).w; + reg_tmp8.w = (uniforms.f[5 + address_registers.x].zzzz).w; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp10 = reg_tmp2; + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_4(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_5(); + } + { + sub_6(); + } + return true; +} +bool sub_2() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_3() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 21F9A8E2086AE351, E9173C43C4058D27 +// program: E9173C43C4058D27, 13A54CCD8AA1DDA2, 010E81557E3052CE +// shader: 8B31, 82FA64D3E5406431 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_7(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_7() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp14 = reg_tmp10; + reg_tmp0 = uniforms.f[7 + address_registers.x]; + { + sub_2(); + } + reg_tmp10.x = dot_s(reg_tmp14, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp14, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp14, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp14, reg_tmp9); + reg_tmp6 = uniforms.f[8 + address_registers.x]; + reg_tmp7 = uniforms.f[9 + address_registers.x]; + reg_tmp8 = uniforms.f[10 + address_registers.x]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5 + address_registers.x].xxxx).w; + reg_tmp7.w = (uniforms.f[5 + address_registers.x].yyyy).w; + reg_tmp8.w = (uniforms.f[5 + address_registers.x].zzzz).w; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp10 = reg_tmp2; + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_7(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 700056CEE706D9D8, 82FA64D3E5406431 +// program: 82FA64D3E5406431, 13A54CCD8AA1DDA2, 010E81557E3052CE +// shader: 8B31, AF4C6DC47BD53EE7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_10(); +bool sub_8(); +bool sub_9(); +bool sub_0(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_10() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_8() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_9() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp2.x = (uniforms.f[8 + address_registers.x].yyyy).x; + reg_tmp2.y = (uniforms.f[9 + address_registers.x].yyyy).y; + reg_tmp2.z = (uniforms.f[10 + address_registers.x].yyyy).z; + reg_tmp3.xyz = (uniforms.f[6 + address_registers.x].xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp4.xyz = (mul_s(reg_tmp3.yzxx, reg_tmp2.zxyy)).xyz; + reg_tmp4.xyz = (fma_s(-reg_tmp2.yzxx, reg_tmp3.zxyy, reg_tmp4)).xyz; + reg_tmp5.x = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp5.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp5.y; + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + reg_tmp4.xyz = (mul_s(reg_tmp4.xyzz, reg_tmp5.xxxx)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp3.yzxx, reg_tmp4.zxyy)).xyz; + reg_tmp5.xyz = (fma_s(-reg_tmp4.yzxx, reg_tmp3.zxyy, reg_tmp5)).xyz; + reg_tmp6.x = (reg_tmp4.xxxx).x; + reg_tmp6.y = (reg_tmp3.xxxx).y; + reg_tmp6.z = (reg_tmp5.xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (reg_tmp4.yyyy).x; + reg_tmp7.y = (reg_tmp3.yyyy).y; + reg_tmp7.z = (reg_tmp5.yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (reg_tmp4.zzzz).x; + reg_tmp8.y = (reg_tmp3.zzzz).y; + reg_tmp8.z = (reg_tmp5.zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_6(); + } else { + sub_7(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_8(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_9(); + } + { + sub_10(); + } + return true; +} +bool sub_2() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_3() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +bool sub_4() { + reg_tmp5.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_5() { + reg_tmp5.x = rsq_s(reg_tmp5.x); + return false; +} +bool sub_6() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_7() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 45D2C052BC8D4FBE, AF4C6DC47BD53EE7 +// shader: 8B30, 4294F53622ED4DE2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 917C0F933E737D07, 4294F53622ED4DE2 +// program: AF4C6DC47BD53EE7, 13A54CCD8AA1DDA2, 4294F53622ED4DE2 +// shader: 8B30, 64DBEBE16D5B7C45 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((const_color[2].bbb) + (texcolor0.bbb), vec3(1.0)) * (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp(min((const_color[2].a) + (texcolor0.a), 1.0) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 457D8D46696D9410, 64DBEBE16D5B7C45 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 64DBEBE16D5B7C45 +// reference: 9ECB4E961EBAAD30, 236A5600D7718995 +// shader: 8B30, 2B227ACF9E58F724 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 187F3265F4721C94, 2B227ACF9E58F724 +// program: DE3C612504843B43, 8D88DA9FC6C2B5D9, 2B227ACF9E58F724 +// reference: 8C73F8E8E70B0634, DE3C612504843B43 +// shader: 8B30, C9AFFAC9C29955D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C59E9830B725C632, C9AFFAC9C29955D1 +// program: 0CE520D37808507E, D7255673101445A5, C9AFFAC9C29955D1 +// shader: 8B30, 340EF9EBDECD34C6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 01EA52BE5B922D31, 340EF9EBDECD34C6 +// program: 0CE520D37808507E, D7255673101445A5, 340EF9EBDECD34C6 +// shader: 8B30, 0FB3CAC96CB84854 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 01EA52BEB725C632, 0FB3CAC96CB84854 +// program: 0CE520D37808507E, D7255673101445A5, 0FB3CAC96CB84854 +// shader: 8B30, 441F63DBCC1F6F4A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F17006121519A68B, 441F63DBCC1F6F4A +// program: 0CE520D37808507E, D7255673101445A5, 441F63DBCC1F6F4A +// shader: 8B30, 59A11A9061B839A8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DF5B08A1B725C632, 59A11A9061B839A8 +// program: 0CE520D37808507E, D7255673101445A5, 59A11A9061B839A8 +// shader: 8B30, 7A52835D9F08CA1A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F17006127A63F880, 7A52835D9F08CA1A +// program: 0CE520D37808507E, D7255673101445A5, 7A52835D9F08CA1A +// reference: 51D5DA07DB4A67B3, FFE98BFD78A1887A +// reference: CE312E68521DF860, B0DCFFF3C0FF493B +// reference: 1F78A607F55CB3AE, 61C2DBAB611E2111 +// reference: DB28E8789A80ED41, 8068A56094A9B82F +// shader: 8B30, 6612F09C369FF3C7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C59E983008978E58, 6612F09C369FF3C7 +// program: 0CE520D37808507E, D7255673101445A5, 6612F09C369FF3C7 +// shader: 8B30, 6ED32FCCAAB0AFE4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 794840768412FA77, 6ED32FCCAAB0AFE4 +// program: 0CE520D37808507E, D7255673101445A5, 6ED32FCCAAB0AFE4 +// shader: 8B30, 90DAE1526415F425 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.r) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 01512651D42D400C, 90DAE1526415F425 +// program: 0CE520D37808507E, D7255673101445A5, 90DAE1526415F425 +// reference: 7D8A9FCB136B631B, 569F0C24FD954D9F +// reference: 33039462136B631B, 569F0C24FD954D9F +// shader: 8B30, 2591AB166ACC9026 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EFE2F2ABEC504A7D, 2591AB166ACC9026 +// program: E556587907894A6B, 1C4CBC8096EA16CD, 2591AB166ACC9026 +// reference: 3D5DA3DB60257F2C, 13C529912A6257B9 +// reference: 80EC9F630B2AB8B9, E556587907894A6B +// reference: A6CF4860FE834226, 0CE520D37808507E +// reference: 7B7BCCC958573D5F, 309449F9A45EF787 +// reference: D09FB1D646F66A05, 236A5600D7718995 +// reference: E3845B877F8658D7, B7D7D9A3231FFAF5 +// reference: 8C73F8E83CB2A773, DE3C612504843B43 +// reference: 51D5DA0700F3C6F4, FFE98BFD78A1887A +// reference: 330394627A12687E, 569F0C24FD954D9F +// reference: 436075E9DB4A67B3, FFE98BFD78A1887A +// reference: 2FE80C35BB9CDE6B, 13C529912A6257B9 +// reference: 9259308DD09319FE, E556587907894A6B +// reference: B47AE78E253AE361, 0CE520D37808507E +// reference: 69CE632783EE9C18, 309449F9A45EF787 +// reference: 9EC65706E70B0634, DE3C612504843B43 +// reference: 21F9A8E2D3D34216, E9173C43C4058D27 +// reference: 700056CE3CBF789F, 82FA64D3E5406431 +// reference: E3BB29D43D825FAF, 3AB1ACF7CE11D7A6 +// reference: 2FE80C3560257F2C, 13C529912A6257B9 +// reference: 9259308D0B2AB8B9, E556587907894A6B +// reference: B47AE78EFE834226, 0CE520D37808507E +// reference: 69CE632758573D5F, 309449F9A45EF787 +// reference: C22A1E3846F66A05, 236A5600D7718995 +// reference: F131F4697F8658D7, B7D7D9A3231FFAF5 +// reference: 334C070CD3D34216, E9173C43C4058D27 +// reference: 62B5F9203CBF789F, 82FA64D3E5406431 +// reference: 9EC657063CB2A773, DE3C612504843B43 +// reference: 436075E900F3C6F4, FFE98BFD78A1887A +// reference: 95A1E3D1F3F9E624, 8068A56094A9B82F +// reference: B251E31DD1FA5534, 8068A56094A9B82F +// shader: 8B31, 8673C92174977329 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_7(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_7() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.x = (uniforms.f[90].xxxx).x; + reg_tmp6.y = (uniforms.f[91].xxxx).y; + reg_tmp6.z = (uniforms.f[92].xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (uniforms.f[90].yyyy).x; + reg_tmp7.y = (uniforms.f[91].yyyy).y; + reg_tmp7.z = (uniforms.f[92].yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (uniforms.f[90].zzzz).x; + reg_tmp8.y = (uniforms.f[91].zzzz).y; + reg_tmp8.z = (uniforms.f[92].zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_7(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: D09FB1D6DC9B34B3, 8673C92174977329 +// program: 8673C92174977329, 13A54CCD8AA1DDA2, 010E81557E3052CE +// reference: 1F812547DB4A67B3, FFE98BFD78A1887A +// reference: 73095C9BBB9CDE6B, 13C529912A6257B9 +// reference: 76040746D09319FE, E556587907894A6B +// reference: E89BB720253AE361, 0CE520D37808507E +// reference: 352F338983EE9C18, 309449F9A45EF787 +// reference: C22707A8E70B0634, DE3C612504843B43 +// reference: 9ECB4E969D4FCB42, 236A5600D7718995 +// reference: ADD0A4C7A43FF990, B7D7D9A3231FFAF5 +// reference: CEB86023D09319FE, E556587907894A6B +// reference: 42927FAB253AE361, 0CE520D37808507E +// reference: 9F26FB0283EE9C18, 309449F9A45EF787 +// reference: 682ECF23E70B0634, DE3C612504843B43 +// reference: 6FAD57A2086AE351, E9173C43C4058D27 +// reference: 3E54A98EE706D9D8, 82FA64D3E5406431 diff --git a/cache/00040000000F4F00.shader.meta b/cache/00040000000F4F00.shader.meta new file mode 100644 index 00000000000..0ceffa31639 --- /dev/null +++ b/cache/00040000000F4F00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 52 +reference: 119 +program: 40 diff --git a/cache/00040000000F5600.shader b/cache/00040000000F5600.shader new file mode 100644 index 00000000000..7c45d06dde0 --- /dev/null +++ b/cache/00040000000F5600.shader @@ -0,0 +1,1995 @@ +// shader: 8DD9, 6B49BF5FD5349480 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E0A3E62E72D05152, 6B49BF5FD5349480 +// shader: 8B31, 2D8701BBC536727F + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + reg_tmp1.x = dot_s(uniforms.f[4], vs_in_reg1); + reg_tmp1.y = dot_s(uniforms.f[5], vs_in_reg1); + reg_tmp1.z = dot_s(uniforms.f[6], vs_in_reg1); + vs_out_attr1 = reg_tmp1; + return true; +} +// reference: C0B2EE4103F50E87, 2D8701BBC536727F +// shader: 8B30, B1800659FBAEDBE8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EB38BCB869, B1800659FBAEDBE8 +// program: 2D8701BBC536727F, 6B49BF5FD5349480, B1800659FBAEDBE8 +// shader: 8B30, 64E327B99004DED3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EB3D65FCF9, 64E327B99004DED3 +// program: 0000000000000000, 0000000000000000, 64E327B99004DED3 +// shader: 8B30, 12433E7DDE265EFC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A1254EF14, 12433E7DDE265EFC +// program: 0000000000000000, 0000000000000000, 12433E7DDE265EFC +// program: 0000000000000000, 0000000000000000, B1800659FBAEDBE8 +// shader: 8DD9, 6F77F38530E7A871 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +struct Vertex { + vec4 attributes[1]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[1](vs_out_attr0[0]); + prim_buffer[1].attributes = vec4[1](vs_out_attr0[1]); + prim_buffer[2].attributes = vec4[1](vs_out_attr0[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: B0EECBB083D64E3E, 6F77F38530E7A871 +// shader: 8B31, C822628E6801C3D8 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + return true; +} +// reference: EA0E5EC915E89AEB, C822628E6801C3D8 +// program: C822628E6801C3D8, 6F77F38530E7A871, 12433E7DDE265EFC +// shader: 8B30, 807AACB0D7DCFE15 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBB3FCC71C, 807AACB0D7DCFE15 +// program: 2D8701BBC536727F, 6B49BF5FD5349480, 807AACB0D7DCFE15 +// shader: 8B31, 33769F0374C7C8E5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0.xy = (mul_s(uniforms.f[95].yyyy, vs_in_reg3.xyyy)).xy; + reg_tmp3.w = (uniforms.f[95].xxxx).w; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp0.x = dot_s(uniforms.f[7 + address_registers.x], vs_in_reg0); + reg_tmp0.y = dot_s(uniforms.f[8 + address_registers.x], vs_in_reg0); + reg_tmp0.z = dot_s(uniforms.f[9 + address_registers.x], vs_in_reg0); + reg_tmp2.x = dot_s(uniforms.f[7 + address_registers.y], vs_in_reg0); + reg_tmp2.y = dot_s(uniforms.f[8 + address_registers.y], vs_in_reg0); + reg_tmp2.z = dot_s(uniforms.f[9 + address_registers.y], vs_in_reg0); + vs_out_attr1 = vs_in_reg1; + reg_tmp1.xyz = (mul_s(reg_tmp0.xyzz, vs_in_reg2.xxxx)).xyz; + reg_tmp3.xyz = (fma_s(reg_tmp2.xyzz, vs_in_reg2.yyyy, reg_tmp1)).xyz; + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp3); + return true; +} +// reference: 281CD77AC2B91C90, 33769F0374C7C8E5 +// program: 33769F0374C7C8E5, 6B49BF5FD5349480, 807AACB0D7DCFE15 +// program: 33769F0374C7C8E5, 6B49BF5FD5349480, B1800659FBAEDBE8 +// program: 0000000000000000, 0000000000000000, 807AACB0D7DCFE15 +// shader: 8B30, F631E732B70C6568 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBD40B536A, F631E732B70C6568 +// program: 0000000000000000, 0000000000000000, F631E732B70C6568 +// shader: 8B30, DD9437BD492683CC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287AFEE30417, DD9437BD492683CC +// program: C822628E6801C3D8, 6F77F38530E7A871, DD9437BD492683CC +// shader: 8B30, 6BD252B7AE7B55EB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) + (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EE8532624F94B738, 6BD252B7AE7B55EB +// program: 2D8701BBC536727F, 6B49BF5FD5349480, 6BD252B7AE7B55EB +// shader: 8B30, 122AF7252C3959A4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A4A4476CD, 122AF7252C3959A4 +// program: 0000000000000000, 0000000000000000, 122AF7252C3959A4 +// program: 33769F0374C7C8E5, 6B49BF5FD5349480, 6BD252B7AE7B55EB +// shader: 8B30, EB119A638099AB3B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) + (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EE853262C4D4C84D, EB119A638099AB3B +// program: 33769F0374C7C8E5, 6B49BF5FD5349480, EB119A638099AB3B +// shader: 8B30, F137550F390629AD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBB625838C, F137550F390629AD +// program: 0000000000000000, 0000000000000000, F137550F390629AD +// program: 2D8701BBC536727F, 6B49BF5FD5349480, EB119A638099AB3B diff --git a/cache/00040000000F5600.shader.meta b/cache/00040000000F5600.shader.meta new file mode 100644 index 00000000000..955d2faabea --- /dev/null +++ b/cache/00040000000F5600.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 15 +reference: 15 +program: 17 diff --git a/cache/0004000000127900.shader b/cache/0004000000127900.shader new file mode 100644 index 00000000000..dd47be33364 --- /dev/null +++ b/cache/0004000000127900.shader @@ -0,0 +1,5399 @@ +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B31, FC7F4467554D34E5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.x = (ivec2(vs_in_reg0.xy)).x; + reg_tmp0 = uniforms.f[6 + address_registers.x].wzyx; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (uniforms.f[5].xyxy).zw; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp2.xw = (uniforms.f[64 + address_registers.y].wwyy).xw; + reg_tmp2.yz = (uniforms.f[5].xxxx).yz; + reg_tmp4.x = dot_s(reg_tmp1, reg_tmp2); + reg_tmp2.yw = (uniforms.f[64 + address_registers.y].zzxx).yw; + reg_tmp2.xz = (uniforms.f[5].xxxx).xz; + reg_tmp4.y = dot_s(reg_tmp1, reg_tmp2); + reg_tmp4.zw = (reg_tmp1.zwzw).zw; + reg_tmp3.x = dot_s(uniforms.f[32 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.y = dot_s(uniforms.f[33 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.z = dot_s(uniforms.f[34 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp4.z = (uniforms.f[34 + address_registers.x].xxxx).z; + reg_tmp4.z = (abs(reg_tmp4.zzzz)).z; + reg_tmp4.z = (uniforms.f[4].yyyy + reg_tmp4.zzzz).z; + reg_tmp4.x = (uniforms.f[4].wwww).x; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp4.xz); + if (all(conditional_code)) { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + conditional_code = greaterThanEqual(uniforms.f[5].yy, reg_tmp0.ww); + if (all(conditional_code)) { + sub_2(); + } else { + sub_3(); + } + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_8(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_9(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_10(); + } + if (all(conditional_code)) { + sub_11(); + } + reg_tmp8 = uniforms.f[5].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop64 = 0u; loop64 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop64) { + sub_12(); + } + vs_out_attr2 = reg_tmp5; + vs_out_attr3 = reg_tmp6; + vs_out_attr4 = reg_tmp7; + return true; +} +bool sub_1() { + reg_tmp4.x = (uniforms.f[4].wwww).x; + reg_tmp4.y = (-uniforms.f[4].zzzz + reg_tmp4.zzzz).y; + reg_tmp4.z = rcp_s(reg_tmp4.z); + reg_tmp4.z = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).z; + reg_tmp3.x = (fma_s(reg_tmp4.xxxx, reg_tmp4.zzzz, reg_tmp3.xxxx)).x; + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[5].yyyy).xyz; + vs_out_attr1.w = (reg_tmp0.wwww).w; + return false; +} +bool sub_3() { + address_registers.y = (ivec2(reg_tmp0.ww)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_4(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_5(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_6(); + } + if (all(conditional_code)) { + sub_7(); + } + return false; +} +bool sub_4() { + vs_out_attr1 = uniforms.f[32 + address_registers.y].wzyx; + return false; +} +bool sub_5() { + vs_out_attr1 = uniforms.f[33 + address_registers.y].wzyx; + return false; +} +bool sub_6() { + vs_out_attr1 = uniforms.f[34 + address_registers.y].wzyx; + return false; +} +bool sub_7() { + vs_out_attr1 = uniforms.f[35 + address_registers.y].wzyx; + return false; +} +bool sub_8() { + reg_tmp5 = uniforms.f[5].xyyy; + reg_tmp6 = uniforms.f[5].xyyy; + reg_tmp7 = uniforms.f[5].xyyy; + return false; +} +bool sub_9() { + reg_tmp5 = uniforms.f[5].yyyy; + reg_tmp6 = uniforms.f[5].yyyy; + reg_tmp7 = uniforms.f[5].yyyy; + return false; +} +bool sub_10() { + reg_tmp5 = uniforms.f[5].xxyy; + reg_tmp6 = uniforms.f[5].xxyy; + reg_tmp7 = uniforms.f[5].xxyy; + return false; +} +bool sub_11() { + reg_tmp5 = uniforms.f[5].yxyy; + reg_tmp6 = uniforms.f[5].yxyy; + reg_tmp7 = uniforms.f[5].yxyy; + return false; +} +bool sub_12() { + conditional_code = equal(uniforms.f[5].yy, reg_tmp8.xy); + if (all(conditional_code)) { + sub_13(); + } + conditional_code = lessThan(uniforms.f[5].ww, reg_tmp8.xy); + if (all(conditional_code)) { + sub_18(); + } + reg_tmp8 = uniforms.f[5].yyyy + reg_tmp8; + return false; +} +bool sub_13() { + address_registers.y = (ivec2(reg_tmp0.zz)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_14(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_15(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_16(); + } + if (all(conditional_code)) { + sub_17(); + } + return false; +} +bool sub_14() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wzzz).xy; + return false; +} +bool sub_15() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yzzz).xy; + return false; +} +bool sub_16() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wxxx).xy; + return false; +} +bool sub_17() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yxxx).xy; + return false; +} +bool sub_18() { + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_19(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_20(); + } + return false; +} +bool sub_19() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].yxxx).xy; + return false; +} +bool sub_20() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].wzzz).xy; + return false; +} +// reference: FDD61A83F31AC733, FC7F4467554D34E5 +// shader: 8B30, 366110D84E9DF41B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B2FC2A64491E03D2, 366110D84E9DF41B +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 366110D84E9DF41B +// shader: 8B30, 7B661124FF63EFE0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DF242EBD0705B568, 7B661124FF63EFE0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 7B661124FF63EFE0 +// shader: 8B30, C92C9AC2ABA7597D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B2FC2A6434B8DF12, C92C9AC2ABA7597D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C92C9AC2ABA7597D +// shader: 8B30, DEFA7038414DC454 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E13EE878D6EA57C7, DEFA7038414DC454 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, DEFA7038414DC454 +// shader: 8B30, 7FC52171B72CA41E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E13EE8789812DEDD, 7FC52171B72CA41E +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 7FC52171B72CA41E +// shader: 8B30, 5BE034A6DDC1A541 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2EA60C875715417D, 5BE034A6DDC1A541 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 5BE034A6DDC1A541 +// shader: 8B30, 793BF2BC7357C4E9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 437E085E57F67EDD, 793BF2BC7357C4E9 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 793BF2BC7357C4E9 +// shader: 8B30, BB44F2152BA0C50B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2EA60C8719EDC867, BB44F2152BA0C50B +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, BB44F2152BA0C50B +// shader: 8B30, 9617AD46CC652257 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8CE6ECA1D6096867, 9617AD46CC652257 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9617AD46CC652257 +// shader: 8B30, 77A0240D939DC4D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBE429BB4E, 77A0240D939DC4D1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 77A0240D939DC4D1 +// shader: 8B30, 8D0607EDE8EB5157 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 34639C16DB5D5E7B, 8D0607EDE8EB5157 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 8D0607EDE8EB5157 +// shader: 8B30, 1D7FE821816F04FA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (last_tex_env_out.rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (last_tex_env_out.a) + (combiner_buffer.a) * (1.0 - (last_tex_env_out.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2A7C6A9BADB328D7, 1D7FE821816F04FA +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 1D7FE821816F04FA +// shader: 8B30, D08938563E3F9062 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 34639C1695A5D761, D08938563E3F9062 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D08938563E3F9062 +// shader: 8B30, C4349459EF6C8FBC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FBFB78E95AA248C1, C4349459EF6C8FBC +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C4349459EF6C8FBC +// shader: 8B30, F47864933AAE7E2C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F01756989A4DA18E, F47864933AAE7E2C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F47864933AAE7E2C +// shader: 8B30, F3FFBA78739CED98 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F8FB2671BB2B734, F3FFBA78739CED98 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F3FFBA78739CED98 +// shader: 8B30, 1A56FD3742CD423B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 59BB98CFDBBE61DB, 1A56FD3742CD423B +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 1A56FD3742CD423B +// shader: 8DD9, 0D30074279C2FEED + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[6].x, vtx.attributes[6].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: FC74FA4ACA1C8C74, 0D30074279C2FEED +// shader: 8B31, AD59F7578304A674 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_21(); +bool sub_4(); +bool sub_9(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_10(); +bool sub_20(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_6(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_44(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_45(); +bool sub_46(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_55(); +bool sub_57(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_56(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_66(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + { + sub_1(); + } + { + sub_30(); + } + { + sub_45(); + } + { + sub_59(); + } + { + sub_66(); + } + return true; +} +bool sub_21() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_4() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_9() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_23(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_3(); + } else { + sub_7(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_4(); + } + if (uniforms.b[8]) { + sub_5(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_5() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_4(); + } + return false; +} +bool sub_7() { + if (all(conditional_code)) { + sub_8(); + } else { + sub_20(); + } + return false; +} +bool sub_8() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_9(); + } + if (uniforms.b[8]) { + sub_10(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_20() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_21(); + } + if (uniforms.b[8]) { + sub_22(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_22() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_21(); + } + return false; +} +bool sub_23() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_24(); + } else { + sub_25(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_27(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_24() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_25() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_26() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_27() { + if (all(conditional_code)) { + sub_28(); + } else { + sub_29(); + } + return false; +} +bool sub_28() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_11(); + } + return false; +} +bool sub_29() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_6() { + uint jmp_to = 202u; + while (true) { + switch (jmp_to) { + case 202u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 218u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 218u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 218u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + uint jmp_to = 219u; + while (true) { + switch (jmp_to) { + case 219u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 294u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 256u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 294u; break; } + } + } + case 256u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_12(); + } else { + sub_17(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 294u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_12() { + if (conditional_code.y) { + sub_13(); + } else { + sub_14(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_14() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_17() { + if (conditional_code.y) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_19() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_30() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_31(); + } + if (uniforms.b[12]) { + sub_33(); + } + if (uniforms.b[5]) { + sub_42(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_44(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_31() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_32(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_32() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_44() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_33() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop315 = 0u; loop315 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop315) { + sub_34(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_34() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[81 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[83 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_35(); + } else { + sub_36(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_41(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_35() { + reg_tmp6.x = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_36() { + reg_tmp4 = uniforms.f[81 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_37(); + } + reg_tmp5 = uniforms.f[82 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_38(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_37() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[83 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_38() { + reg_tmp5.x = dot_3(uniforms.f[82 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[84 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_39(); + } else { + sub_40(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_39() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_40() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[84 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_41() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[80 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_42() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_43(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_43() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_46(); + } else { + sub_52(); + } + return false; +} +bool sub_46() { + { + sub_47(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_52() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_53(); + } else { + sub_54(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_53() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_54() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + { + sub_56(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_57() { + { + sub_58(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_49(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_48() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_49() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_50(); + } else { + sub_51(); + } + return false; +} +bool sub_50() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_56() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_58() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_59() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_60(); + } else { + sub_61(); + } + return false; +} +bool sub_60() { + { + sub_47(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_61() { + if (uniforms.b[13]) { + sub_62(); + } else { + sub_65(); + } + return false; +} +bool sub_62() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_63(); + } else { + sub_64(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_63() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_64() { + { + sub_58(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_65() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_66() { + reg_tmp0.xy = (uniforms.f[10].zzzz).xy; + if (uniforms.b[11]) { + sub_67(); + } else { + sub_68(); + } + return false; +} +bool sub_67() { + { + sub_47(); + } + reg_tmp5.x = dot_s(uniforms.f[17].xywz, reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18].xywz, reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_68() { + if (uniforms.b[14]) { + sub_69(); + } else { + sub_70(); + } + return false; +} +bool sub_69() { + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp5.zw = (reg_tmp6.zwww).zw; + { + sub_58(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_70() { + vs_out_attr6 = uniforms.f[93].xxxx; + return false; +} +// reference: 7614F88BB7A5CAAA, AD59F7578304A674 +// shader: 8B30, 5C0CDCAC7B1B6A0E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F7F99D96B732BFA0, 5C0CDCAC7B1B6A0E +// program: AD59F7578304A674, 0D30074279C2FEED, 5C0CDCAC7B1B6A0E +// shader: 8B30, 43689BD301C482A9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0E26330F6F69C929, 43689BD301C482A9 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 43689BD301C482A9 +// shader: 8B30, 5FEA786FD710439C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0E26330F21914033, 5FEA786FD710439C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 5FEA786FD710439C +// shader: 8B30, 9766C2BB3C8FB31A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 63FE37D66F8AF689, 9766C2BB3C8FB31A +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9766C2BB3C8FB31A +// shader: 8B30, 0A5A086706435C42 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C1BED7F0EE96DF93, 0A5A086706435C42 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 0A5A086706435C42 +// shader: 8B30, A21480100F866010 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FFA41135AE56BF60, A21480100F866010 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, A21480100F866010 diff --git a/cache/0004000000127900.shader.meta b/cache/0004000000127900.shader.meta new file mode 100644 index 00000000000..1001f443856 --- /dev/null +++ b/cache/0004000000127900.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 27 +reference: 27 +program: 23 diff --git a/cache/0004000000131E00.shader b/cache/0004000000131E00.shader new file mode 100644 index 00000000000..079271cddd3 --- /dev/null +++ b/cache/0004000000131E00.shader @@ -0,0 +1,17577 @@ +// shader: 8B31, AC1E05AC1AB5ABAD + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp15.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp15.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp15.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp15.w = dot_s(uniforms.f[7], vs_in_reg0); + reg_tmp14.z = (vs_in_reg0.zzzz).z; + reg_tmp15.z = (uniforms.f[93].xxxx).z; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.z = (abs(reg_tmp14.zzzz)).z; + reg_tmp14.z = (uniforms.f[91].zzzz + reg_tmp14.zzzz).z; + reg_tmp14.x = (uniforms.f[91].xxxx).x; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp14.xz); + if (all(conditional_code)) { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp15); + vs_out_attr1 = vs_in_reg1; + return true; +} +bool sub_1() { + reg_tmp14.x = (uniforms.f[91].xxxx).x; + reg_tmp14.y = (-uniforms.f[91].yyyy + reg_tmp14.zzzz).y; + reg_tmp14.z = rcp_s(reg_tmp14.z); + reg_tmp14.z = (mul_s(reg_tmp14.yyyy, reg_tmp14.zzzz)).z; + reg_tmp15.x = (fma_s(reg_tmp14.xxxx, reg_tmp14.zzzz, reg_tmp15.xxxx)).x; + return false; +} +// reference: 9821948648D1E191, AC1E05AC1AB5ABAD +// shader: 8DD9, CBBC43C38774091B + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 6D98C2C476DC3F58, CBBC43C38774091B +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF94A19E284, B35EFE43E319BB63 +// program: AC1E05AC1AB5ABAD, CBBC43C38774091B, B35EFE43E319BB63 +// shader: 8B31, 4AC344BC6E622851 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp15.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp15.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp15.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp15.w = dot_s(uniforms.f[7], vs_in_reg0); + reg_tmp14.z = (vs_in_reg0.zzzz).z; + reg_tmp15.z = (uniforms.f[93].xxxx).z; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.z = (abs(reg_tmp14.zzzz)).z; + reg_tmp14.z = (uniforms.f[91].zzzz + reg_tmp14.zzzz).z; + reg_tmp14.x = (uniforms.f[91].xxxx).x; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp14.xz); + if (all(conditional_code)) { + sub_1(); + } + reg_tmp1.x = dot_s(uniforms.f[0], reg_tmp15); + reg_tmp1.y = dot_s(uniforms.f[1], reg_tmp15); + reg_tmp1.z = dot_s(uniforms.f[2], reg_tmp15); + reg_tmp1.w = dot_s(uniforms.f[3], reg_tmp15); + reg_tmp2.xy = (mul_s(uniforms.f[92].xyyy, -reg_tmp1.wwww)).xy; + conditional_code.x = reg_tmp1.xxxx.x < reg_tmp2.xyyy.x; + conditional_code.y = reg_tmp1.xxxx.y > reg_tmp2.xyyy.y; + if (all(conditional_code)) { + sub_2(); + } + vs_out_attr0 = reg_tmp1; + vs_out_attr1 = vs_in_reg1; + vs_out_attr2 = vs_in_reg2; + return true; +} +bool sub_1() { + reg_tmp14.x = (uniforms.f[91].xxxx).x; + reg_tmp14.y = (-uniforms.f[91].yyyy + reg_tmp14.zzzz).y; + reg_tmp14.z = rcp_s(reg_tmp14.z); + reg_tmp14.z = (mul_s(reg_tmp14.yyyy, reg_tmp14.zzzz)).z; + reg_tmp15.x = (fma_s(reg_tmp14.xxxx, reg_tmp14.zzzz, reg_tmp15.xxxx)).x; + return false; +} +bool sub_2() { + reg_tmp1.x = (-reg_tmp1.wwww).x; + return false; +} +// reference: 376506C196BDC838, 4AC344BC6E622851 +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B30, 7974F3663498993D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF91328FB4C, 7974F3663498993D +// program: 4AC344BC6E622851, 219384019281D7FD, 7974F3663498993D +// reference: 7931F9811548AE4A, 4AC344BC6E622851 +// shader: 8B30, 9A4719A519F0D3B1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68D672CA48, 9A4719A519F0D3B1 +// program: 4AC344BC6E622851, 219384019281D7FD, 9A4719A519F0D3B1 +// shader: 8B30, F6B6F838D1CE558E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10807477763B8BAF, F6B6F838D1CE558E +// program: 4AC344BC6E622851, 219384019281D7FD, F6B6F838D1CE558E +// shader: 8B30, 30B703594147E54C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9E2FC3054, 30B703594147E54C +// program: 4AC344BC6E622851, 219384019281D7FD, 30B703594147E54C +// reference: D6756BC6CB2487E3, AC1E05AC1AB5ABAD +// shader: 8B30, 370761F478D5E560 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2FC15C0D763B8BAF, 370761F478D5E560 +// program: 4AC344BC6E622851, 219384019281D7FD, 370761F478D5E560 +// shader: 8B30, 0803E1FD60D3E38E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EBB596834A19E284, 0803E1FD60D3E38E +// program: AC1E05AC1AB5ABAD, CBBC43C38774091B, 0803E1FD60D3E38E +// reference: 887AAA0C83086634, 9A4719A519F0D3B1 +// reference: 56CBF013234127D3, F6B6F838D1CE558E +// reference: 698AD869234127D3, 370761F478D5E560 +// reference: 92BF3A9D46525730, 7974F3663498993D +// shader: 8B31, 4CE8EC673CE76DDE + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.xy = ivec2(vs_in_reg3.xy); + reg_tmp1.w = dot_3(uniforms.f[10 + address_registers.x].xyz, vs_in_reg0.xyz); + reg_tmp3.w = dot_3(uniforms.f[10 + address_registers.y].xyz, vs_in_reg0.xyz); + reg_tmp1.xyz = (mul_s(-uniforms.f[10 + address_registers.x].zxyy, vs_in_reg0.yzxx)).xyz; + reg_tmp3.xyz = (mul_s(-uniforms.f[10 + address_registers.y].zxyy, vs_in_reg0.yzxx)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg0.zxyy, uniforms.f[10 + address_registers.x].yzxx, reg_tmp1.xyzz)).xyz; + reg_tmp3.xyz = (fma_s(vs_in_reg0.zxyy, uniforms.f[10 + address_registers.y].yzxx, reg_tmp3.xyzz)).xyz; + reg_tmp1.xyz = (fma_s(vs_in_reg0.xyzz, uniforms.f[10 + address_registers.x].wwww, reg_tmp1)).xyz; + reg_tmp3.xyz = (fma_s(vs_in_reg0.xyzz, uniforms.f[10 + address_registers.y].wwww, reg_tmp3)).xyz; + reg_tmp0 = mul_s(uniforms.f[94].xxxx, vs_in_reg3); + reg_tmp14.w = dot_3(uniforms.f[10 + address_registers.x].xyz, -reg_tmp1.xyz); + reg_tmp15.w = dot_3(uniforms.f[10 + address_registers.y].xyz, -reg_tmp3.xyz); + reg_tmp14.xyz = (mul_s(uniforms.f[10 + address_registers.x].yzxx, reg_tmp1.zxyy)).xyz; + reg_tmp15.xyz = (mul_s(uniforms.f[10 + address_registers.y].yzxx, reg_tmp3.zxyy)).xyz; + reg_tmp14.xyz = (fma_s(-reg_tmp1.yzxx, uniforms.f[10 + address_registers.x].zxyy, reg_tmp14.xyzz)).xyz; + reg_tmp15.xyz = (fma_s(-reg_tmp3.yzxx, uniforms.f[10 + address_registers.y].zxyy, reg_tmp15.xyzz)).xyz; + reg_tmp14.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[10 + address_registers.x].wwww, reg_tmp14.xyzz)).xyz; + reg_tmp15.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[10 + address_registers.y].wwww, reg_tmp15.xyzz)).xyz; + reg_tmp14 = fma_s(reg_tmp1.wwww, uniforms.f[10 + address_registers.x], reg_tmp14); + reg_tmp15 = fma_s(reg_tmp3.wwww, uniforms.f[10 + address_registers.y], reg_tmp15); + reg_tmp14 = mul_s(uniforms.f[11 + address_registers.x].wwww, reg_tmp14); + reg_tmp15 = mul_s(uniforms.f[11 + address_registers.y].wwww, reg_tmp15); + reg_tmp14 = uniforms.f[11 + address_registers.x] + reg_tmp14; + reg_tmp15 = uniforms.f[11 + address_registers.y] + reg_tmp15; + reg_tmp14 = mul_s(reg_tmp14, reg_tmp0.zzzz); + reg_tmp14 = fma_s(reg_tmp15, reg_tmp0.wwww, reg_tmp14); + reg_tmp15.x = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[0]); + reg_tmp15.y = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[1]); + reg_tmp15.z = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[2]); + vs_out_attr0.x = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[87]); + vs_out_attr0.z = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[88]); + vs_out_attr0.w = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[89]); + return true; +} +// reference: B29D240EA2170139, 4CE8EC673CE76DDE +// shader: 8DD9, 6F77F38530E7A871 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +struct Vertex { + vec4 attributes[1]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(0.0, 0.0); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[1](vs_out_attr0[0]); + prim_buffer[1].attributes = vec4[1](vs_out_attr0[1]); + prim_buffer[2].attributes = vec4[1](vs_out_attr0[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: B0EECBB083D64E3E, 6F77F38530E7A871 +// reference: FCC9DB4E21E2674B, 4CE8EC673CE76DDE +// shader: 8B31, CABD7FF7677EC71E + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.xy = ivec2(vs_in_reg3.xy); + reg_tmp1.w = dot_3(uniforms.f[10 + address_registers.x].xyz, vs_in_reg0.xyz); + reg_tmp3.w = dot_3(uniforms.f[10 + address_registers.y].xyz, vs_in_reg0.xyz); + reg_tmp1.xyz = (mul_s(-uniforms.f[10 + address_registers.x].zxyy, vs_in_reg0.yzxx)).xyz; + reg_tmp3.xyz = (mul_s(-uniforms.f[10 + address_registers.y].zxyy, vs_in_reg0.yzxx)).xyz; + reg_tmp2 = uniforms.f[10 + address_registers.x]; + reg_tmp1.xyz = (fma_s(vs_in_reg0.zxyy, uniforms.f[10 + address_registers.x].yzxx, reg_tmp1.xyzz)).xyz; + reg_tmp3.xyz = (fma_s(vs_in_reg0.zxyy, uniforms.f[10 + address_registers.y].yzxx, reg_tmp3.xyzz)).xyz; + reg_tmp2 = vec4(dot_s(uniforms.f[10 + address_registers.y], reg_tmp2)); + reg_tmp1.xyz = (fma_s(vs_in_reg0.xyzz, uniforms.f[10 + address_registers.x].wwww, reg_tmp1)).xyz; + reg_tmp3.xyz = (fma_s(vs_in_reg0.xyzz, uniforms.f[10 + address_registers.y].wwww, reg_tmp3)).xyz; + reg_tmp0 = mul_s(uniforms.f[94].xxxx, vs_in_reg3); + conditional_code = lessThanEqual(uniforms.f[93].xx, reg_tmp2.xy); + reg_tmp13.w = dot_3(uniforms.f[10 + address_registers.x].xyz, -reg_tmp1.xyz); + reg_tmp14.w = dot_3(uniforms.f[10 + address_registers.y].xyz, -reg_tmp3.xyz); + reg_tmp15 = mul_s(uniforms.f[10 + address_registers.x], reg_tmp0.zzzz); + reg_tmp13.xyz = (mul_s(uniforms.f[10 + address_registers.x].yzxx, reg_tmp1.zxyy)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[10 + address_registers.y].yzxx, reg_tmp3.zxyy)).xyz; + if (conditional_code.x) { + sub_1(); + } else { + sub_2(); + } + reg_tmp13.xyz = (fma_s(-reg_tmp1.yzxx, uniforms.f[10 + address_registers.x].zxyy, reg_tmp13.xyzz)).xyz; + reg_tmp14.xyz = (fma_s(-reg_tmp3.yzxx, uniforms.f[10 + address_registers.y].zxyy, reg_tmp14.xyzz)).xyz; + reg_tmp2 = vec4(dot_s(reg_tmp15, reg_tmp15)); + vs_out_attr3 = vs_in_reg1.xyxy; + reg_tmp13.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[10 + address_registers.x].wwww, reg_tmp13.xyzz)).xyz; + reg_tmp14.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[10 + address_registers.y].wwww, reg_tmp14.xyzz)).xyz; + reg_tmp2 = vec4(rsq_s(reg_tmp2.x)); + reg_tmp13 = fma_s(reg_tmp1.wwww, uniforms.f[10 + address_registers.x], reg_tmp13); + reg_tmp14 = fma_s(reg_tmp3.wwww, uniforms.f[10 + address_registers.y], reg_tmp14); + reg_tmp15 = mul_s(reg_tmp15, reg_tmp2.xxxx); + reg_tmp13 = mul_s(uniforms.f[11 + address_registers.x].wwww, reg_tmp13); + reg_tmp14 = mul_s(uniforms.f[11 + address_registers.y].wwww, reg_tmp14); + reg_tmp2.w = dot_3(reg_tmp15.xyz, -vs_in_reg2.xyz); + reg_tmp13 = uniforms.f[11 + address_registers.x] + reg_tmp13; + reg_tmp14 = uniforms.f[11 + address_registers.y] + reg_tmp14; + reg_tmp2.xyz = (mul_s(reg_tmp15.yzxx, vs_in_reg2.zxyy)).xyz; + reg_tmp13 = mul_s(reg_tmp13, reg_tmp0.zzzz); + reg_tmp13 = fma_s(reg_tmp14, reg_tmp0.wwww, reg_tmp13); + reg_tmp2.xyz = (fma_s(reg_tmp15.zxyy, -vs_in_reg2.yzxx, reg_tmp2.xyzz)).xyz; + reg_tmp14.x = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[0]); + reg_tmp14.y = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[1]); + reg_tmp14.z = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[2]); + reg_tmp2.xyz = (fma_s(reg_tmp15.wwww, vs_in_reg2.xyzz, reg_tmp2.xyzz)).xyz; + vs_out_attr2 = vs_in_reg1; + reg_tmp6 = fma_s(reg_tmp15, vs_in_reg2.wwww, reg_tmp2); + vs_out_attr4 = uniforms.f[90] + -reg_tmp14; + reg_tmp7.w = dot_3(uniforms.f[3].xyz, -reg_tmp6.xyz); + vs_out_attr0.x = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[86]); + reg_tmp7.xyz = (mul_s(uniforms.f[3].yzxx, reg_tmp6.zxyy)).xyz; + vs_out_attr0.y = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[87]); + reg_tmp7.xyz = (fma_s(-reg_tmp6.yzxx, uniforms.f[3].zxyy, reg_tmp7.xyzz)).xyz; + vs_out_attr0.z = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[88]); + reg_tmp7.xyz = (fma_s(reg_tmp6.xyzz, uniforms.f[3].wwww, reg_tmp7.xyzz)).xyz; + vs_out_attr0.w = dot_s(vec4(reg_tmp14.xyz, 1.0), uniforms.f[89]); + vs_out_attr1 = fma_s(reg_tmp6.wwww, uniforms.f[3], reg_tmp7); + return true; +} +bool sub_1() { + reg_tmp15 = fma_s(reg_tmp0.wwww, uniforms.f[10 + address_registers.y], reg_tmp15); + return false; +} +bool sub_2() { + reg_tmp15 = fma_s(reg_tmp0.wwww, -uniforms.f[10 + address_registers.y], reg_tmp15); + return false; +} +// reference: E586DB637C92A987, CABD7FF7677EC71E +// shader: 8DD9, BCFD13684549D2B2 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = vtx.attributes[2].z; + view = vec3(vtx.attributes[4].x, vtx.attributes[4].y, vtx.attributes[4].z); + texcoord2 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 4FE46847320F1EC0, BCFD13684549D2B2 +// shader: 8B30, A453279F963EF650 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) * geo_factor) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (vec3(1.0) - const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.aaa) * (vec3(1.0) - const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3C111F917CCF1C45, A453279F963EF650 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, A453279F963EF650 +// shader: 8B30, 8FFF40937EB91414 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) * geo_factor) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (vec3(1.0) - primary_fragment_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8E74321337F25F17, 8FFF40937EB91414 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 8FFF40937EB91414 +// shader: 8B30, 7639F41487FD0FB0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) * geo_factor) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - texcolor1.aaa) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 33BFCAC4F731C3E1, 7639F41487FD0FB0 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 7639F41487FD0FB0 +// shader: 8B30, B5DB15264CA222B6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[1].specular_0) * geo_factor) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp(min((texcolor0.ggg) + (const_color[1].rgb), vec3(1.0)) * (texcolor0.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((vec3(1.0) - texcolor0.aaa) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 200394BADB625EFC, B5DB15264CA222B6 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, B5DB15264CA222B6 +// shader: 8B30, 0E48B126B5A1F0CD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTSigned(3, dot(normal, normalize(view)))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTSigned(3, dot(normal, normalize(view)))); +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[1].specular_0) * geo_factor) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((const_color[0].rgb) + (vec3(1.0) - primary_fragment_color.aaa), vec3(1.0)) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = (primary_fragment_color.rgb); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B0C0A4886738F0F8, 0E48B126B5A1F0CD +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 0E48B126B5A1F0CD +// reference: C65F091EB15A4A64, 9A4719A519F0D3B1 +// reference: DC9A998F74007B60, 7974F3663498993D +// reference: 27AF7B7B11130B83, 370761F478D5E560 +// reference: C65F091EB0982053, 9A4719A519F0D3B1 +// reference: 3C111F917D0D7672, A453279F963EF650 +// reference: 8E74321336303520, 8FFF40937EB91414 +// reference: 33BFCAC4F6F3A9D6, 7639F41487FD0FB0 +// reference: 200394BADAA034CB, B5DB15264CA222B6 +// reference: B0C0A48866FA9ACF, 0E48B126B5A1F0CD +// reference: DC9A998F75C21157, 7974F3663498993D +// reference: 27AF7B7B10D161B4, 370761F478D5E560 +// reference: D4F4BEF94BDB88B3, B35EFE43E319BB63 +// reference: CE312E68D7B0A07F, 9A4719A519F0D3B1 +// reference: D4F4BEF912EA917B, 7974F3663498993D +// reference: 1080747777F9E198, F6B6F838D1CE558E +// reference: D4F4BEF9E33E5A63, 30B703594147E54C +// shader: 8B30, D098787893B2A669 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10807477E33E5A63, D098787893B2A669 +// program: 4AC344BC6E622851, 219384019281D7FD, D098787893B2A669 +// shader: 8B30, D64F785DB695D4B5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].ggg) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].bbb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 54B41806B55C92C5, D64F785DB695D4B5 +// program: 4AC344BC6E622851, 219384019281D7FD, D64F785DB695D4B5 +// shader: 8B30, BE79C96A183B7C35 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 713A998F458F323A, BE79C96A183B7C35 +// program: 4AC344BC6E622851, 219384019281D7FD, BE79C96A183B7C35 +// reference: 22BB0D9EBE6F4383, 0803E1FD60D3E38E +// shader: 8B31, 940333C8A0C882B5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.xy = ivec2(vs_in_reg3.xy); + reg_tmp0 = mul_s(uniforms.f[94].xxxx, vs_in_reg3); + reg_tmp13.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[10 + address_registers.x]); + reg_tmp13.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[11 + address_registers.x]); + reg_tmp13.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[12 + address_registers.x]); + reg_tmp14.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[10 + address_registers.y]); + reg_tmp14.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[11 + address_registers.y]); + reg_tmp14.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[12 + address_registers.y]); + vs_out_attr1 = mul_s(uniforms.f[94].xxxx, vs_in_reg2); + reg_tmp13 = mul_s(reg_tmp13, reg_tmp0.zzzz); + vs_out_attr3.x = dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[82]); + vs_out_attr3.y = dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[83]); + reg_tmp13 = fma_s(reg_tmp14, reg_tmp0.wwww, reg_tmp13); + vs_out_attr2.x = dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[79]); + vs_out_attr2.yzw = vec3(dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[80])); + vs_out_attr3.z = dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[84]); + vs_out_attr3.w = dot_s(vec4(vs_in_reg1.xyyy.xyz, 1.0), uniforms.f[85]); + vs_out_attr0.x = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[87]); + vs_out_attr0.z = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[88]); + vs_out_attr0.w = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[89]); + return true; +} +// reference: D288B27F2FDD9723, 940333C8A0C882B5 +// shader: 8DD9, 8C3EE1C6135E31E3 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: FD61970B2C76F264, 8C3EE1C6135E31E3 +// shader: 8B30, A65608349203942D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 558BF1DF42EC023F, A65608349203942D +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, A65608349203942D +// reference: 9CDC4D3FAC28F151, 940333C8A0C882B5 +// shader: 8B30, 1814F3193E26B890 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 91FF3B5142EC023F, 1814F3193E26B890 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 1814F3193E26B890 +// shader: 8B30, 567B7A2E50172D64 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 558BF1DFC9AC7D4A, 567B7A2E50172D64 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 567B7A2E50172D64 +// shader: 8B30, 24E125F765838BB2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 7E8AC2CDA50937BB, 24E125F765838BB2 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 24E125F765838BB2 +// shader: 8B31, 6BC2ABEB69D37DBC + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp15 = mul_s(uniforms.f[95].zzzz, vs_in_reg3); + reg_tmp0.x = dot_s(vec4(vs_in_reg0.xyzz.xyz, 1.0), uniforms.f[0]); + reg_tmp0.y = dot_s(vec4(vs_in_reg0.xyzz.xyz, 1.0), uniforms.f[1]); + reg_tmp2.xyz = (mul_s(uniforms.f[3].yzxx, reg_tmp15.zxyy)).xyz; + reg_tmp0.z = dot_s(vec4(vs_in_reg0.xyzz.xyz, 1.0), uniforms.f[2]); + vs_out_attr2 = mul_s(uniforms.f[94].xxxx, vs_in_reg2); + reg_tmp2.w = dot_3(uniforms.f[3].xyz, -reg_tmp15.xyz); + if (uniforms.b[1]) { + sub_1(); + } else { + sub_6(); + } + vs_out_attr5 = uniforms.f[90] + -reg_tmp0; + vs_out_attr1 = fma_s(reg_tmp15.wwww, uniforms.f[3], reg_tmp2); + return true; +} +bool sub_1() { + if (uniforms.b[4]) { + sub_2(); + } else { + sub_5(); + } + vs_out_attr0.y = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[87]); + vs_out_attr0.z = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[88]); + reg_tmp2.xyz = (fma_s(-reg_tmp15.yzxx, uniforms.f[3].zxyy, reg_tmp2.xyzz)).xyz; + vs_out_attr0.w = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[89]); + vs_out_attr3.x = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[79]); + vs_out_attr3.y = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[80]); + reg_tmp2.xyz = (fma_s(reg_tmp15.xyzz, uniforms.f[3].wwww, reg_tmp2.xyzz)).xyz; + vs_out_attr3.zw = vec2(dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[81])); + return false; +} +bool sub_2() { + if (uniforms.b[5]) { + sub_3(); + } else { + sub_4(); + } + vs_out_attr0.x = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[86]); + return false; +} +bool sub_3() { + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1.zwzw); + return false; +} +bool sub_4() { + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1); + return false; +} +bool sub_5() { + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1.xyxy); + vs_out_attr0.x = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[86]); + return false; +} +bool sub_6() { + vs_out_attr3 = mul_s(uniforms.f[95].yyyy, vs_in_reg1); + if (uniforms.b[4]) { + sub_7(); + } else { + sub_10(); + } + vs_out_attr0.x = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[87]); + reg_tmp2.xyz = (fma_s(reg_tmp15.xyzz, uniforms.f[3].wwww, reg_tmp2.xyzz)).xyz; + vs_out_attr0.z = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[88]); + vs_out_attr0.w = dot_s(vec4(reg_tmp0.xyz, 1.0), uniforms.f[89]); + return false; +} +bool sub_7() { + if (uniforms.b[5]) { + sub_8(); + } else { + sub_9(); + } + reg_tmp2.xyz = (fma_s(-reg_tmp15.yzxx, uniforms.f[3].zxyy, reg_tmp2.xyzz)).xyz; + return false; +} +bool sub_8() { + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1.zwzw); + return false; +} +bool sub_9() { + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1); + return false; +} +bool sub_10() { + reg_tmp2.xyz = (fma_s(-reg_tmp15.yzxx, uniforms.f[3].zxyy, reg_tmp2.xyzz)).xyz; + vs_out_attr4 = mul_s(uniforms.f[95].yyyy, vs_in_reg1.xyxy); + return false; +} +// reference: CF3A6BEBD2098CB1, 6BC2ABEB69D37DBC +// shader: 8DD9, 91A2A4284D9D0125 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z, vtx.attributes[2].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + texcoord0_w = vtx.attributes[3].z; + view = vec3(vtx.attributes[5].x, vtx.attributes[5].y, vtx.attributes[5].z); + texcoord2 = vec2(vtx.attributes[4].z, vtx.attributes[4].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[6](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0]); + prim_buffer[1].attributes = vec4[6](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1]); + prim_buffer[2].attributes = vec4[6](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: EDDDC23AE7F85894, 91A2A4284D9D0125 +// shader: 8B30, A94E0AFE11430C03 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[2].rgb), vec3(1.0)) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 75BD325F02465EED, A94E0AFE11430C03 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, A94E0AFE11430C03 +// shader: 8B30, 35F64DD418C43AE8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BE777BFC8DF6D90E, 35F64DD418C43AE8 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 35F64DD418C43AE8 +// shader: 8B30, 7C5E11B0D08F71E7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EB55C8225869955C, 7C5E11B0D08F71E7 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 7C5E11B0D08F71E7 +// shader: 8B30, C5F9704A41D985AA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EF0A1DD889093FE0, C5F9704A41D985AA +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, C5F9704A41D985AA +// shader: 8B30, 5BFFB4E7C22168B0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[2].rgb), vec3(1.0)) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 23A11B00C69CC665, 5BFFB4E7C22168B0 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 5BFFB4E7C22168B0 +// shader: 8B30, 2288F3BC2137A8B1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb) + (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[3].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 86A8F9BE6DDEE38B, 2288F3BC2137A8B1 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 2288F3BC2137A8B1 +// shader: 8B30, 7A001056D544A63A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (texcolor1.rgb), vec3(1.0)) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[3].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B43CAA7790CBD27A, 7A001056D544A63A +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 7A001056D544A63A +// shader: 8B30, 231341ADE983B0EF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (texcolor1.rgb), vec3(1.0)) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0096F541545B8E7B, 231341ADE983B0EF +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 231341ADE983B0EF +// shader: 8B30, 165FC9AA441D1A81 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[2].rgb), vec3(1.0)) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0096F5417C038DC3, 165FC9AA441D1A81 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 165FC9AA441D1A81 +// shader: 8B30, 96CD7DCF818F673D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp(min((last_tex_env_out.rgb) + (secondary_fragment_color.rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(1.0)) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CD9ED5AD82E23BF3, 96CD7DCF818F673D +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 96CD7DCF818F673D +// shader: 8B30, 6A1BB71D3D0E9148 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((last_tex_env_out.rgb) + (const_color[3].rgb), vec3(1.0)) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D40BB57645D5EBA4, 6A1BB71D3D0E9148 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 6A1BB71D3D0E9148 +// reference: C9567B3216911C46, 7C5E11B0D08F71E7 +// reference: EB55C82216911C46, 7C5E11B0D08F71E7 +// shader: 8B30, 6EFFB7CE13972D01 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[3].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 49138ED1874F59BC, 6EFFB7CE13972D01 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 6EFFB7CE13972D01 +// shader: 8B30, 30F59EF34F255F55 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[3].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 19A0E40D3AEADCDF, 30F59EF34F255F55 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 30F59EF34F255F55 +// shader: 8B30, 30C0BDB7C999CA5D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EB55C822E37590C3, 30C0BDB7C999CA5D +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 30C0BDB7C999CA5D +// shader: 8B30, 2C5AAADC3943A339 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor2).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((shadowTexture(texcoord0, texcoord0_w).rgb) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EB55C8220021AB23, 2C5AAADC3943A339 +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 2C5AAADC3943A339 +// shader: 8B31, CBBEE036EBC5C5CD + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp15.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[0]); + reg_tmp15.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[1]); + reg_tmp15.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[2]); + vs_out_attr1 = vs_in_reg1; + vs_out_attr0.x = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[87]); + vs_out_attr0.z = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[88]); + vs_out_attr2 = vs_in_reg2.xyyy; + vs_out_attr0.w = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[89]); + return true; +} +// reference: 7931F98138FA2D72, CBBEE036EBC5C5CD +// shader: 8B30, 7545061F2AD2E2E2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AA3FAD15334F86DA, 7545061F2AD2E2E2 +// program: CBBEE036EBC5C5CD, 219384019281D7FD, 7545061F2AD2E2E2 +// reference: 9DBA831B40E859F5, D64F785DB695D4B5 +// reference: F9BE39045C35D8D1, BE79C96A183B7C35 +// shader: 8B30, 35B6A52B3D768E86 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3DCAF38A0F307BB8, 35B6A52B3D768E86 +// program: 4AC344BC6E622851, 219384019281D7FD, 35B6A52B3D768E86 +// shader: 8B30, C14170987499741F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.aaa) + (rounded_primary_color.rgb) * (vec3(1.0) - (rounded_primary_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3879FF150F307BB8, C14170987499741F +// program: 4AC344BC6E622851, 219384019281D7FD, C14170987499741F +// shader: 8B30, B8AE6BC68B244DDA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E37BA9952CA2733F, B8AE6BC68B244DDA +// program: 4AC344BC6E622851, 219384019281D7FD, B8AE6BC68B244DDA +// reference: AA3FAD15A7D5A968, 0803E1FD60D3E38E +// shader: 8B30, 5779A24412A1FEDC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AA3FAD150F307BB8, 5779A24412A1FEDC +// program: 4AC344BC6E622851, 219384019281D7FD, 5779A24412A1FEDC +// reference: 8FBB15FE3BBE81A4, 9A4719A519F0D3B1 +// reference: 6E4B679B9BF7C043, 370761F478D5E560 +// shader: 8B30, 8C3FC0D439811C7F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0EDB721AD153333, 8C3FC0D439811C7F +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 8C3FC0D439811C7F +// shader: 8B30, 02E4FC843CD44F4F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 24997DAFAD153333, 02E4FC843CD44F4F +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 02E4FC843CD44F4F +// shader: 8B30, D819F6645F9EDCFD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0EDB72126554C46, D819F6645F9EDCFD +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, D819F6645F9EDCFD +// shader: 8B30, 630E8F86E494C6DB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CBEC84334AF006B7, 630E8F86E494C6DB +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 630E8F86E494C6DB +// shader: 8B31, E47A25CAEDE18CE0 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.xy = ivec2(vs_in_reg4.xy); + reg_tmp0 = mul_s(uniforms.f[94].xxxx, vs_in_reg4); + reg_tmp8.x = dot_3(uniforms.f[10 + address_registers.x].xyz, vs_in_reg1.xyz); + reg_tmp8.y = dot_3(uniforms.f[11 + address_registers.x].xyz, vs_in_reg1.xyz); + reg_tmp8.z = dot_3(uniforms.f[12 + address_registers.x].xyz, vs_in_reg1.xyz); + reg_tmp9.x = dot_3(uniforms.f[10 + address_registers.y].xyz, vs_in_reg1.xyz); + reg_tmp9.y = dot_3(uniforms.f[11 + address_registers.y].xyz, vs_in_reg1.xyz); + reg_tmp9.z = dot_3(uniforms.f[12 + address_registers.y].xyz, vs_in_reg1.xyz); + reg_tmp13.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[10 + address_registers.x]); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp0.zzzz); + reg_tmp13.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[11 + address_registers.x]); + reg_tmp13.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[12 + address_registers.x]); + reg_tmp8 = fma_s(reg_tmp9, reg_tmp0.wwww, reg_tmp8); + reg_tmp14.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[10 + address_registers.y]); + reg_tmp14.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[11 + address_registers.y]); + reg_tmp14.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[12 + address_registers.y]); + reg_tmp13 = mul_s(reg_tmp13, reg_tmp0.zzzz); + reg_tmp2.x = dot_3(reg_tmp8.xyz, reg_tmp8.xyz); + vs_out_attr3.x = dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[82]); + vs_out_attr3.y = dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[83]); + reg_tmp13 = fma_s(reg_tmp14, reg_tmp0.wwww, reg_tmp13); + vs_out_attr2.x = dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[79]); + reg_tmp2.x = rsq_s(reg_tmp2.x); + vs_out_attr2.yzw = vec3(dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[80])); + vs_out_attr3.z = dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[84]); + vs_out_attr3.w = dot_s(vec4(vs_in_reg3.xyyy.xyz, 1.0), uniforms.f[85]); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp2.xxxx); + vs_out_attr4 = uniforms.f[90] + -reg_tmp13; + vs_out_attr0.x = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[87]); + conditional_code = equal(-uniforms.f[93].yy, reg_tmp8.zz); + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp8.zzzz; + vs_out_attr0.z = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[88]); + vs_out_attr0.w = dot_s(vec4(reg_tmp13.xyz, 1.0), uniforms.f[89]); + reg_tmp4 = mul_s(uniforms.f[93].wwww, reg_tmp4); + reg_tmp15 = uniforms.f[93].yxxx; + vs_out_attr1 = mul_s(uniforms.f[94].xxxx, vs_in_reg2); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[93].wwww, reg_tmp8); + if (!conditional_code.x) { + sub_1(); + } + vs_out_attr5 = reg_tmp15; + return true; +} +bool sub_1() { + reg_tmp15.z = rcp_s(reg_tmp4.x); + reg_tmp15.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +// reference: 04AC4A54BC20340C, E47A25CAEDE18CE0 +// shader: 8DD9, 4B59102A98868B38 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[5].x, vtx.attributes[5].y, vtx.attributes[5].z, vtx.attributes[5].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[4].x, vtx.attributes[4].y, vtx.attributes[4].z); + texcoord2 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[6](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0]); + prim_buffer[1].attributes = vec4[6](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1]); + prim_buffer[2].attributes = vec4[6](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 1145DC3262254B61, 4B59102A98868B38 +// shader: 8B30, 224324BE8AA9D348 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 437E63A79493C2AD, 224324BE8AA9D348 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 224324BE8AA9D348 +// shader: 8B30, B9821BE4ED10E3CE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor1.rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F01EB4E9836EDA4C, B9821BE4ED10E3CE +// program: E47A25CAEDE18CE0, 4B59102A98868B38, B9821BE4ED10E3CE +// shader: 8B30, F90BF3D91D4758FD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0B40F97101E0BB80, F90BF3D91D4758FD +// program: E47A25CAEDE18CE0, 4B59102A98868B38, F90BF3D91D4758FD +// shader: 8B30, 5F8CD5FE885BCA84 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8BB95A96D147F6BB, 5F8CD5FE885BCA84 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 5F8CD5FE885BCA84 +// reference: D9F8E8720B00B6F0, 7545061F2AD2E2E2 +// reference: 8A797C63647AE8FB, BE79C96A183B7C35 +// reference: 4E0DB6ED377F4B92, 35B6A52B3D768E86 +// reference: 4BBEBA72377F4B92, C14170987499741F +// reference: 90BCECF214ED4315, B8AE6BC68B244DDA +// shader: 8B30, 6562A6B303FBEFF1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4E0DB6ED766FB467, 6562A6B303FBEFF1 +// program: 4AC344BC6E622851, 219384019281D7FD, 6562A6B303FBEFF1 +// reference: D9F8E8729F9A9942, 0803E1FD60D3E38E +// reference: D9F8E872377F4B92, 5779A24412A1FEDC +// reference: FC7C509903F1B18E, 9A4719A519F0D3B1 +// reference: 1D8C22FCA3B8F069, 370761F478D5E560 +// reference: 067EAF3B17272EE5, 7545061F2AD2E2E2 +// reference: 55FF3B2A785D70EE, BE79C96A183B7C35 +// reference: 918BF1A42B58D387, 35B6A52B3D768E86 +// reference: 9438FD3B2B58D387, C14170987499741F +// reference: 4F3AABBB08CADB00, B8AE6BC68B244DDA +// reference: 918BF1A46A482C72, 6562A6B303FBEFF1 +// reference: 067EAF3B83BD0157, 0803E1FD60D3E38E +// reference: 067EAF3B2B58D387, 5779A24412A1FEDC +// reference: 23FA17D01FD6299B, 9A4719A519F0D3B1 +// reference: C20A65B5BF9F687C, 370761F478D5E560 +// shader: 8B31, A9D268AF4B4A9C66 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp15.x = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[0]); + reg_tmp15.y = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[1]); + reg_tmp15.z = dot_s(vec4(vs_in_reg0.xyz, 1.0), uniforms.f[2]); + reg_tmp13.x = dot_3(uniforms.f[0].xyz, vs_in_reg2.xyz); + reg_tmp13.y = dot_3(uniforms.f[1].xyz, vs_in_reg2.xyz); + reg_tmp13.z = dot_3(uniforms.f[2].xyz, vs_in_reg2.xyz); + vs_out_attr1 = vs_in_reg1; + vs_out_attr0.x = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[86]); + vs_out_attr0.y = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[87]); + vs_out_attr0.z = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[88]); + reg_tmp0.x = dot_3(reg_tmp13.xyz, reg_tmp13.xyz); + vs_out_attr0.w = dot_s(vec4(reg_tmp15.xyz, 1.0), uniforms.f[89]); + vs_out_attr3 = uniforms.f[90] + -reg_tmp15; + vs_out_attr4 = vs_in_reg3.xyyy; + reg_tmp14 = uniforms.f[93].yxxx; + reg_tmp0.x = rsq_s(reg_tmp0.x); + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp0.xxxx)).xyz; + conditional_code = equal(-uniforms.f[93].yy, reg_tmp13.zz); + if (!conditional_code.x) { + sub_1(); + } + vs_out_attr2 = reg_tmp14; + return true; +} +bool sub_1() { + reg_tmp11 = uniforms.f[93].yyyy + reg_tmp13.zzzz; + reg_tmp11 = mul_s(uniforms.f[93].wwww, reg_tmp11); + reg_tmp11 = vec4(rsq_s(reg_tmp11.z)); + reg_tmp12.xy = (mul_s(uniforms.f[93].wwww, reg_tmp13)).xy; + reg_tmp14.z = rcp_s(reg_tmp11.z); + reg_tmp14.xy = (mul_s(reg_tmp12.xyyy, reg_tmp11.xxxx)).xy; + return false; +} +// reference: E586DB63FBD2E89F, A9D268AF4B4A9C66 +// shader: 8DD9, 238E382D0072C345 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z, vtx.attributes[2].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7E424AC856749C8E, 238E382D0072C345 +// shader: 8B30, 1F3CF8780CD39572 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F1700612BB7357F3, 1F3CF8780CD39572 +// program: A9D268AF4B4A9C66, 238E382D0072C345, 1F3CF8780CD39572 +// reference: 3DCAF38A4E20844D, 6562A6B303FBEFF1 +// shader: 8B30, 1C9E4DFDE7692E61 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AA3FAD155C35D8D1, 1C9E4DFDE7692E61 +// program: 4AC344BC6E622851, 219384019281D7FD, 1C9E4DFDE7692E61 +// reference: 067EAF3B785D70EE, 1C9E4DFDE7692E61 +// shader: 8B30, E98844A9767F3156 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 94EB4DB4045E5302, E98844A9767F3156 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, E98844A9767F3156 +// shader: 8B30, 8E071DD2D37C1643 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 509F873A045E5302, 8E071DD2D37C1643 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 8E071DD2D37C1643 +// shader: 8B30, 41075A3770C2BEB6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 94EB4DB48F1E2C77, 41075A3770C2BEB6 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 41075A3770C2BEB6 +// shader: 8B30, 3DE6162D5E2667C7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += (((light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BFEA7EA6E3BB6686, 3DE6162D5E2667C7 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 3DE6162D5E2667C7 +// shader: 8B30, 1F29A24E1EFD4DB7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (vec3(1.0) - const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.aaa) * (vec3(1.0) - const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3C111F91A9236C53, 1F29A24E1EFD4DB7 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 1F29A24E1EFD4DB7 +// shader: 8B30, A87E2CAB5E616A45 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (vec3(1.0) - primary_fragment_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8E743213E21E2F01, A87E2CAB5E616A45 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, A87E2CAB5E616A45 +// shader: 8B30, 3B579410BD1F3F14 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +clamp_highlights = sign(dot_product); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTUnsigned(3, max(dot(normal, normalize(view)), 0.0))); +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - texcolor1.aaa) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 33BFCAC422DDB3F7, 3B579410BD1F3F14 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 3B579410BD1F3F14 +// shader: 8B30, E51A55B59EF71EFC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp(min((texcolor0.ggg) + (const_color[1].rgb), vec3(1.0)) * (texcolor0.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((vec3(1.0) - texcolor0.aaa) + (const_color[4].rgb), vec3(1.0)) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 200394BA0E8E2EEA, E51A55B59EF71EFC +// program: CABD7FF7677EC71E, BCFD13684549D2B2, E51A55B59EF71EFC +// shader: 8B30, FD77385CCB9FC275 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.a = (lut_scale_fr * LookupLightingLUTSigned(3, dot(normal, normalize(view)))); +specular_sum.a = (lut_scale_fr * LookupLightingLUTSigned(3, dot(normal, normalize(view)))); +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTSigned(0, dot(normal, normalize(half_vector)))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((const_color[0].rgb) + (vec3(1.0) - primary_fragment_color.aaa), vec3(1.0)) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = (primary_fragment_color.rgb); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B0C0A488B2D480EE, FD77385CCB9FC275 +// program: CABD7FF7677EC71E, BCFD13684549D2B2, FD77385CCB9FC275 +// shader: 8B30, 3E6D5EDB0E32411C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[7].position); +spot_dir = light_src[7].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +geo_factor = dot(half_vector, half_vector); +geo_factor = geo_factor == 0.0 ? 0.0 : min(dot_product / geo_factor, 1.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[7].diffuse * dot_product) + light_src[7].ambient) * 1.0; +specular_sum.rgb += ((((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[7].specular_0) * geo_factor) + (light_src[7].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp(min((texcolor0.ggg) + (const_color[1].rgb), vec3(1.0)) * (texcolor0.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 19BAA0E056EF7AB5, 3E6D5EDB0E32411C +// program: CABD7FF7677EC71E, BCFD13684549D2B2, 3E6D5EDB0E32411C +// reference: C9F2D38DB7097399, 7545061F2AD2E2E2 +// reference: C9F2D38DD8732D92, 1C9E4DFDE7692E61 +// reference: 9A73479CD8732D92, BE79C96A183B7C35 +// reference: 5E078D128B768EFB, 35B6A52B3D768E86 +// reference: 5BB4818D8B768EFB, C14170987499741F +// reference: 80B6D70DA8E4867C, B8AE6BC68B244DDA +// reference: C9F2D38D8B768EFB, 5779A24412A1FEDC +// reference: EC766B66BFF874E7, 9A4719A519F0D3B1 +// reference: 0D8619031FB13500, 370761F478D5E560 +// shader: 8B30, 10B4F62F985652EB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CC42EEA0BAB5F078, 10B4F62F985652EB +// program: 6BC2ABEB69D37DBC, 91A2A4284D9D0125, 10B4F62F985652EB +// reference: E6B9C008C6AB808A, 7974F3663498993D +// shader: 8B30, 34D2DFB61EF1C5FA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4E0DB6EDDED7F2FE, 34D2DFB61EF1C5FA +// program: AC1E05AC1AB5ABAD, CBBC43C38774091B, 34D2DFB61EF1C5FA +// shader: 8B30, 915BFAF2367A95BA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4E0DB6EDA3B8F069, 915BFAF2367A95BA +// program: 4AC344BC6E622851, 219384019281D7FD, 915BFAF2367A95BA +// shader: 8B30, 0D2C0CDC80018144 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A4A9EA2303724CD6, 0D2C0CDC80018144 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 0D2C0CDC80018144 +// reference: 6B84566F1548AE4A, 4AC344BC6E622851 +// reference: C4C0C428CB2487E3, AC1E05AC1AB5ABAD +// reference: EE7C74A021E2674B, 4CE8EC673CE76DDE +// reference: F733748D7C92A987, CABD7FF7677EC71E +// reference: 8E69E2D1AC28F151, 940333C8A0C882B5 +// reference: DD8FC405D2098CB1, 6BC2ABEB69D37DBC +// reference: 6B84566F38FA2D72, CBBEE036EBC5C5CD +// reference: 1619E5BABC20340C, E47A25CAEDE18CE0 +// reference: F733748DFBD2E89F, A9D268AF4B4A9C66 +// shader: 8B30, 4500F8CBA236EA54 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3504CC9CE876F49A, 4500F8CBA236EA54 +// program: A9D268AF4B4A9C66, 238E382D0072C345, 4500F8CBA236EA54 +// program: 4AC344BC6E622851, 219384019281D7FD, 7545061F2AD2E2E2 +// shader: 8B30, 8A7B64C96E414CF3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8A797C630B00B6F0, 8A7B64C96E414CF3 +// program: 4AC344BC6E622851, 219384019281D7FD, 8A7B64C96E414CF3 +// shader: 8B30, E2336507D115048F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8A797C63377F4B92, E2336507D115048F +// program: 4AC344BC6E622851, 219384019281D7FD, E2336507D115048F +// reference: 5E078D1262DE3797, 34D2DFB61EF1C5FA +// reference: 5E078D121FB13500, 915BFAF2367A95BA +// reference: 9A73479C8B768EFB, E2336507D115048F +// reference: F6B3FBF77AA245E3, 7974F3663498993D +// reference: 97DD4B60C50C5D3D, 7545061F2AD2E2E2 +// reference: C45CDF71AA760336, BE79C96A183B7C35 +// reference: 002815FF10DB1933, 34D2DFB61EF1C5FA +// reference: 002815FF6DB41BA4, 915BFAF2367A95BA +// reference: 002815FFF973A05F, 35B6A52B3D768E86 +// reference: 059B1960F973A05F, C14170987499741F +// reference: DE994FE0DAE1A8D8, B8AE6BC68B244DDA +// reference: 97DD4B60F973A05F, 5779A24412A1FEDC +// reference: B259F38BCDFD5A43, 9A4719A519F0D3B1 +// reference: 53A981EE6DB41BA4, 370761F478D5E560 +// reference: C45CDF71F973A05F, E2336507D115048F +// shader: 8B30, E8DE42F53A8F6D43 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AC4D1BAD662143F3, E8DE42F53A8F6D43 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, E8DE42F53A8F6D43 +// shader: 8B30, 9D00FD53DE0AE4FB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((last_tex_env_out.rgb) + (texcolor1.rgb), vec3(1.0)) * (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4 * 2.0, alpha_output_4 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D29F2F3A0A03BF72, 9D00FD53DE0AE4FB +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 9D00FD53DE0AE4FB +// shader: 8B30, FF859E7CB65A9737 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp(min((last_tex_env_out.rgb) + (texcolor1.rgb), vec3(1.0)) * (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4 * 2.0, alpha_output_4 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 456A71A53A0E9A25, FF859E7CB65A9737 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, FF859E7CB65A9737 +// shader: 8B30, 94151A1D58B257A1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BD3C8AF8D96A0C3E, 94151A1D58B257A1 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 94151A1D58B257A1 +// shader: 8B30, 9C4117B9C0F36A06 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FFCC8FBCD521A7B3, 9C4117B9C0F36A06 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 9C4117B9C0F36A06 +// reference: BD83475094522833, BE79C96A183B7C35 +// reference: 79F78DDE2EFF3236, 34D2DFB61EF1C5FA +// reference: 79F78DDE539030A1, 915BFAF2367A95BA +// reference: 79F78DDEC7578B5A, 35B6A52B3D768E86 +// reference: 7C448141C7578B5A, C14170987499741F +// reference: A746D7C1E4C583DD, B8AE6BC68B244DDA +// reference: EE02D341C7578B5A, 5779A24412A1FEDC +// reference: CB866BAAF3D97146, 9A4719A519F0D3B1 +// reference: 2A7619CF539030A1, 370761F478D5E560 +// reference: C9F2D38D803E2002, 1C9E4DFDE7692E61 +// program: A9D268AF4B4A9C66, 238E382D0072C345, 1C9E4DFDE7692E61 +// shader: 8B30, 67B4F31684021479 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((texcolor0.r) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F1CB72FD19FFABCB, 67B4F31684021479 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 67B4F31684021479 +// program: 940333C8A0C882B5, 8C3EE1C6135E31E3, 67B4F31684021479 +// shader: 8B30, 5AB0911C44B56E92 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0EE30564BDFCE94, 5AB0911C44B56E92 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 5AB0911C44B56E92 +// shader: 8B30, 9A7578D5BD5DE94B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3E5F6A494BDFCE94, 9A7578D5BD5DE94B +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 9A7578D5BD5DE94B +// shader: 8B30, BA83D9C2BD5DE94B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3E5F6A49BE3B4211, BA83D9C2BD5DE94B +// program: E47A25CAEDE18CE0, 4B59102A98868B38, BA83D9C2BD5DE94B +// shader: 8B30, C7431134887C9728 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3E5F6A49DF18756F, C7431134887C9728 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, C7431134887C9728 +// reference: EE02D341FB287638, 7545061F2AD2E2E2 +// reference: BD834750FB287638, 8A7B64C96E414CF3 +// shader: 8B30, 546C74A431B2122D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0D8619038B768EFB, 546C74A431B2122D +// program: CBBEE036EBC5C5CD, 219384019281D7FD, 546C74A431B2122D +// shader: 8B30, 1D1D77C029E2FD04 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6D5332480527478E, 1D1D77C029E2FD04 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 1D1D77C029E2FD04 +// shader: 8B30, 2813669BAAB6A216 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3E268570527478E, 2813669BAAB6A216 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 2813669BAAB6A216 +// shader: 8B30, A08E0CF2AAB6A216 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3E26857F0C3CB0B, A08E0CF2AAB6A216 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, A08E0CF2AAB6A216 +// shader: 8B30, 0C953E62AA44E62F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3E2685791E0FC75, 0C953E62AA44E62F +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 0C953E62AA44E62F +// reference: D143FB3B36834042, 7974F3663498993D +// reference: 054C51F6647AE8FB, BE79C96A183B7C35 +// reference: 56CDC5E70B00B6F0, 7545061F2AD2E2E2 +// reference: 054C51F60B00B6F0, 8A7B64C96E414CF3 +// reference: C1389B78DED7F2FE, 34D2DFB61EF1C5FA +// reference: C1389B78A3B8F069, 915BFAF2367A95BA +// reference: C1389B78377F4B92, 35B6A52B3D768E86 +// reference: C48B97E7377F4B92, C14170987499741F +// reference: 1F89C16714ED4315, B8AE6BC68B244DDA +// reference: 56CDC5E7377F4B92, 5779A24412A1FEDC +// reference: 73497D0C03F1B18E, 9A4719A519F0D3B1 +// reference: 92B90F69A3B8F069, 370761F478D5E560 +// shader: 8B30, 0D2C0CDC1AFB3250 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A4A9EA238EBA9D5C, 0D2C0CDC1AFB3250 +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 0D2C0CDC1AFB3250 +// shader: 8B30, 8EC44935AE69341F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +depth /= gl_FragCoord.w; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A4A9EA237B5E11D9, 8EC44935AE69341F +// program: E47A25CAEDE18CE0, 4B59102A98868B38, 8EC44935AE69341F +// reference: 9A73479CB7097399, 8A7B64C96E414CF3 diff --git a/cache/0004000000131E00.shader.meta b/cache/0004000000131E00.shader.meta new file mode 100644 index 00000000000..fdf44c84da2 --- /dev/null +++ b/cache/0004000000131E00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 101 +reference: 213 +program: 87 diff --git a/cache/0004000000158D00.shader b/cache/0004000000158D00.shader new file mode 100644 index 00000000000..55fcd2f7f4c --- /dev/null +++ b/cache/0004000000158D00.shader @@ -0,0 +1,2841 @@ +// shader: 8B31, B8BC03A278E845A7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0.x = dot_s(uniforms.f[4], vs_in_reg0); + reg_tmp0.y = dot_s(uniforms.f[5], vs_in_reg0); + reg_tmp0.z = dot_s(uniforms.f[6], vs_in_reg0); + reg_tmp0.w = dot_s(uniforms.f[7], vs_in_reg0); + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp0); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp0); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp0); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp0); + vs_out_attr1 = mul_s(uniforms.f[95].xxxx, vs_in_reg1.wzyx); + vs_out_attr2 = vs_in_reg2; + return true; +} +// reference: ADD6671999AEF0F1, B8BC03A278E845A7 +// shader: 8DD9, 219384019281D7FD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +struct Vertex { + vec4 attributes[3]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[3](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0]); + prim_buffer[1].attributes = vec4[3](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1]); + prim_buffer[2].attributes = vec4[3](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 7B07DA3E334A19B0, 219384019281D7FD +// shader: 8B30, 12433E7DDE265EFC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A1254EF14, 12433E7DDE265EFC +// program: B8BC03A278E845A7, 219384019281D7FD, 12433E7DDE265EFC +// reference: E38298591A5B9683, B8BC03A278E845A7 +// shader: 8B30, 4DFD84F1D4CE3747 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 66BB775680AB8AE4, 4DFD84F1D4CE3747 +// program: B8BC03A278E845A7, 219384019281D7FD, 4DFD84F1D4CE3747 +// shader: 8B30, 479706B299D4859E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D0EE1D580AB8AE4, 479706B299D4859E +// program: B8BC03A278E845A7, 219384019281D7FD, 479706B299D4859E +// shader: 8B30, 6934EFAB6214C050 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 66BB7756754F0661, 6934EFAB6214C050 +// program: B8BC03A278E845A7, 219384019281D7FD, 6934EFAB6214C050 +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF91254EF14, B35EFE43E319BB63 +// program: B8BC03A278E845A7, 219384019281D7FD, B35EFE43E319BB63 +// shader: 8B30, 66AC7067CE4BEBEF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp(min((texcolor0.rgb) + (const_color[0].rgb), vec3(1.0)) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8D0EE1D5754F0661, 66AC7067CE4BEBEF +// program: B8BC03A278E845A7, 219384019281D7FD, 66AC7067CE4BEBEF +// shader: 8B30, C5B689A94B459F54 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +float ProcTexLookupLUT(int offset, float coord) { + coord *= 128.0; + float index_i = clamp(floor(coord), 0.0, 127.0); + float index_f = coord - index_i; // fract() cannot be used here because 128.0 needs to be + // extracted as index_i = 127.0 and index_f = 1.0 + vec2 entry = texelFetch(texture_buffer_lut_rg, int(index_i) + offset).rg; + return clamp(entry.r + entry.g * index_f, 0.0, 1.0); +} + vec4 SampleProcTexColor(float lut_coord, int level) { +int lut_width = 255 >> level; +int lut_offsets[8] = int[](0, 128, 192, 224, 0xF0, 0xF8, 0xFC, 0xFE); +int lut_offset = lut_offsets[level]; +lut_coord *= float(lut_width - 1); +lut_coord += float(lut_offset); +return texelFetch(texture_buffer_lut_rgba, int(round(lut_coord)) + proctex_lut_offset); +} +vec4 ProcTex() { +vec2 uv = abs(texcoord2); +float u_shift = 0.0; +float v_shift = 0.0; +float u = uv.x + u_shift; +float v = uv.y + v_shift; +u = mix(u, 0.0, u > 1.0); +v = mix(v, 0.0, v > 1.0); +float lut_coord = ProcTexLookupLUT(proctex_color_map_offset, u); +vec4 final_color = SampleProcTexColor(lut_coord, 0); +return final_color; +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) - (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) + (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((combiner_buffer.r) - (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 1.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((ProcTex().rgb) * (last_tex_env_out.aaa) + (textureLod(tex2, texcoord1, getLod(texcoord1 * vec2(textureSize(tex2, 0)))).rgb) * (vec3(1.0) - (last_tex_env_out.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((combiner_buffer.r) - (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3 * 1.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.aaa) + (combiner_buffer.rgb) * (vec3(1.0) - (last_tex_env_out.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((rounded_primary_color.a) - (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 1.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) + (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) != alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F08419E0664CA7E7, C5B689A94B459F54 +// program: 0000000000000000, 0000000000000000, C5B689A94B459F54 +// shader: 8B30, 122AF7252C3959A4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287A4B65F6DC, 122AF7252C3959A4 +// program: 0000000000000000, 0000000000000000, 122AF7252C3959A4 +// shader: 8B31, B3BA993F3884A0DD + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0.x = dot_s(uniforms.f[0], vs_in_reg0); + vs_out_attr0.y = dot_s(uniforms.f[1], vs_in_reg0); + vs_out_attr0.z = dot_s(uniforms.f[2], vs_in_reg0); + vs_out_attr0.w = dot_s(uniforms.f[3], vs_in_reg0); + vs_out_attr1 = vs_in_reg1.xyxy; + return true; +} +// reference: F8C3C3D47F137573, B3BA993F3884A0DD +// shader: 8DD9, CA7A5FBE4D339F65 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[1].z, vtx.attributes[1].w); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 4A90D8FC4D93BB15, CA7A5FBE4D339F65 +// reference: 3F41287A4B386295, 12433E7DDE265EFC +// program: B3BA993F3884A0DD, CA7A5FBE4D339F65, 12433E7DDE265EFC +// shader: 8B30, B1800659FBAEDBE8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2584B8EBE3DDB045, B1800659FBAEDBE8 +// program: B3BA993F3884A0DD, CA7A5FBE4D339F65, B1800659FBAEDBE8 +// shader: 8B30, 4F691F5A00C1A34B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3F41287ADFA24D27, 4F691F5A00C1A34B +// program: 0000000000000000, 0000000000000000, 4F691F5A00C1A34B +// shader: 8B30, EAD385646656F9C4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) - (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) + (combiner_buffer.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rrr) + (combiner_buffer.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3 * 1.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rrr) + (combiner_buffer.bbb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 4.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((1.0 - last_tex_env_out.a) * (last_tex_env_out.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52EE755D3ED2276A, EAD385646656F9C4 +// program: 0000000000000000, 0000000000000000, EAD385646656F9C4 +// shader: 8B30, BEE6D99B785EA1A0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rrr) + (last_tex_env_out.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.b); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4 * 1.0, alpha_output_4 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 82BF8CF159E7107B, BEE6D99B785EA1A0 +// program: 0000000000000000, 0000000000000000, BEE6D99B785EA1A0 +// shader: 8B30, F6CF3D5C02E13B08 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor1.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4609680CE94C8269, F6CF3D5C02E13B08 +// program: 0000000000000000, 0000000000000000, F6CF3D5C02E13B08 +// shader: 8B30, ECACC28486ECD4F1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((combiner_buffer.rgb) - (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) - (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2 * 4.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = byteround(clamp((last_tex_env_out.r) + (last_tex_env_out.g), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (texcolor0.rgb); +float alpha_output_5 = byteround(clamp((combiner_buffer.b) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5 * 1.0, alpha_output_5 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0A58247ACA2506B4, ECACC28486ECD4F1 +// program: 0000000000000000, 0000000000000000, ECACC28486ECD4F1 +// reference: 66BB7756D9C70765, 4DFD84F1D4CE3747 +// reference: 66BB77562C238BE0, 6934EFAB6214C050 +// shader: 8B30, 33E9C4BE7724DE81 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E680F6A5B46, 33E9C4BE7724DE81 +// program: 0000000000000000, 0000000000000000, 33E9C4BE7724DE81 diff --git a/cache/0004000000158D00.shader.meta b/cache/0004000000158D00.shader.meta new file mode 100644 index 00000000000..f965df30a11 --- /dev/null +++ b/cache/0004000000158D00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 19 +reference: 23 +program: 16 diff --git a/cache/000400000018A400.shader b/cache/000400000018A400.shader new file mode 100644 index 00000000000..7f3d1504106 --- /dev/null +++ b/cache/000400000018A400.shader @@ -0,0 +1,8951 @@ +// shader: 8B31, 3539DDEF1DA85349 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0.x = (vs_in_reg0.xxxx).x; + reg_tmp0.y = (vs_in_reg0.yyyy).y; + reg_tmp0.z = (vs_in_reg0.zzzz).z; + reg_tmp0.w = (uniforms.f[90].zzzz).w; + reg_tmp1.x = dot_s(uniforms.f[4], reg_tmp0); + reg_tmp1.y = dot_s(uniforms.f[5], reg_tmp0); + reg_tmp1.z = dot_s(uniforms.f[6], reg_tmp0); + reg_tmp1.w = (uniforms.f[90].zzzz).w; + reg_tmp2.z = (abs(reg_tmp1.zzzz)).z; + reg_tmp2.z = (uniforms.f[10].zzzz + reg_tmp2.zzzz).z; + reg_tmp2.x = (uniforms.f[10].xxxx).x; + conditional_code = notEqual(uniforms.f[90].xx, reg_tmp2.xz); + if (all(conditional_code)) { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp1); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp1); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp1); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp1); + vs_out_attr1 = vs_in_reg1; + return true; +} +bool sub_1() { + reg_tmp2.y = (-uniforms.f[10].yyyy + reg_tmp2.zzzz).y; + reg_tmp2.z = rcp_s(reg_tmp2.z); + reg_tmp2.z = (mul_s(reg_tmp2.yyyy, reg_tmp2.zzzz)).z; + reg_tmp1.x = (fma_s(reg_tmp2.xxxx, reg_tmp2.zzzz, reg_tmp1.xxxx)).x; + return false; +} +// reference: E268988761D3B20C, 3539DDEF1DA85349 +// shader: 8DD9, 6B49BF5FD5349480 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +struct Vertex { + vec4 attributes[2]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(0.0, 0.0); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[2](vs_out_attr0[0], vs_out_attr1[0]); + prim_buffer[1].attributes = vec4[2](vs_out_attr0[1], vs_out_attr1[1]); + prim_buffer[2].attributes = vec4[2](vs_out_attr0[2], vs_out_attr1[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: E0A3E62E72D05152, 6B49BF5FD5349480 +// shader: 8B30, 689218E786681D8C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8FBEBCC656AC84D8, 689218E786681D8C +// program: 3539DDEF1DA85349, 6B49BF5FD5349480, 689218E786681D8C +// shader: 8B31, 7C96EBECB346C618 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_1(); +bool sub_0(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_5() { + reg_tmp13 = floor(reg_tmp0.xxxx); + reg_tmp13 = reg_tmp0.xxxx + -reg_tmp13; + address_registers.y = (ivec2(reg_tmp11.zz)).y; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_6(); + } + conditional_code = lessThanEqual(uniforms.f[5].yy, reg_tmp11.xy); + if (!conditional_code.y) { + sub_15(); + } else { + sub_22(); + } + return false; +} +bool sub_6() { + reg_tmp12.xy = (uniforms.f[5].xyyy + vs_in_reg0.zwww).xy; + reg_tmp14.xy = (uniforms.f[6].wzzz).xy; + reg_tmp13.xy = (mul_s(uniforms.f[5].zzzz, reg_tmp0.xxxx)).xy; + reg_tmp13.y = (floor(reg_tmp13)).y; + reg_tmp13.x = (reg_tmp13.xxxx + -reg_tmp13.yyyy).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_7(); + } + reg_tmp14.xy = (mul_s(reg_tmp14, reg_tmp2)).xy; + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_8(); + } + if (conditional_code.x) { + sub_9(); + } + reg_tmp14.xy = (uniforms.f[5].yyyy + -reg_tmp14.xyyy).xy; + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_10(); + } + if (conditional_code.x) { + sub_11(); + } + reg_tmp13.x = (mul_s(uniforms.f[5].zzzz, reg_tmp13.xxxx)).x; + reg_tmp13 = mul_s(uniforms.f[5].zyzy, reg_tmp13.xxxx); + reg_tmp13.zw = (floor(reg_tmp13)).zw; + reg_tmp13.xy = (reg_tmp13.xyyy + -reg_tmp13.zwww).xy; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xy); + if (conditional_code.y) { + sub_12(); + } + if (conditional_code.x) { + sub_13(); + } + reg_tmp13.xy = (mul_s(uniforms.f[5].zzzz, reg_tmp0.xxxx)).xy; + reg_tmp13.y = (floor(reg_tmp13)).y; + reg_tmp13.x = (reg_tmp13.xxxx + -reg_tmp13.yyyy).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_14(); + } + reg_tmp12.y = (uniforms.f[5].yyyy + -reg_tmp12.yyyy).y; + return false; +} +bool sub_7() { + reg_tmp14.xy = (reg_tmp14.yxxx).xy; + return false; +} +bool sub_8() { + reg_tmp12.x = (mul_s(reg_tmp12.xxxx, reg_tmp14.xxxx)).x; + return false; +} +bool sub_9() { + reg_tmp12.y = (fma_s(reg_tmp12.yyyy, reg_tmp14.yyyy, uniforms.f[5].yyyy)).y; + reg_tmp12.y = (reg_tmp12.yyyy + -reg_tmp14.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp12.x = (reg_tmp12.xxxx + reg_tmp14.xxxx).x; + return false; +} +bool sub_11() { + reg_tmp12.y = (reg_tmp12.yyyy + -reg_tmp14.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp12.x = (uniforms.f[5].yyyy + -reg_tmp12.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp12.y = (uniforms.f[5].yyyy + -reg_tmp12.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp12.xy = (uniforms.f[5].yyyy + -reg_tmp12.yxxx).xy; + return false; +} +bool sub_15() { + reg_tmp13.x = (floor(reg_tmp0.xxxx)).x; + reg_tmp13.x = (reg_tmp0.xxxx + -reg_tmp13).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + reg_tmp13 = uniforms.f[32 + address_registers.y].wzyx; + if (conditional_code.x) { + sub_16(); + } else { + sub_17(); + } + reg_tmp11.z = (uniforms.f[5].yyyy + reg_tmp11.zzzz).z; + return false; +} +bool sub_16() { + reg_tmp11.xy = (fma_s(reg_tmp12.xyyy, reg_tmp13.xyyy, reg_tmp13.zwww)).xy; + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp14.zwww)).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_17() { + conditional_code = notEqual(uniforms.f[5].xx, vs_in_reg0.zw); + if (!conditional_code.x) { + sub_18(); + } else { + sub_19(); + } + if (!conditional_code.y) { + sub_20(); + } else { + sub_21(); + } + return false; +} +bool sub_18() { + reg_tmp11.x = (reg_tmp13.xxxx).x; + return false; +} +bool sub_19() { + reg_tmp11.x = (reg_tmp13.zzzz).x; + return false; +} +bool sub_20() { + reg_tmp11.y = (reg_tmp13.yyyy).y; + return false; +} +bool sub_21() { + reg_tmp11.y = (reg_tmp13.wwww).y; + return false; +} +bool sub_22() { + if (!conditional_code.x) { + sub_23(); + } else { + sub_32(); + } + reg_tmp11.z = (uniforms.f[5].zzzz + reg_tmp11.zzzz).z; + return false; +} +bool sub_23() { + reg_tmp13.x = (floor(reg_tmp0.xxxx)).x; + reg_tmp13.x = (reg_tmp0.xxxx + -reg_tmp13).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp13.xx); + if (conditional_code.x) { + sub_24(); + } else { + sub_25(); + } + return false; +} +bool sub_24() { + reg_tmp12.zw = (uniforms.f[5].xxxy).zw; + reg_tmp11.x = dot_s(uniforms.f[32 + address_registers.y].wzyx, reg_tmp12); + reg_tmp11.y = dot_s(uniforms.f[33 + address_registers.y].wzyx, reg_tmp12); + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp14.zwww)).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_25() { + reg_tmp14 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp13 = uniforms.f[33 + address_registers.y].wzyx; + conditional_code = notEqual(uniforms.f[5].xx, vs_in_reg0.zw); + if (!conditional_code.y) { + sub_26(); + } else { + sub_29(); + } + return false; +} +bool sub_26() { + if (!conditional_code.x) { + sub_27(); + } else { + sub_28(); + } + return false; +} +bool sub_27() { + reg_tmp11.xy = (reg_tmp14.xyyy).xy; + return false; +} +bool sub_28() { + reg_tmp11.xy = (reg_tmp13.zwww).xy; + return false; +} +bool sub_29() { + if (!conditional_code.x) { + sub_30(); + } else { + sub_31(); + } + return false; +} +bool sub_30() { + reg_tmp11.xy = (reg_tmp13.xyyy).xy; + return false; +} +bool sub_31() { + reg_tmp11.xy = (reg_tmp14.zwww).xy; + return false; +} +bool sub_32() { + reg_tmp11.x = dot_s(uniforms.f[32 + address_registers.y].wzyx, reg_tmp1); + reg_tmp11.y = dot_s(uniforms.f[33 + address_registers.y].wzyx, reg_tmp1); + return false; +} +bool sub_1() { + uint jmp_to = 97u; + while (true) { + switch (jmp_to) { + case 97u: { + reg_tmp3.x = dot_s(uniforms.f[32 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.y = dot_s(uniforms.f[33 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.z = dot_s(uniforms.f[34 + address_registers.x].wzyx, reg_tmp1); + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp11 = uniforms.f[4].wzyx; + reg_tmp11.z = (-uniforms.f[34 + address_registers.x].xxxx + reg_tmp11.zzzz).z; + conditional_code.x = uniforms.f[5].xxxx.x != reg_tmp11.xzzz.x; + conditional_code.y = uniforms.f[5].xxxx.y < reg_tmp11.xzzz.y; + if (any(not(conditional_code))) { + { jmp_to = 108u; break; } + } + reg_tmp11.z = rcp_s(reg_tmp11.z); + reg_tmp3.x = (reg_tmp3.xxxx + reg_tmp11.xxxx).x; + reg_tmp3.x = (fma_s(-reg_tmp11.yyyy, reg_tmp11.zzzz, reg_tmp3.xxxx)).x; + } + case 108u: { + } + default: return false; + } + } + return false; +} +bool sub_0() { + uint jmp_to = 109u; + while (true) { + switch (jmp_to) { + case 109u: { + address_registers.x = (ivec2(vs_in_reg0.xx)).x; + reg_tmp0 = uniforms.f[9 + address_registers.x].wzyx; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (uniforms.f[5].xyxy).zw; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp2 = uniforms.f[32 + address_registers.y].wzyx; + if (uniforms.b[0]) { + { jmp_to = 191u; break; } + } + reg_tmp4 = uniforms.f[31 + address_registers.x].wzyx; + reg_tmp1.xy = (fma_s(reg_tmp1.xyyy, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + conditional_code = greaterThanEqual(uniforms.f[5].yy, reg_tmp0.ww); + if (all(conditional_code)) { + sub_2(); + } else { + sub_3(); + } + reg_tmp11.z = (reg_tmp0.zzzz).z; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp0.zzzz); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[6].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[1]) { + sub_33(); + } + if (uniforms.b[2]) { + sub_34(); + } + vs_out_attr2 = reg_tmp11.xyyy; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp9.xxxx); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[7].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[3]) { + sub_35(); + } + if (uniforms.b[4]) { + sub_36(); + } + vs_out_attr3 = reg_tmp11.xyyy; + reg_tmp9 = mul_s(uniforms.f[5].zyzy, reg_tmp9.xxxx); + reg_tmp9.xy = (floor(reg_tmp9)).xy; + reg_tmp9.xy = (reg_tmp9.zwww + -reg_tmp9.xyyy).xy; + reg_tmp9 = mul_s(uniforms.f[5].zzzz, reg_tmp9); + reg_tmp14 = uniforms.f[8].wzyx; + reg_tmp11.xy = (reg_tmp9.xyyy).xy; + { + sub_5(); + } + if (uniforms.b[5]) { + sub_37(); + } + if (uniforms.b[6]) { + sub_38(); + } + vs_out_attr4 = reg_tmp11.xyyy; + return true; + } + case 191u: { + reg_tmp2.w = (reg_tmp2.wwww + reg_tmp2.yyyy).w; + reg_tmp1.y = (-uniforms.f[5].yyyy + -reg_tmp1.yyyy).y; + reg_tmp13.xy = (mul_s(uniforms.f[36 + address_registers.x].wzzz, reg_tmp2.xyyy)).xy; + reg_tmp11.x = (mul_s(uniforms.f[35 + address_registers.x].wwww, -reg_tmp1.yyyy)).x; + reg_tmp1.xy = (mul_s(reg_tmp1.xyyy, reg_tmp13.xyyy)).xy; + reg_tmp1.x = (reg_tmp1.xxxx + reg_tmp11.xxxx).x; + if (uniforms.b[1]) { + sub_39(); + } + reg_tmp1.xy = (reg_tmp1.xyyy + reg_tmp2.zwww).xy; + reg_tmp1.xy = (uniforms.f[36 + address_registers.x].yxxx + reg_tmp1.xyyy).xy; + { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + if (uniforms.b[2]) { + sub_40(); + } else { + sub_41(); + } + reg_tmp8 = reg_tmp8 + -reg_tmp7; + vs_out_attr1 = fma_s(reg_tmp8, reg_tmp11.yyyy, reg_tmp7); + reg_tmp9.xy = (mul_s(uniforms.f[32 + address_registers.x].yxxx, reg_tmp11)).xy; + reg_tmp11.zw = (vec4(lessThan(reg_tmp11, uniforms.f[5].yyyy))).zw; + reg_tmp9.xy = (fma_s(reg_tmp11.zwww, uniforms.f[32 + address_registers.x].wzzz, reg_tmp9.xyyy)).xy; + reg_tmp9.y = (uniforms.f[5].yyyy + -reg_tmp9.yyyy).y; + vs_out_attr2 = reg_tmp9; + vs_out_attr3 = reg_tmp9; + vs_out_attr4 = reg_tmp9; + return true; + } + default: return false; + } + } + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[5].yyyy).xyz; + vs_out_attr1.w = (reg_tmp0.wwww).w; + return false; +} +bool sub_3() { + address_registers.y = (ivec2(reg_tmp0.ww)).y; + reg_tmp7 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp8 = uniforms.f[33 + address_registers.y].wzyx; + reg_tmp9 = uniforms.f[34 + address_registers.y].wzyx; + reg_tmp10 = uniforms.f[35 + address_registers.y].wzyx; + reg_tmp11.xy = (vs_in_reg0.zwww).xy; + reg_tmp14.x = (floor(reg_tmp0.yyyy)).x; + reg_tmp14.x = (reg_tmp0.yyyy + -reg_tmp14.xxxx).x; + conditional_code = lessThanEqual(uniforms.f[5].ww, reg_tmp14.xx); + if (conditional_code.x) { + sub_4(); + } + reg_tmp11.xy = (abs(reg_tmp11.xyyy)).xy; + reg_tmp8 = reg_tmp8 + -reg_tmp7; + reg_tmp8 = fma_s(reg_tmp8, reg_tmp11.xxxx, reg_tmp7); + reg_tmp10 = reg_tmp10 + -reg_tmp9; + reg_tmp10 = fma_s(reg_tmp10, reg_tmp11.xxxx, reg_tmp9); + reg_tmp10 = reg_tmp10 + -reg_tmp8; + reg_tmp10 = fma_s(reg_tmp10, reg_tmp11.yyyy, reg_tmp8); + vs_out_attr1 = reg_tmp10; + return false; +} +bool sub_4() { + reg_tmp11.z = rcp_s(reg_tmp4.x); + reg_tmp11.w = rcp_s(reg_tmp4.y); + reg_tmp11.xy = (reg_tmp1.xyyy + -reg_tmp4.zwww).xy; + reg_tmp11.xy = (mul_s(reg_tmp11.xyyy, reg_tmp11.zwww)).xy; + return false; +} +bool sub_33() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_34() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_35() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_36() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_37() { + reg_tmp11.xy = (reg_tmp11.yxxx).xy; + reg_tmp11.y = (uniforms.f[5].yyyy + -reg_tmp11.yyyy).y; + return false; +} +bool sub_38() { + reg_tmp11.xy = (uniforms.f[5].yyyy + -reg_tmp11.yxxx).xy; + return false; +} +bool sub_39() { + reg_tmp13.xzw = (mul_s(uniforms.f[5].wxxx, reg_tmp13.xxxx)).xzw; + reg_tmp13.y = (mul_s(uniforms.f[34 + address_registers.y].yyyy, reg_tmp13.yyyy)).y; + reg_tmp11 = fma_s(reg_tmp1, uniforms.f[5].yyxx, -reg_tmp13); + reg_tmp14 = uniforms.f[33 + address_registers.y].wzyx; + reg_tmp1.x = dot_3(reg_tmp11.xyz, reg_tmp14.xyy); + reg_tmp1.y = dot_3(reg_tmp11.xyz, reg_tmp14.zww); + reg_tmp14 = uniforms.f[34 + address_registers.y].wzyx; + reg_tmp1.z = dot_s(vec4(reg_tmp11.xyz, 1.0), reg_tmp14); + reg_tmp1.xy = (reg_tmp1.xyyy + reg_tmp13.xyyy).xy; + return false; +} +bool sub_40() { + reg_tmp11 = abs(vs_in_reg0.zwzw); + reg_tmp14.w = (floor(reg_tmp0.zzzz)).w; + reg_tmp14.w = (reg_tmp0.zzzz + -reg_tmp14).w; + address_registers.xy = ivec2(reg_tmp0.zx); + reg_tmp14.w = (mul_s(uniforms.f[5].zzzz, reg_tmp14.wwww)).w; + reg_tmp14.xyz = (uniforms.f[5].yyyy).xyz; + reg_tmp7 = mul_s(uniforms.f[37 + address_registers.y].wzyx, reg_tmp14); + reg_tmp8 = mul_s(uniforms.f[38 + address_registers.y].wzyx, reg_tmp14); + return false; +} +bool sub_41() { + reg_tmp11 = abs(vs_in_reg0.zwzw); + address_registers.xy = ivec2(reg_tmp0.zw); + reg_tmp7 = uniforms.f[32 + address_registers.y].wzyx; + reg_tmp8 = uniforms.f[33 + address_registers.y].wzyx; + return false; +} +// reference: 7F87A97685750974, 7C96EBECB346C618 +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B30, 1FC0926CA52913E2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 80466EB69D9A02F4, 1FC0926CA52913E2 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 1FC0926CA52913E2 +// shader: 8B30, B8C305A6C6465AF1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) - (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a) + (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 377B0429C0E7B2D6, B8C305A6C6465AF1 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, B8C305A6C6465AF1 +// shader: 8B30, 10C80DAE0B3C88A8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 80466EB66D32DDB4, 10C80DAE0B3C88A8 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 10C80DAE0B3C88A8 +// shader: 8B30, 2B46AB02AADCE248 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B5966F2D77044641, 2B46AB02AADCE248 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 2B46AB02AADCE248 +// shader: 8B30, 4866D01897FF6888 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B5966F2D8C9B6315, 4866D01897FF6888 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 4866D01897FF6888 +// shader: 8B30, 774503F333F737B4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B5966F2D7C33BC55, 774503F333F737B4 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 774503F333F737B4 +// reference: AC3C67C7E226D47E, 3539DDEF1DA85349 +// reference: 8FBEBCC6576EEEEF, 689218E786681D8C +// shader: 8B30, 82A5D77EA64BBC20 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) < alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 80466EB616DA7D81, 82A5D77EA64BBC20 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 82A5D77EA64BBC20 +// shader: 8B30, 805B3A1E46C42199 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].aaa); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B0FE71FD3E377EDD, 805B3A1E46C42199 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 805B3A1E46C42199 +// reference: E2689887E226D47E, 3539DDEF1DA85349 +// reference: 896F315385750974, 7C96EBECB346C618 +// shader: 8B30, 6FE200724A5E1776 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (last_tex_env_out.a) + (last_tex_env_out.a) * (1.0 - (last_tex_env_out.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9970BD08A3FFE1A0, 6FE200724A5E1776 +// program: 0000000000000000, 0000000000000000, 6FE200724A5E1776 +// shader: 8B30, 2BBBCA1742D811FB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DA43396668, 2BBBCA1742D811FB +// program: 0000000000000000, 0000000000000000, 2BBBCA1742D811FB +// shader: 8B30, E4A051727AE746AB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 452A29A7257FBF37, E4A051727AE746AB +// program: 0000000000000000, 0000000000000000, E4A051727AE746AB +// shader: 8B30, 5103D850AD98D3D0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAFC8B2E02, 5103D850AD98D3D0 +// program: 0000000000000000, 0000000000000000, 5103D850AD98D3D0 +// shader: 8B30, EA0CF839D1E0413B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAB8D917D1, EA0CF839D1E0413B +// program: 0000000000000000, 0000000000000000, EA0CF839D1E0413B +// shader: 8B30, 7DACF911E65AB1DA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAA3FFE1A0, 7DACF911E65AB1DA +// program: 0000000000000000, 0000000000000000, 7DACF911E65AB1DA +// shader: 8DD9, 0D30074279C2FEED + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[6].x, vtx.attributes[6].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: FC74FA4ACA1C8C74, 0D30074279C2FEED +// shader: 8B31, AD59F7578304A674 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_21(); +bool sub_4(); +bool sub_9(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_5(); +bool sub_7(); +bool sub_8(); +bool sub_10(); +bool sub_20(); +bool sub_22(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_6(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_44(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_45(); +bool sub_46(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_55(); +bool sub_57(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_56(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_66(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + { + sub_1(); + } + { + sub_30(); + } + { + sub_45(); + } + { + sub_59(); + } + { + sub_66(); + } + return true; +} +bool sub_21() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_4() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_9() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_23(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2 = mul_s(uniforms.f[93].wwww, vs_in_reg7); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_3(); + } else { + sub_7(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_4(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_4(); + } + if (uniforms.b[8]) { + sub_5(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_5() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_4(); + } + return false; +} +bool sub_7() { + if (all(conditional_code)) { + sub_8(); + } else { + sub_20(); + } + return false; +} +bool sub_8() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_9(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_9(); + } + if (uniforms.b[8]) { + sub_10(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_20() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (reg_tmp2.xxxx).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.yyyy).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_21(); + } + reg_tmp1.xy = (reg_tmp2.zzzz).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_21(); + } + if (uniforms.b[8]) { + sub_22(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_22() { + reg_tmp1.xy = (reg_tmp2.wwww).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_21(); + } + return false; +} +bool sub_23() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_24(); + } else { + sub_25(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_26(); + } else { + sub_27(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_24() { + reg_tmp1.x = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).x; + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_25() { + address_registers.x = (ivec2(uniforms.f[93].xx)).x; + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_26() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_6(); + } + return false; +} +bool sub_27() { + if (all(conditional_code)) { + sub_28(); + } else { + sub_29(); + } + return false; +} +bool sub_28() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.x].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_11(); + } + return false; +} +bool sub_29() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_6() { + uint jmp_to = 202u; + while (true) { + switch (jmp_to) { + case 202u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 218u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 218u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 218u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_11() { + uint jmp_to = 219u; + while (true) { + switch (jmp_to) { + case 219u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 294u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 256u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 294u; break; } + } + } + case 256u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_12(); + } else { + sub_17(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 294u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_12() { + if (conditional_code.y) { + sub_13(); + } else { + sub_14(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_13() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_14() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_17() { + if (conditional_code.y) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_19() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_30() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_31(); + } + if (uniforms.b[12]) { + sub_33(); + } + if (uniforms.b[5]) { + sub_42(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_44(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_31() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_32(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_32() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_44() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_33() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop315 = 0u; loop315 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop315) { + sub_34(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_34() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[81 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[83 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_35(); + } else { + sub_36(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_41(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_35() { + reg_tmp6.x = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_36() { + reg_tmp4 = uniforms.f[81 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_37(); + } + reg_tmp5 = uniforms.f[82 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_38(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_37() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[83 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_38() { + reg_tmp5.x = dot_3(uniforms.f[82 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[84 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_39(); + } else { + sub_40(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_39() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_40() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[84 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_41() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[80 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_42() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_43(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_43() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_46(); + } else { + sub_52(); + } + return false; +} +bool sub_46() { + { + sub_47(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_52() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_53(); + } else { + sub_54(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_53() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_54() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + { + sub_56(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_57() { + { + sub_58(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_49(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_48() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_49() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_50(); + } else { + sub_51(); + } + return false; +} +bool sub_50() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_56() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_58() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_59() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_60(); + } else { + sub_61(); + } + return false; +} +bool sub_60() { + { + sub_47(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_61() { + if (uniforms.b[13]) { + sub_62(); + } else { + sub_65(); + } + return false; +} +bool sub_62() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_63(); + } else { + sub_64(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_63() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_64() { + { + sub_58(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_65() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_66() { + reg_tmp0.xy = (uniforms.f[10].zzzz).xy; + if (uniforms.b[11]) { + sub_67(); + } else { + sub_68(); + } + return false; +} +bool sub_67() { + { + sub_47(); + } + reg_tmp5.x = dot_s(uniforms.f[17].xywz, reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18].xywz, reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_68() { + if (uniforms.b[14]) { + sub_69(); + } else { + sub_70(); + } + return false; +} +bool sub_69() { + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp5.zw = (reg_tmp6.zwww).zw; + { + sub_58(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_70() { + vs_out_attr6 = uniforms.f[93].xxxx; + return false; +} +// reference: 9249CF40B7A5CAAA, AD59F7578304A674 +// shader: 8B30, FED49714AFF27B3A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = (lut_scale_rr * LookupLightingLUTSigned(6, dot(normal, normalize(half_vector)))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1C3F38D474722F45, FED49714AFF27B3A +// program: AD59F7578304A674, 0D30074279C2FEED, FED49714AFF27B3A +// shader: 8B30, D5CE7D5FE2C0E75D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = (lut_scale_rr * LookupLightingLUTSigned(6, dot(normal, normalize(half_vector)))); +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (refl_value * light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1C3F38D4DC97FD95, D5CE7D5FE2C0E75D +// program: AD59F7578304A674, 0D30074279C2FEED, D5CE7D5FE2C0E75D +// shader: 8B30, 8AAB98604BC01DF3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].aaa); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40FA503EE9180F93, 8AAB98604BC01DF3 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 8AAB98604BC01DF3 +// shader: 8B30, F3D657DC8CE6D127 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].aaa); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40FA503EE22FF587, F3D657DC8CE6D127 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, F3D657DC8CE6D127 +// shader: 8B30, 8C2073BB0D2583D6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].aaa); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40FA503E12872AC7, 8C2073BB0D2583D6 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, 8C2073BB0D2583D6 +// shader: 8B30, DF41007E03A99F56 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) - (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (const_color[0].a) + (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].aaa); +float alpha_output_1 = (texcolor0.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F7C73AA1BF5245A5, DF41007E03A99F56 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, DF41007E03A99F56 +// shader: 8B30, BA947C8942732C02 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) - (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = (const_color[3].a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B5966F2D87AC9901, BA947C8942732C02 +// program: 7C96EBECB346C618, 1C4CBC8096EA16CD, BA947C8942732C02 +// shader: 8B30, 1E7B6AE25EF42DA5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1B356D66A512B7AC, 1E7B6AE25EF42DA5 +// program: 0000000000000000, 0000000000000000, 1E7B6AE25EF42DA5 +// shader: 8B30, EE9D59D3D057292A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DA45D43064, EE9D59D3D057292A +// program: 0000000000000000, 0000000000000000, EE9D59D3D057292A +// shader: 8B30, F789075555A6DC0C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 452A29A72392E93B, F789075555A6DC0C +// program: 0000000000000000, 0000000000000000, F789075555A6DC0C +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAFA66780E, B35EFE43E319BB63 +// program: 0000000000000000, 0000000000000000, B35EFE43E319BB63 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DABE3441DD, DC12E218392F9BDB +// program: 0000000000000000, 0000000000000000, DC12E218392F9BDB +// shader: 8B30, 828B17C8889F4FA8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAA512B7AC, 828B17C8889F4FA8 +// program: 0000000000000000, 0000000000000000, 828B17C8889F4FA8 +// shader: 8B30, 24E6FB097480A597 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 1C3F38D4C8CAB375, 24E6FB097480A597 +// program: 0000000000000000, 0000000000000000, 24E6FB097480A597 +// shader: 8B30, 36C97EDF2A28E6E4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DA280C34BD, 36C97EDF2A28E6E4 +// program: 0000000000000000, 0000000000000000, 36C97EDF2A28E6E4 +// shader: 8B30, 491BA705335CC1FF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 452A29A74E4AEDE2, 491BA705335CC1FF +// program: 0000000000000000, 0000000000000000, 491BA705335CC1FF +// shader: 8B30, 2731D021649C0914 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DA97BE7CD7, 2731D021649C0914 +// program: 0000000000000000, 0000000000000000, 2731D021649C0914 +// shader: 8B30, 0BE6F3E0F47A66DE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAD3EC4504, 0BE6F3E0F47A66DE +// program: 0000000000000000, 0000000000000000, 0BE6F3E0F47A66DE +// shader: 8B30, 49D9C4085F76B7DD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ABCAF9DAC8CAB375, 49D9C4085F76B7DD +// program: 0000000000000000, 0000000000000000, 49D9C4085F76B7DD +// shader: 8DD9, 13A54CCD8AA1DDA2 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: A55C6948CCF76B42, 13A54CCD8AA1DDA2 +// shader: 8B31, 8673C92174977329 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_7(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_7() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.x = (uniforms.f[90].xxxx).x; + reg_tmp6.y = (uniforms.f[91].xxxx).y; + reg_tmp6.z = (uniforms.f[92].xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (uniforms.f[90].yyyy).x; + reg_tmp7.y = (uniforms.f[91].yyyy).y; + reg_tmp7.z = (uniforms.f[92].yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (uniforms.f[90].zzzz).x; + reg_tmp8.y = (uniforms.f[91].zzzz).y; + reg_tmp8.z = (uniforms.f[92].zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_7(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: D09FB1D6DC9B34B3, 8673C92174977329 +// shader: 8B30, F563EBBF4CF9B403 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9B829F9A3E737D07, F563EBBF4CF9B403 +// program: 8673C92174977329, 13A54CCD8AA1DDA2, F563EBBF4CF9B403 +// shader: 8B31, 15B7E28495255EC5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_8(); +bool sub_2(); +bool sub_3(); +bool sub_6(); +bool sub_7(); +bool sub_0(); +bool sub_4(); +bool sub_5(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_8() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_3() { + reg_tmp6.x = (uniforms.f[90].xxxx).x; + reg_tmp6.y = (uniforms.f[91].xxxx).y; + reg_tmp6.z = (uniforms.f[92].xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (uniforms.f[90].yyyy).x; + reg_tmp7.y = (uniforms.f[91].yyyy).y; + reg_tmp7.z = (uniforms.f[92].yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (uniforms.f[90].zzzz).x; + reg_tmp8.y = (uniforms.f[91].zzzz).y; + reg_tmp8.z = (uniforms.f[92].zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_6() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_7() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4.xy = (mul_s(vs_in_reg0.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-vs_in_reg0.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(vs_in_reg0.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp0 = uniforms.f[7 + address_registers.x]; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp10 = reg_tmp2; + { + sub_3(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_6(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_7(); + } + { + sub_8(); + } + return true; +} +bool sub_4() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_5() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 0A7425230B44F628, 15B7E28495255EC5 +// program: 15B7E28495255EC5, 13A54CCD8AA1DDA2, F563EBBF4CF9B403 +// shader: 8B30, 23DAC15A4CF9B403 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4588B16A3E737D07, 23DAC15A4CF9B403 +// program: 15B7E28495255EC5, 13A54CCD8AA1DDA2, 23DAC15A4CF9B403 +// shader: 8B30, E0D0545C16A51CB4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 47E33AB266CD3357, E0D0545C16A51CB4 +// program: 15B7E28495255EC5, 13A54CCD8AA1DDA2, E0D0545C16A51CB4 +// reference: 64A15765B7A5CAAA, AD59F7578304A674 diff --git a/cache/000400000018A400.shader.meta b/cache/000400000018A400.shader.meta new file mode 100644 index 00000000000..6b3e7e6c3ba --- /dev/null +++ b/cache/000400000018A400.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 46 +reference: 51 +program: 38 diff --git a/cache/00040000001A4800.shader b/cache/00040000001A4800.shader new file mode 100644 index 00000000000..48a73663f17 --- /dev/null +++ b/cache/00040000001A4800.shader @@ -0,0 +1,17028 @@ +// shader: 8B31, 3BC00FBFE97A550F + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp1 = abs(vs_in_reg0); + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp2 = uniforms.f[18 + address_registers.x]; + reg_tmp3 = uniforms.f[19 + address_registers.x]; + reg_tmp15.xy = (mul_s(uniforms.f[91 + address_registers.y].xyyy, reg_tmp2.xyyy)).xy; + reg_tmp15.xy = (reg_tmp15.xyyy + reg_tmp2.zwww).xy; + reg_tmp15.zw = (uniforms.f[95].xyyy).zw; + reg_tmp8.x = dot_s(uniforms.f[8], reg_tmp15); + reg_tmp8.y = dot_s(uniforms.f[9], reg_tmp15); + reg_tmp8.z = dot_s(uniforms.f[10], reg_tmp15); + reg_tmp8.w = (uniforms.f[95].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[4], reg_tmp8); + reg_tmp15.y = dot_s(uniforms.f[5], reg_tmp8); + reg_tmp15.z = dot_s(uniforms.f[6], reg_tmp8); + reg_tmp15.w = (uniforms.f[95].yyyy).w; + if (uniforms.b[3]) { + sub_1(); + } + reg_tmp10 = uniforms.f[95].yyyy; + if (uniforms.b[0]) { + sub_2(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp15); + vs_out_attr1 = reg_tmp10; + if (uniforms.b[1]) { + sub_5(); + } else { + sub_12(); + } + reg_tmp12 = uniforms.f[95].xxxx; + if (uniforms.b[2]) { + sub_13(); + } + vs_out_attr2.xy = (reg_tmp11.xyyy).xy; + vs_out_attr2.z = (reg_tmp11.zzzz).z; + vs_out_attr2.w = (uniforms.f[95].xxxx).w; + vs_out_attr3.xy = (reg_tmp12.xyyy).xy; + vs_out_attr3.zw = (uniforms.f[95].xxxx).zw; + return true; +} +bool sub_1() { + reg_tmp0.z = (reg_tmp15.zzzz).z; + reg_tmp0.z = (abs(reg_tmp0.zzzz)).z; + reg_tmp0.x = (uniforms.f[11].xxxx).x; + reg_tmp0.y = (-uniforms.f[11].yyyy + reg_tmp0.zzzz).y; + reg_tmp0.z = rcp_s(reg_tmp0.z); + reg_tmp0.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.zzzz)).z; + reg_tmp15.x = (fma_s(reg_tmp0.xxxx, reg_tmp0.zzzz, reg_tmp15.xxxx)).x; + return false; +} +bool sub_2() { + conditional_code = greaterThan(uniforms.f[95].xx, reg_tmp3.xx); + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + return false; +} +bool sub_3() { + reg_tmp3 = abs(reg_tmp3); + reg_tmp3.x = (reg_tmp3.xxxx + vs_in_reg0.yyyy).x; + address_registers.y = (ivec2(reg_tmp3.xx)).y; + reg_tmp10 = uniforms.f[0 + address_registers.y]; + return false; +} +bool sub_4() { + reg_tmp10 = reg_tmp3; + return false; +} +bool sub_5() { + conditional_code = equal(uniforms.f[95].zw, reg_tmp1.yy); + if (all(not(conditional_code))) { + sub_6(); + } else { + sub_9(); + } + reg_tmp11.x = dot_s(uniforms.f[12], reg_tmp10); + reg_tmp11.y = dot_s(uniforms.f[13], reg_tmp10); + reg_tmp11.zw = (uniforms.f[95].xxxx).zw; + return false; +} +bool sub_6() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp1.yy); + if (conditional_code.x) { + sub_7(); + } else { + sub_8(); + } + return false; +} +bool sub_7() { + reg_tmp10.xy = (uniforms.f[20 + address_registers.x].xyyy).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_8() { + reg_tmp10.xy = (uniforms.f[20 + address_registers.x].zwww).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_9() { + if (conditional_code.x) { + sub_10(); + } else { + sub_11(); + } + return false; +} +bool sub_10() { + reg_tmp10.xy = (uniforms.f[20 + address_registers.x].xwww).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_11() { + reg_tmp10.xy = (uniforms.f[20 + address_registers.x].zyyy).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_12() { + reg_tmp11 = uniforms.f[95].xxxx; + return false; +} +bool sub_13() { + conditional_code = equal(uniforms.f[95].zw, reg_tmp1.yy); + if (all(not(conditional_code))) { + sub_14(); + } else { + sub_17(); + } + reg_tmp12.x = dot_s(uniforms.f[14], reg_tmp10); + reg_tmp12.y = dot_s(uniforms.f[15], reg_tmp10); + return false; +} +bool sub_14() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp1.yy); + if (conditional_code.x) { + sub_15(); + } else { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp10.xy = (uniforms.f[21 + address_registers.x].xyyy).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_16() { + reg_tmp10.xy = (uniforms.f[21 + address_registers.x].zwww).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_17() { + if (conditional_code.x) { + sub_18(); + } else { + sub_19(); + } + return false; +} +bool sub_18() { + reg_tmp10.xy = (uniforms.f[21 + address_registers.x].xwww).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +bool sub_19() { + reg_tmp10.xy = (uniforms.f[21 + address_registers.x].zyyy).xy; + reg_tmp10.zw = (uniforms.f[95].xyyy).zw; + return false; +} +// reference: D8FAAB02074F3F8D, 3BC00FBFE97A550F +// shader: 8DD9, 5ADC687F067D9F6C + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = vtx.attributes[2].z; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 83ABF08ECCF76B42, 5ADC687F067D9F6C +// shader: 8B30, 55DC97714BEADD97 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9A6F39DCE, 55DC97714BEADD97 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 55DC97714BEADD97 +// reference: 96AE544284BA59FF, 3BC00FBFE97A550F +// shader: 8B30, 46B229D10DD751B6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((const_color[1].a) * (texcolor0.a) + (last_tex_env_out.a) * (1.0 - (texcolor0.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 64011D69B3765532, 46B229D10DD751B6 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 46B229D10DD751B6 +// shader: 8B31, EB3171E0267A0BF2 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_80(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_11(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_22(); +bool sub_32(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_44(); +bool sub_45(); +bool sub_46(); +bool sub_74(); +bool sub_75(); +bool sub_76(); +bool sub_77(); +bool sub_78(); +bool sub_79(); +bool sub_81(); +bool sub_82(); +bool sub_83(); +bool sub_84(); +bool sub_85(); +bool sub_12(); +bool sub_13(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_5(); +bool sub_6(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_14(); +bool sub_7(); +bool sub_47(); +bool sub_48(); +bool sub_49(); +bool sub_50(); +bool sub_51(); +bool sub_53(); +bool sub_62(); +bool sub_63(); +bool sub_65(); +bool sub_66(); +bool sub_72(); +bool sub_73(); +bool sub_54(); +bool sub_55(); +bool sub_56(); +bool sub_57(); +bool sub_58(); +bool sub_59(); +bool sub_60(); +bool sub_61(); +bool sub_52(); +bool sub_64(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); +bool sub_71(); +bool sub_23(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_30(); +bool sub_31(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0.xy = (uniforms.f[89].wwww).xy; + conditional_code = equal(uniforms.f[93].xy, reg_tmp0.xy); + if (conditional_code.x) { + sub_1(); + } else { + sub_80(); + } + return true; +} +bool sub_1() { + { + sub_2(); + } + return false; +} +bool sub_80() { + { + sub_81(); + } + return false; +} +bool sub_2() { + if (uniforms.b[2]) { + sub_3(); + } else { + sub_18(); + } + reg_tmp8.w = (uniforms.f[93].yyyy).w; + reg_tmp0.w = dot_3(reg_tmp11.xyz, reg_tmp11.xyz); + reg_tmp1.w = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp0.w = rsq_s(reg_tmp0.w); + reg_tmp1.w = rsq_s(reg_tmp1.w); + reg_tmp11 = mul_s(reg_tmp11, reg_tmp0.wwww); + reg_tmp12 = mul_s(reg_tmp12, reg_tmp1.wwww); + reg_tmp15.x = dot_s(uniforms.f[4], reg_tmp8); + reg_tmp15.y = dot_s(uniforms.f[5], reg_tmp8); + reg_tmp15.z = dot_s(uniforms.f[6], reg_tmp8); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp14.y = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.z = dot_3(uniforms.f[6].xyz, reg_tmp11.xyz); + vs_out_attr6 = -reg_tmp15; + if (uniforms.b[10]) { + sub_21(); + } else { + sub_35(); + } + if (uniforms.b[9]) { + sub_36(); + } else { + sub_42(); + } + if (uniforms.b[11]) { + sub_44(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp15); + vs_out_attr1 = reg_tmp10; + if (uniforms.b[1]) { + sub_45(); + } else { + sub_79(); + } + return false; +} +bool sub_3() { + reg_tmp8 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + if (uniforms.b[0]) { + sub_4(); + } else { + sub_11(); + } + return false; +} +bool sub_4() { + reg_tmp12 = uniforms.f[93].xxxx; + { + sub_5(); + } + return false; +} +bool sub_11() { + reg_tmp12 = uniforms.f[93].yxxx; + { + sub_12(); + } + return false; +} +bool sub_18() { + reg_tmp15 = mul_s(uniforms.f[90].xxxx, vs_in_reg0); + reg_tmp14 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + reg_tmp13 = mul_s(uniforms.f[90].wwww, vs_in_reg2); + reg_tmp11.x = dot_3(uniforms.f[20].xyz, reg_tmp14.xyz); + reg_tmp11.y = dot_3(uniforms.f[21].xyz, reg_tmp14.xyz); + reg_tmp11.z = dot_3(uniforms.f[22].xyz, reg_tmp14.xyz); + reg_tmp11.w = (uniforms.f[93].xxxx).w; + reg_tmp8.x = dot_s(uniforms.f[20], reg_tmp15); + reg_tmp8.y = dot_s(uniforms.f[21], reg_tmp15); + reg_tmp8.z = dot_s(uniforms.f[22], reg_tmp15); + if (uniforms.b[0]) { + sub_19(); + } else { + sub_20(); + } + return false; +} +bool sub_19() { + reg_tmp12.x = dot_3(uniforms.f[20].xyz, reg_tmp13.xyz); + reg_tmp12.y = dot_3(uniforms.f[21].xyz, reg_tmp13.xyz); + reg_tmp12.z = dot_3(uniforms.f[22].xyz, reg_tmp13.xyz); + reg_tmp12.w = (uniforms.f[93].xxxx).w; + return false; +} +bool sub_20() { + reg_tmp12 = uniforms.f[93].yxxx; + return false; +} +bool sub_21() { + if (uniforms.b[0]) { + sub_22(); + } else { + sub_32(); + } + return false; +} +bool sub_22() { + reg_tmp13.x = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp13.y = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.z = dot_3(uniforms.f[6].xyz, reg_tmp12.xyz); + { + sub_23(); + } + return false; +} +bool sub_32() { + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + vs_out_attr5.w = (uniforms.f[93].xxxx).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (!conditional_code.x) { + sub_33(); + } else { + sub_34(); + } + return false; +} +bool sub_33() { + vs_out_attr5.z = rcp_s(reg_tmp4.x); + vs_out_attr5.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_34() { + vs_out_attr5.xyz = (uniforms.f[93].yxxx).xyz; + return false; +} +bool sub_35() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_36() { + reg_tmp0 = uniforms.f[8]; + reg_tmp1 = uniforms.f[9]; + reg_tmp3.x = dot_3(uniforms.f[77].xyz, reg_tmp14.xyz); + reg_tmp3.y = dot_3(uniforms.f[80].xyz, reg_tmp14.xyz); + reg_tmp3.z = dot_3(uniforms.f[83].xyz, reg_tmp14.xyz); + reg_tmp3.w = dot_3(uniforms.f[86].xyz, reg_tmp14.xyz); + reg_tmp5 = mul_s(uniforms.f[74], reg_tmp1); + reg_tmp9 = uniforms.f[93].xxxx; + reg_tmp10 = uniforms.f[93].xxxx; + reg_tmp2 = uniforms.f[75]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp2.xy); + if (conditional_code.x) { + sub_37(); + } + if (conditional_code.y) { + sub_38(); + } + conditional_code = equal(uniforms.f[93].yy, reg_tmp2.zw); + if (conditional_code.x) { + sub_39(); + } + if (conditional_code.y) { + sub_40(); + } + reg_tmp10.xyz = (reg_tmp10.xyzz + reg_tmp9.xyzz).xyz; + reg_tmp10.xyz = (reg_tmp10.xyzz + reg_tmp5.xyzz).xyz; + if (uniforms.b[5]) { + sub_41(); + } + return false; +} +bool sub_37() { + reg_tmp4 = mul_s(uniforms.f[78], reg_tmp0); + reg_tmp3.x = (max(uniforms.f[93].xxxx, reg_tmp3.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xxxx, reg_tmp4.xyzz, reg_tmp10.xyzz)).xyz; + reg_tmp10.w = (reg_tmp10.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_38() { + reg_tmp4 = mul_s(uniforms.f[81], reg_tmp0); + reg_tmp3.y = (max(uniforms.f[93].xxxx, reg_tmp3.yyyy)).y; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[82].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.yyyy, reg_tmp4.xyzz, reg_tmp10.xyzz)).xyz; + reg_tmp10.w = (reg_tmp10.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_39() { + reg_tmp4 = mul_s(uniforms.f[84], reg_tmp0); + reg_tmp3.z = (max(uniforms.f[93].xxxx, reg_tmp3.zzzz)).z; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[85].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.zzzz, reg_tmp4.xyzz, reg_tmp10.xyzz)).xyz; + reg_tmp10.w = (reg_tmp10.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_40() { + reg_tmp4 = mul_s(uniforms.f[87], reg_tmp0); + reg_tmp3.w = (max(uniforms.f[93].xxxx, reg_tmp3.wwww)).w; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[88].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.wwww, reg_tmp4.xyzz, reg_tmp10.xyzz)).xyz; + reg_tmp10.w = (reg_tmp10.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_41() { + reg_tmp9 = mul_s(uniforms.f[90].zzzz, vs_in_reg3); + reg_tmp10 = mul_s(reg_tmp10, reg_tmp9); + return false; +} +bool sub_42() { + reg_tmp10 = uniforms.f[8]; + if (uniforms.b[5]) { + sub_43(); + } + return false; +} +bool sub_43() { + reg_tmp10 = mul_s(uniforms.f[90].zzzz, vs_in_reg3); + return false; +} +bool sub_44() { + reg_tmp10 = uniforms.f[69]; + return false; +} +bool sub_45() { + reg_tmp0.xy = (uniforms.f[92].xxxx).xy; + conditional_code = lessThanEqual(uniforms.f[93].yy, reg_tmp0.xy); + if (conditional_code.x) { + sub_46(); + } else { + sub_74(); + } + vs_out_attr2.xy = (reg_tmp3.xyyy).xy; + vs_out_attr2.z = (reg_tmp3.zzzz).z; + vs_out_attr2.w = (uniforms.f[93].yyyy).w; + reg_tmp0.xy = (uniforms.f[92].yyyy).xy; + conditional_code = lessThanEqual(uniforms.f[93].yy, reg_tmp0.xy); + if (conditional_code.x) { + sub_75(); + } else { + sub_76(); + } + vs_out_attr3.xy = (reg_tmp3.xyyy).xy; + vs_out_attr3.zw = (uniforms.f[93].yyyy).zw; + reg_tmp0.xy = (uniforms.f[92].zzzz).xy; + conditional_code = lessThanEqual(uniforms.f[93].yy, reg_tmp0.xy); + if (conditional_code.x) { + sub_77(); + } else { + sub_78(); + } + vs_out_attr4.xy = (reg_tmp3.xyyy).xy; + vs_out_attr4.zw = (uniforms.f[93].yyyy).zw; + return false; +} +bool sub_46() { + reg_tmp1.xy = (uniforms.f[89].xxxx).xy; + reg_tmp2.xy = (uniforms.f[93].xxxx).xy; + { + sub_47(); + } + return false; +} +bool sub_74() { + reg_tmp3 = uniforms.f[93].xxxx; + return false; +} +bool sub_75() { + reg_tmp1.xy = (uniforms.f[89].yyyy).xy; + reg_tmp2.xy = (uniforms.f[93].yyyy).xy; + { + sub_47(); + } + return false; +} +bool sub_76() { + reg_tmp3 = uniforms.f[93].xxxx; + return false; +} +bool sub_77() { + reg_tmp1.xy = (uniforms.f[89].zzzz).xy; + reg_tmp2.xy = (uniforms.f[93].zyyy).xy; + { + sub_47(); + } + return false; +} +bool sub_78() { + reg_tmp3 = uniforms.f[93].xxxx; + return false; +} +bool sub_79() { + reg_tmp3 = uniforms.f[93].xxxx; + vs_out_attr2.xy = (reg_tmp3.xyyy).xy; + vs_out_attr2.z = (reg_tmp3.zzzz).z; + vs_out_attr2.w = (uniforms.f[93].yyyy).w; + vs_out_attr3.xy = (reg_tmp3.xyyy).xy; + vs_out_attr3.zw = (uniforms.f[93].yyyy).zw; + vs_out_attr4.xy = (reg_tmp3.xyyy).xy; + vs_out_attr4.zw = (uniforms.f[93].yyyy).zw; + return false; +} +bool sub_81() { + reg_tmp8.x = dot_s(uniforms.f[20], vs_in_reg0); + reg_tmp8.y = dot_s(uniforms.f[21], vs_in_reg0); + reg_tmp8.z = dot_s(uniforms.f[22], vs_in_reg0); + reg_tmp8.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[4], reg_tmp8); + reg_tmp15.y = dot_s(uniforms.f[5], reg_tmp8); + reg_tmp15.z = dot_s(uniforms.f[6], reg_tmp8); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[4]) { + sub_82(); + } + reg_tmp10 = uniforms.f[8]; + if (uniforms.b[5]) { + sub_83(); + } + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp15); + vs_out_attr1 = reg_tmp10; + vs_out_attr6 = -reg_tmp15; + vs_out_attr5 = uniforms.f[93].xxxx; + if (uniforms.b[1]) { + sub_84(); + } else { + sub_85(); + } + vs_out_attr2.xy = (reg_tmp3.xyyy).xy; + vs_out_attr2.z = (reg_tmp3.zzzz).z; + vs_out_attr2.w = (uniforms.f[93].xxxx).w; + vs_out_attr3.xy = (reg_tmp4.xyyy).xy; + vs_out_attr3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4.xy = (reg_tmp5.xyyy).xy; + vs_out_attr4.zw = (uniforms.f[93].xxxx).zw; + return false; +} +bool sub_82() { + reg_tmp0.z = (reg_tmp15.zzzz).z; + reg_tmp0.z = (abs(reg_tmp0.zzzz)).z; + reg_tmp0.x = (uniforms.f[23].xxxx).x; + reg_tmp0.y = (-uniforms.f[23].yyyy + reg_tmp0.zzzz).y; + reg_tmp0.z = rcp_s(reg_tmp0.z); + reg_tmp0.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.zzzz)).z; + reg_tmp15.x = (fma_s(reg_tmp0.xxxx, reg_tmp0.zzzz, reg_tmp15.xxxx)).x; + return false; +} +bool sub_83() { + reg_tmp9 = mul_s(uniforms.f[90].zzzz, vs_in_reg3); + reg_tmp10 = mul_s(reg_tmp10, reg_tmp9); + return false; +} +bool sub_84() { + reg_tmp1.xy = (uniforms.f[89].xxxx).xy; + { + sub_54(); + } + reg_tmp3.x = dot_s(uniforms.f[10], reg_tmp10); + reg_tmp3.y = dot_s(uniforms.f[11], reg_tmp10); + reg_tmp3.z = (uniforms.f[93].xxxx).z; + reg_tmp1.xy = (uniforms.f[89].yyyy).xy; + { + sub_54(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp10); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp10); + reg_tmp1.xy = (uniforms.f[89].zzzz).xy; + { + sub_54(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp10); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp10); + return false; +} +bool sub_85() { + reg_tmp3 = uniforms.f[93].xxxx; + reg_tmp4 = uniforms.f[93].xxxx; + reg_tmp5 = uniforms.f[93].xxxx; + return false; +} +bool sub_12() { + reg_tmp15 = mul_s(uniforms.f[90].xxxx, vs_in_reg0); + reg_tmp14 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + if (uniforms.b[3]) { + sub_13(); + } else { + sub_17(); + } + return false; +} +bool sub_13() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.xxxx)).w; + { + sub_14(); + } + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.yyyy)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.yyyy)).w; + { + sub_14(); + } + reg_tmp0.xy = (uniforms.f[91].wwww).xy; + conditional_code = lessThanEqual(uniforms.f[95].xy, reg_tmp0.xy); + if (conditional_code.x) { + sub_15(); + } + if (conditional_code.y) { + sub_16(); + } + return false; +} +bool sub_15() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.zzzz)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.zzzz)).w; + { + sub_14(); + } + return false; +} +bool sub_16() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.wwww)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.wwww)).w; + { + sub_14(); + } + return false; +} +bool sub_17() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).xy; + reg_tmp1.w = (uniforms.f[93].yyyy).w; + { + sub_14(); + } + return false; +} +bool sub_5() { + reg_tmp15 = mul_s(uniforms.f[90].xxxx, vs_in_reg0); + reg_tmp14 = mul_s(uniforms.f[90].yyyy, vs_in_reg1); + reg_tmp13 = mul_s(uniforms.f[90].wwww, vs_in_reg2); + if (uniforms.b[3]) { + sub_6(); + } else { + sub_10(); + } + return false; +} +bool sub_6() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.xxxx)).w; + { + sub_7(); + } + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.yyyy)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.yyyy)).w; + { + sub_7(); + } + reg_tmp0.xy = (uniforms.f[91].wwww).xy; + conditional_code = lessThanEqual(uniforms.f[95].xy, reg_tmp0.xy); + if (conditional_code.x) { + sub_8(); + } + if (conditional_code.y) { + sub_9(); + } + return false; +} +bool sub_8() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.zzzz)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.zzzz)).w; + { + sub_7(); + } + return false; +} +bool sub_9() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.wwww)).xy; + reg_tmp1.w = (mul_s(uniforms.f[94].wwww, vs_in_reg8.wwww)).w; + { + sub_7(); + } + return false; +} +bool sub_10() { + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, vs_in_reg7.xxxx)).xy; + reg_tmp1.w = (uniforms.f[93].yyyy).w; + { + sub_7(); + } + return false; +} +bool sub_14() { + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp3.w = (uniforms.f[93].yyyy).w; + reg_tmp3.x = dot_s(uniforms.f[20 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[21 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[22 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[20 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[21 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[22 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.w = (uniforms.f[93].xxxx).w; + reg_tmp8 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp8); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp11); + return false; +} +bool sub_7() { + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp3.x = dot_s(uniforms.f[20 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[21 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[22 + address_registers.x], reg_tmp15); + reg_tmp3.w = (uniforms.f[93].yyyy).w; + reg_tmp4.x = dot_3(uniforms.f[20 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[21 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[22 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.w = (uniforms.f[93].xxxx).w; + reg_tmp5.x = dot_3(uniforms.f[20 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[21 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[22 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp5.w = (uniforms.f[93].xxxx).w; + reg_tmp8 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp8); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp11); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp12); + return false; +} +bool sub_47() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp2.x = (fma_s(reg_tmp2.xxxx, uniforms.f[93].wwww, reg_tmp2.yyyy)).x; + address_registers.x = (ivec2(reg_tmp2.xx)).x; + if (all(not(conditional_code))) { + sub_48(); + } else { + sub_62(); + } + return false; +} +bool sub_48() { + conditional_code = equal(uniforms.f[93].zy, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_49(); + } else { + sub_50(); + } + return false; +} +bool sub_49() { + reg_tmp10.x = dot_s(uniforms.f[70], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[71], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[72], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp3.x = dot_s(uniforms.f[10 + address_registers.x], reg_tmp10); + reg_tmp3.y = dot_s(uniforms.f[11 + address_registers.x], reg_tmp10); + reg_tmp3.z = dot_s(uniforms.f[12 + address_registers.x], reg_tmp10); + reg_tmp3.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_50() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_51(); + } else { + sub_53(); + } + return false; +} +bool sub_51() { + { + sub_52(); + } + reg_tmp3.x = dot_3(uniforms.f[70].xyz, reg_tmp10.xyz); + reg_tmp3.y = dot_3(uniforms.f[71].xyz, reg_tmp10.xyz); + reg_tmp3.z = dot_3(uniforms.f[72].xyz, reg_tmp10.xyz); + reg_tmp3.w = (uniforms.f[93].xxxx).w; + return false; +} +bool sub_53() { + { + sub_54(); + } + reg_tmp3.x = dot_s(uniforms.f[10 + address_registers.x], reg_tmp10); + reg_tmp3.y = dot_s(uniforms.f[11 + address_registers.x], reg_tmp10); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + return false; +} +bool sub_62() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_63(); + } else { + sub_65(); + } + return false; +} +bool sub_63() { + { + sub_64(); + } + reg_tmp3.x = dot_s(uniforms.f[10 + address_registers.x], reg_tmp10); + reg_tmp3.y = dot_s(uniforms.f[11 + address_registers.x], reg_tmp10); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + return false; +} +bool sub_65() { + reg_tmp10.x = dot_3(uniforms.f[70].xyz, reg_tmp14.xyz); + reg_tmp10.y = dot_3(uniforms.f[71].xyz, reg_tmp14.xyz); + reg_tmp10.z = dot_3(uniforms.f[72].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[12 + address_registers.x].xyz, reg_tmp10.xyz); + reg_tmp10.x = dot_s(uniforms.f[70], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[71], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[72], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp3.x = dot_s(uniforms.f[10 + address_registers.x], reg_tmp10); + reg_tmp3.y = dot_s(uniforms.f[11 + address_registers.x], reg_tmp10); + reg_tmp3.z = dot_s(uniforms.f[12 + address_registers.x], reg_tmp10); + conditional_code.x = uniforms.f[93].xyyy.x >= reg_tmp4.zzzz.x; + conditional_code.y = uniforms.f[93].xyyy.y < reg_tmp4.zzzz.y; + if (conditional_code.x) { + sub_66(); + } else { + sub_72(); + } + reg_tmp3.xy = (uniforms.f[94].zzzz + reg_tmp3.xyyy).xy; + return false; +} +bool sub_66() { + { + sub_67(); + } + return false; +} +bool sub_72() { + if (conditional_code.y) { + sub_73(); + } + return false; +} +bool sub_73() { + { + sub_67(); + } + return false; +} +bool sub_54() { + conditional_code = equal(uniforms.f[93].xy, reg_tmp1.xy); + reg_tmp10 = reg_tmp15; + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_55(); + } else { + sub_57(); + } + return false; +} +bool sub_55() { + if (uniforms.b[6]) { + sub_56(); + } + return false; +} +bool sub_56() { + reg_tmp10.xy = (mul_s(uniforms.f[91].xxxx, vs_in_reg4.xyyy)).xy; + reg_tmp10.zw = (uniforms.f[93].xyyy).zw; + return false; +} +bool sub_57() { + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_58(); + } else { + sub_60(); + } + return false; +} +bool sub_58() { + if (uniforms.b[7]) { + sub_59(); + } + return false; +} +bool sub_59() { + reg_tmp10.xy = (mul_s(uniforms.f[91].yyyy, vs_in_reg5)).xy; + reg_tmp10.zw = (uniforms.f[93].xyyy).zw; + return false; +} +bool sub_60() { + if (uniforms.b[8]) { + sub_61(); + } + return false; +} +bool sub_61() { + reg_tmp10.xy = (mul_s(uniforms.f[91].zzzz, vs_in_reg6)).xy; + reg_tmp10.zw = (uniforms.f[93].xyyy).zw; + return false; +} +bool sub_52() { + reg_tmp0 = -reg_tmp15; + reg_tmp0.w = dot_3(reg_tmp0.xyz, reg_tmp0.xyz); + reg_tmp0.w = rsq_s(reg_tmp0.w); + reg_tmp0 = mul_s(reg_tmp0, reg_tmp0.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp0.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp10 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp0); + return false; +} +bool sub_64() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp10 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp10.zw = (uniforms.f[93].yyyy).zw; + return false; +} +bool sub_67() { + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp3.xy); + if (conditional_code.x) { + sub_68(); + } else { + sub_69(); + } + if (conditional_code.y) { + sub_70(); + } else { + sub_71(); + } + return false; +} +bool sub_68() { + reg_tmp3.x = (-uniforms.f[95].wwww + reg_tmp3.xxxx).x; + return false; +} +bool sub_69() { + reg_tmp3.x = (uniforms.f[95].wwww + reg_tmp3.xxxx).x; + return false; +} +bool sub_70() { + reg_tmp3.y = (-uniforms.f[95].wwww + reg_tmp3.yyyy).y; + return false; +} +bool sub_71() { + reg_tmp3.y = (uniforms.f[95].wwww + reg_tmp3.yyyy).y; + return false; +} +bool sub_23() { + uint jmp_to = 417u; + while (true) { + switch (jmp_to) { + case 417u: { + reg_tmp10 = uniforms.f[93].yxxx; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6.wwww).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6.wwww).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 443u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6.wwww).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp10 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 481u; break; } + } + } + case 443u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_24(); + } else { + sub_29(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp10 = mul_s(reg_tmp8, reg_tmp6); + } + case 481u: { + vs_out_attr5 = reg_tmp10; + } + default: return false; + } + } + return false; +} +bool sub_24() { + if (conditional_code.y) { + sub_25(); + } else { + sub_26(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_25() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_26() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_27(); + } else { + sub_28(); + } + return false; +} +bool sub_27() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_28() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_29() { + if (conditional_code.y) { + sub_30(); + } else { + sub_31(); + } + return false; +} +bool sub_30() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_31() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +// reference: F36ACDA701060AE0, EB3171E0267A0BF2 +// shader: 8DD9, 2E167B5E5D58FF27 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[5].x, vtx.attributes[5].y, vtx.attributes[5].z, vtx.attributes[5].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = vtx.attributes[2].z; + view = vec3(vtx.attributes[6].x, vtx.attributes[6].y, vtx.attributes[6].z); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: C9E56D0A62F3408C, 2E167B5E5D58FF27 +// shader: 8B30, 123AEB0EDF90A3FE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CE312E68704D9AD0, 123AEB0EDF90A3FE +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 123AEB0EDF90A3FE +// reference: BD3E32E782F36C92, EB3171E0267A0BF2 +// shader: 8B31, 361AE2AA8DF99CD7 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_15(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_15() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_7(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_8(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_9(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_7() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_8() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_9() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp2 = reg_tmp10.xzyw; + reg_tmp2.z = (-reg_tmp2.zzzz).z; + reg_tmp14 = reg_tmp2; + reg_tmp0 = uniforms.f[7 + address_registers.x]; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp14, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp14, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp14, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp14, reg_tmp9); + reg_tmp6 = uniforms.f[8 + address_registers.x]; + reg_tmp7 = uniforms.f[9 + address_registers.x]; + reg_tmp8 = uniforms.f[10 + address_registers.x]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5 + address_registers.x].xxxx).w; + reg_tmp7.w = (uniforms.f[5 + address_registers.x].yyyy).w; + reg_tmp8.w = (uniforms.f[5 + address_registers.x].zzzz).w; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_15(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 017B59A19277E5B5, 361AE2AA8DF99CD7 +// shader: 8DD9, 13A54CCD8AA1DDA2 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: A55C6948CCF76B42, 13A54CCD8AA1DDA2 +// shader: 8B30, 2F65C93961D66538 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6FE6392B01C1F016, 2F65C93961D66538 +// program: 361AE2AA8DF99CD7, 13A54CCD8AA1DDA2, 2F65C93961D66538 +// reference: 4F2FA6E1118283C7, 361AE2AA8DF99CD7 +// shader: 8B30, C177EDF23A5BAC37 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10807477E48A212B, C177EDF23A5BAC37 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, C177EDF23A5BAC37 +// shader: 8B30, ADD332F8F6E95DAC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) - (const_color[0].ggg), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) - (const_color[0].g), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.aaa) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (texcolor0.a); +last_tex_env_out = vec4(color_output_2 * 1.0, alpha_output_2 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((combiner_buffer.aaa) * (rounded_primary_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((combiner_buffer.a) * (rounded_primary_color.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = (last_tex_env_out.rgb); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 422C06C5DD3815A7, ADD332F8F6E95DAC +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, ADD332F8F6E95DAC +// shader: 8B30, 221B7736F307CBFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3092B42CF5314446, 221B7736F307CBFA +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 221B7736F307CBFA +// shader: 8B30, 254B3122F307CBFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B9748374F5314446, 254B3122F307CBFA +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 254B3122F307CBFA +// shader: 8B30, 97E4DFCDD5BFE5F2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb) + (texcolor1.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B483BEB2F5314446, 97E4DFCDD5BFE5F2 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 97E4DFCDD5BFE5F2 +// shader: 8B30, 6CD6115DF307CBFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4419EA1EF5314446, 6CD6115DF307CBFA +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 6CD6115DF307CBFA +// shader: 8B30, 6B865749F307CBFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) - (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CDFFDD46F5314446, 6B865749F307CBFA +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 6B865749F307CBFA +// shader: 8B30, F469630EF307CBFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (vec3(1.0) - texcolor1.aaa); +float alpha_output_0 = (texcolor1.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) + (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor0.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (combiner_buffer.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (combiner_buffer.a) + (last_tex_env_out.a) * (1.0 - (combiner_buffer.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (last_tex_env_out.rgb); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FA4D4F99F5314446, F469630EF307CBFA +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, F469630EF307CBFA +// shader: 8B30, E348EA9115EA17F1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rrr); +float alpha_output_0 = byteround(clamp((texcolor0.a) - (const_color[0].g), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 2.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0605656193D6D855, E348EA9115EA17F1 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, E348EA9115EA17F1 +// shader: 8B30, 46901A0E651BA613 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((const_color[1].a) * (texcolor0.a) + (last_tex_env_out.a) * (1.0 - (texcolor0.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (last_tex_env_out.rgb); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 64011D695FC1BE31, 46901A0E651BA613 +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, 46901A0E651BA613 +// shader: 8B30, EC3D5957A2FDEACE +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4609680C5AF1DC81, EC3D5957A2FDEACE +// program: 3BC00FBFE97A550F, 5ADC687F067D9F6C, EC3D5957A2FDEACE +// shader: 8B30, 357EA601E8E997F2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 10807477ACF75484, 357EA601E8E997F2 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 357EA601E8E997F2 +// shader: 8B30, A0B12CB65500D5A5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.r) - (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (last_tex_env_out.rgb); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 73A446E3057FF10D, A0B12CB65500D5A5 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, A0B12CB65500D5A5 +// shader: 8B30, A5C9901F3BBDC30D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B6933CA039D0AC24, A5C9901F3BBDC30D +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, A5C9901F3BBDC30D +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, EC3D5957A2FDEACE +// shader: 8B30, F3CFFB30868A7F93 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0C4C520BB9FC48D5, F3CFFB30868A7F93 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, F3CFFB30868A7F93 +// shader: 8B30, EF095C18D763D5B1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) * (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb) + (texcolor1.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0CAEB39C26D47AA5, EF095C18D763D5B1 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, EF095C18D763D5B1 +// shader: 8B30, 711031A52A03FAD2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTSigned(1, dot(normal, normalize(half_vector)))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTSigned(1, dot(normal, normalize(half_vector)))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.aaa) + (texcolor1.rgb) * (vec3(1.0) - (rounded_primary_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a) + (texcolor1.a) * (1.0 - (rounded_primary_color.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor2.r) * (const_color[1].a) + (texcolor2.g) * (1.0 - (const_color[1].a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((combiner_buffer.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 1.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((combiner_buffer.rgb) * (rounded_primary_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4 * 2.0, alpha_output_4 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 750FC752B1A1893D, 711031A52A03FAD2 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 711031A52A03FAD2 +// shader: 8B30, 3AF34A3FDF3ED4D5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (texcolor2.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor1.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((rounded_primary_color.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texture(tex_cube, vec3(texcoord0, texcoord0_w)).rgb) * (combiner_buffer.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EB3550264D4C9D67, 3AF34A3FDF3ED4D5 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 3AF34A3FDF3ED4D5 +// shader: 8B30, 504F6215D0E3343C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5FD44E099A07ED5D, 504F6215D0E3343C +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 504F6215D0E3343C +// shader: 8B30, 544C0C790D32FB41 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb) + (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp(vec3(dot((last_tex_env_out.rgb) - vec3(0.5), (const_color[1].rgb) - vec3(0.5)) * 4.0), vec3(0.0), vec3(1.0))); +float alpha_output_1 = color_output_1[0]; +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9980AEFA7D521E01, 544C0C790D32FB41 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 544C0C790D32FB41 +// shader: 8B30, 30B703594147E54C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9E2FC3054, 30B703594147E54C +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 30B703594147E54C +// shader: 8B30, 30859842737CCC91 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor2.rgb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2FF85E5A54666AA6, 30859842737CCC91 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 30859842737CCC91 +// shader: 8B30, 33BEF95CA070E282 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (const_color[1].aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 96387671B4F54A56, 33BEF95CA070E282 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 33BEF95CA070E282 +// shader: 8B30, D096324DA1E1E3EB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 2.0, alpha_output_1 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 135B07CE8B8AF4C4, D096324DA1E1E3EB +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, D096324DA1E1E3EB +// shader: 8B30, 369B1AF9265D7F5C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.aaa) * (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (last_tex_env_out.rgb) + (texcolor1.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 2.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 13B9E65914A2C6B4, 369B1AF9265D7F5C +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 369B1AF9265D7F5C +// shader: 8B30, 9DAE9985D17E3B0B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTSigned(1, dot(normal, normalize(half_vector)))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTSigned(1, dot(normal, normalize(half_vector)))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + ((lut_scale_d1 * LookupLightingLUTSigned(1, dot(normal, normalize(half_vector)))) * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.aaa) + (texcolor1.rgb) * (vec3(1.0) - (rounded_primary_color.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a) + (texcolor1.a) * (1.0 - (rounded_primary_color.a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((texcolor2.r) * (const_color[1].a) + (texcolor2.g) * (1.0 - (const_color[1].a)), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((combiner_buffer.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 1.0, alpha_output_2 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3 * 4.0, alpha_output_3 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((combiner_buffer.rgb) * (rounded_primary_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (const_color[4].a); +last_tex_env_out = vec4(color_output_4 * 2.0, alpha_output_4 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6A18929783D7352C, 9DAE9985D17E3B0B +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 9DAE9985D17E3B0B +// shader: 8B30, 7974F3663498993D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF94A4476CD, 7974F3663498993D +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 7974F3663498993D +// shader: 8B30, 028490EB6CE605C1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[2].specular_0) + (light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor1.rgb) * (texcolor2.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor1.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 1.0, alpha_output_0 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((rounded_primary_color.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2 * 2.0, alpha_output_2 * 1.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (primary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texture(tex_cube, vec3(texcoord0, texcoord0_w)).rgb) * (combiner_buffer.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F42205E37F3A2176, 028490EB6CE605C1 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 028490EB6CE605C1 +// shader: 8B30, B5AF184B790AD578 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 40C31BCCA871514C, B5AF184B790AD578 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, B5AF184B790AD578 +// shader: 8B31, 856D50001A60785F + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_16(); +bool sub_2(); +bool sub_3(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_0(); +bool sub_4(); +bool sub_5(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_16() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_3() { + reg_tmp6.x = (uniforms.f[90].xxxx).x; + reg_tmp6.y = (uniforms.f[91].xxxx).y; + reg_tmp6.z = (uniforms.f[92].xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (uniforms.f[90].yyyy).x; + reg_tmp7.y = (uniforms.f[91].yyyy).y; + reg_tmp7.z = (uniforms.f[92].yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (uniforms.f[90].zzzz).x; + reg_tmp8.y = (uniforms.f[91].zzzz).y; + reg_tmp8.z = (uniforms.f[92].zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_6() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_7() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_8(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_9(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_15(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_8() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_9() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_10() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_13() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_14() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_15() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp0 = uniforms.f[7 + address_registers.x]; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp10 = reg_tmp2; + { + sub_3(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_6(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_7(); + } + { + sub_16(); + } + return true; +} +bool sub_4() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_5() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 15D7A4B58DAE907F, 856D50001A60785F +// shader: 8B30, 57EE39CC711116A3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) - (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CC8B58D778A87963, 57EE39CC711116A3 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 57EE39CC711116A3 +// shader: 8B31, 840CDA2008BFF630 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_18(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_0(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_18() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_8() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_9() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_15(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_16(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_17(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_10() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_12() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_13() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_15() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_16() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_17() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp2.x = (uniforms.f[8 + address_registers.x].yyyy).x; + reg_tmp2.y = (uniforms.f[9 + address_registers.x].yyyy).y; + reg_tmp2.z = (uniforms.f[10 + address_registers.x].yyyy).z; + reg_tmp3.xyz = (uniforms.f[6 + address_registers.x].xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp4.xyz = (mul_s(reg_tmp2.yzxx, reg_tmp3.zxyy)).xyz; + reg_tmp4.xyz = (fma_s(-reg_tmp3.yzxx, reg_tmp2.zxyy, reg_tmp4)).xyz; + reg_tmp5.x = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp5.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp5.y; + if (conditional_code.x) { + sub_4(); + } else { + sub_5(); + } + reg_tmp4.xyz = (mul_s(reg_tmp4.xyzz, reg_tmp5.xxxx)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp4.yzxx, reg_tmp3.zxyy)).xyz; + reg_tmp5.xyz = (fma_s(-reg_tmp3.yzxx, reg_tmp4.zxyy, reg_tmp5)).xyz; + reg_tmp6.x = (reg_tmp4.xxxx).x; + reg_tmp6.y = (reg_tmp3.xxxx).y; + reg_tmp6.z = (reg_tmp5.xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (reg_tmp4.yyyy).x; + reg_tmp7.y = (reg_tmp3.yyyy).y; + reg_tmp7.z = (reg_tmp5.yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (reg_tmp4.zzzz).x; + reg_tmp8.y = (reg_tmp3.zzzz).y; + reg_tmp8.z = (reg_tmp5.zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_6(); + } else { + sub_7(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_8(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_9(); + } + { + sub_18(); + } + return true; +} +bool sub_2() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_3() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +bool sub_4() { + reg_tmp5.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_5() { + reg_tmp5.x = rsq_s(reg_tmp5.x); + return false; +} +bool sub_6() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_7() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: E006E3BA331ABEC1, 840CDA2008BFF630 +// shader: 8B30, 4A9F2E3E6D6A3441 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FCB73F768595A0EE, 4A9F2E3E6D6A3441 +// program: 840CDA2008BFF630, 13A54CCD8AA1DDA2, 4A9F2E3E6D6A3441 +// shader: 8B31, 1B4F5D8F85FA1A43 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_15(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_15() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.x = (uniforms.f[90].xxxx).x; + reg_tmp6.y = (uniforms.f[91].xxxx).y; + reg_tmp6.z = (uniforms.f[92].xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (uniforms.f[90].yyyy).x; + reg_tmp7.y = (uniforms.f[91].yyyy).y; + reg_tmp7.z = (uniforms.f[92].yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (uniforms.f[90].zzzz).x; + reg_tmp8.y = (uniforms.f[91].zzzz).y; + reg_tmp8.z = (uniforms.f[92].zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9.x = (uniforms.f[90].wwww).x; + reg_tmp9.y = (uniforms.f[91].wwww).y; + reg_tmp9.z = (uniforms.f[92].wwww).z; + reg_tmp9.w = (uniforms.f[0].zzzz).w; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_7(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_8(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_9(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_7() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_8() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_9() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(uniforms.f[0].xxxz, reg_tmp10); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_15(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 6590628E3F775D7A, 1B4F5D8F85FA1A43 +// shader: 8B30, 1979BEC8711116A3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FC5627BE78A87963, 1979BEC8711116A3 +// program: 1B4F5D8F85FA1A43, 13A54CCD8AA1DDA2, 1979BEC8711116A3 +// shader: 8B30, FFA7CA48AC3C668B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].aaa) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 915EDB35C2827ED1, FFA7CA48AC3C668B +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, FFA7CA48AC3C668B +// shader: 8B30, C851EB99C624376F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.aaa) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A6FBA20FF51DBB86, C851EB99C624376F +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, C851EB99C624376F +// shader: 8B30, 3CC74C9C5BA0A910 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].aaa) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 552A11BBC2827ED1, 3CC74C9C5BA0A910 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 3CC74C9C5BA0A910 +// shader: 8B30, 536E8CE403B367B6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.aaa) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.aaa) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DE34E2006137F32E, 536E8CE403B367B6 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 536E8CE403B367B6 +// shader: 8B30, D478BA76BDBC21B9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].aaa) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DB68A085DEA5E6C4, D478BA76BDBC21B9 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, D478BA76BDBC21B9 +// shader: 8B30, 864573EFDDD5209B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].aaa) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DB68A08550E757FA, 864573EFDDD5209B +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 864573EFDDD5209B +// shader: 8B30, 42486DBC4DBEAD93 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) * (const_color[1].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (last_tex_env_out.rgb); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A97C91909B284222, 42486DBC4DBEAD93 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 42486DBC4DBEAD93 +// reference: B2FAB1CCC2AF098C, 57EE39CC711116A3 +// reference: 82C6D66D3F92D001, 4A9F2E3E6D6A3441 +// reference: 8227CEA5C2AF098C, 1979BEC8711116A3 +// shader: 8B30, 99C29D57FC04E12D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].aaa) + (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BD566DC1A0D5F439, 99C29D57FC04E12D +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 99C29D57FC04E12D +// shader: 8B30, 52B1226476A31AB4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D04F420450B69E3A, 52B1226476A31AB4 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 52B1226476A31AB4 +// shader: 8B30, 8F647C8B5D568A73 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor0).rgb - 1.0; +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(view)), 0.0))) * light_src[2].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor1.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E994AFFB437194B1, 8F647C8B5D568A73 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 8F647C8B5D568A73 +// shader: 8B30, 1358176FA7DE9D9C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.bbb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (const_color[2].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (const_color[2].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A8646711766AF783, 1358176FA7DE9D9C +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 1358176FA7DE9D9C +// shader: 8B30, 8A8595C5A3F74395 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + (light_src[1].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[2].position + view); +spot_dir = light_src[2].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[2].diffuse * dot_product) + light_src[2].ambient) * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +specular_sum.rgb += ((light_src[2].specular_0) + (light_src[2].specular_1)) * clamp_highlights * LookupLightingLUTUnsigned(18, clamp(light_src[2].dist_atten_scale * length(-view - light_src[2].position) + light_src[2].dist_atten_bias, 0.0, 1.0)) * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((primary_fragment_color.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 74340DFD29AA2441, 8A8595C5A3F74395 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 8A8595C5A3F74395 +// shader: 8B30, B6CFF685DA511B6B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += ((light_src[0].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[0].specular_1)) * clamp_highlights * 1.0; +light_vector = normalize(light_src[1].position); +spot_dir = light_src[1].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[1].diffuse * dot_product) + light_src[1].ambient) * 1.0; +specular_sum.rgb += ((light_src[1].specular_0) + ((lut_scale_d1 * LookupLightingLUTUnsigned(1, max(dot(normal, normalize(view)), 0.0))) * light_src[1].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.ggg), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) * (secondary_fragment_color.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (const_color[3].rrr), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +float fog_index = depth * 128.0; +int fog_i = int(fog_index); +float fog_f = fract(fog_index); +vec2 fog_lut_entry = texelFetch(texture_buffer_lut_lf, fog_i + fog_lut_offset).rg; +float fog_factor = fog_lut_entry.r + fog_lut_entry.g * fog_f; +fog_factor = clamp(fog_factor, 0.0, 1.0); +last_tex_env_out.rgb = mix(fog_color.rgb, last_tex_env_out.rgb, fog_factor); +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 57280AF8DD457C48, B6CFF685DA511B6B +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, B6CFF685DA511B6B +// reference: 5B835BF50E5BF60D, 856D50001A60785F +// shader: 8B30, BD099273E0557909 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) - (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B2FAB1CC394F7835, BD099273E0557909 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, BD099273E0557909 +// shader: 8B30, 4C0BB907EE40D414 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) + (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FEAB806CE655739A, 4C0BB907EE40D414 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 4C0BB907EE40D414 +// shader: 8B30, 69603AA5B061A024 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 70D611D1F49F9C0B, 69603AA5B061A024 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 69603AA5B061A024 +// reference: 2BC49DCEBC823B08, 1B4F5D8F85FA1A43 +// reference: 6426D3128B3DF3B8, 1979BEC8711116A3 +// reference: 54FBAC7B70DD8201, BD099273E0557909 +// reference: 18AA9DDBAFC789AE, 4C0BB907EE40D414 +// reference: 96D70C66BD0D663F, 69603AA5B061A024 +// shader: 8B30, 2B10BB0377D1741F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 96D70C66FA3C45C2, 2B10BB0377D1741F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 2B10BB0377D1741F +// shader: 8B30, F2B0D3B757EF8F8A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 64C7CBDA8DE05B8C, F2B0D3B757EF8F8A +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, F2B0D3B757EF8F8A +// shader: 8B31, C270E8617D51E2E6 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_2(); +bool sub_5(); +bool sub_1(); +bool sub_7(); +bool sub_6(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_2() { + reg_tmp1.xyz = (uniforms.f[92].xyzz).xyz; + reg_tmp1.w = (uniforms.f[0].xxxx).w; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.xx)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xyz = (uniforms.f[1 + address_registers.x].xyzz).xyz; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp11.xy = (uniforms.f[4 + address_registers.x].xyyy).xy; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp12.xy = (uniforms.f[4 + address_registers.x].xyyy).xy; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp2 = uniforms.f[0].xxxx; + reg_tmp3 = uniforms.f[0].xxxx; + reg_tmp4 = uniforms.f[0].xxxx; + return false; +} +bool sub_7() { + vs_out_attr0 = reg_tmp10; + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[75].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[75].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[75].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[75].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[75].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_6() { + reg_tmp14.z = (uniforms.f[78].zzzz).z; + reg_tmp14.w = (uniforms.f[79].zzzz).w; + reg_tmp2.x = rcp_s(uniforms.f[75].y); + reg_tmp2.xy = (mul_s(reg_tmp14.zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[75].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (reg_tmp14.zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[75].xxxx, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[75].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp4 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp4.xyyy, reg_tmp4.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp4 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp4.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp4.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp4 = uniforms.f[4 + address_registers.x].xxyy; + reg_tmp4 = -uniforms.f[0].yyyy + reg_tmp4; + reg_tmp4 = mul_s(reg_tmp4, reg_tmp1.xyyx); + reg_tmp11.xy = (reg_tmp4.xyyy + reg_tmp4.zwww).xy; + reg_tmp5.xy = (uniforms.f[78].xyyy).xy; + reg_tmp11.xy = (fma_s(reg_tmp11.xyyy, reg_tmp5.xyyy, uniforms.f[77].xyyy)).xy; + reg_tmp11.xy = (uniforms.f[0].yyyy + reg_tmp11.xyyy).xy; + reg_tmp4 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp4.xyyy, reg_tmp4.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp4 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp4.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp4.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp4 = uniforms.f[4 + address_registers.x].zzww; + reg_tmp4 = -uniforms.f[0].yyyy + reg_tmp4; + reg_tmp4 = mul_s(reg_tmp4, reg_tmp1.xyyx); + reg_tmp12.xy = (reg_tmp4.xyyy + reg_tmp4.zwww).xy; + reg_tmp5.xy = (uniforms.f[79].xyyy).xy; + reg_tmp12.xy = (fma_s(reg_tmp12.xyyy, reg_tmp5.xyyy, uniforms.f[77].zwww)).xy; + reg_tmp12.xy = (uniforms.f[0].yyyy + reg_tmp12.xyyy).xy; + return false; +} +bool sub_0() { + { + sub_1(); + } + { + sub_2(); + } + reg_tmp2 = reg_tmp1; + reg_tmp3.xyz = (mul_s(-uniforms.f[2 + address_registers.x].yzxx, reg_tmp2.zxyy)).xyz; + reg_tmp3.xyz = (fma_s(reg_tmp2.yzxx, uniforms.f[2 + address_registers.x].zxyy, reg_tmp3)).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + reg_tmp4.x = rsq_s(reg_tmp4.x); + reg_tmp4.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp4.xyz = (mul_s(uniforms.f[3 + address_registers.x].wwww, reg_tmp4.xyzz)).xyz; + reg_tmp4.xyz = (mul_s(uniforms.f[0].yyyy, reg_tmp4.xyzz)).xyz; + reg_tmp10.xyz = (reg_tmp10.xyzz + -reg_tmp4.xyzz).xyz; + { + sub_2(); + } + reg_tmp3 = reg_tmp1; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[76].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[80]; + reg_tmp2.w = (mul_s(uniforms.f[1 + address_registers.x].wwww, reg_tmp2.wwww)).w; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_7(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 7617F0C9BD2374F9, C270E8617D51E2E6 +// shader: 8B30, B6B08DE0C83FF4C8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 963614AE7623ED04, B6B08DE0C83FF4C8 +// program: C270E8617D51E2E6, 13A54CCD8AA1DDA2, B6B08DE0C83FF4C8 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 1979BEC8711116A3 +// shader: 8B31, 7D68CBC79559621F + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_15(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp11.xy = (vs_in_reg1.xyyy).xy; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_15() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = mul_s(vs_in_reg2, reg_tmp13); + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5].wwww).x; + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_7(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_8(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_9(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + reg_tmp3 = reg_tmp14.xyxy; + reg_tmp3.y = (uniforms.f[0].zzzz + -reg_tmp3.yyyy).y; + reg_tmp3.w = (uniforms.f[0].zzzz + -reg_tmp3.wwww).w; + reg_tmp2 = mul_s(uniforms.f[83].xxyy, reg_tmp3); + reg_tmp2 = -uniforms.f[0].yyyy + reg_tmp2; + reg_tmp2 = mul_s(reg_tmp2, reg_tmp1.xyyx); + reg_tmp2.x = (reg_tmp2.xxxx + -reg_tmp2.yyyy).x; + reg_tmp2.y = (reg_tmp2.zzzz + reg_tmp2.wwww).y; + reg_tmp4.xy = (uniforms.f[3].xyyy).xy; + reg_tmp3.xy = (fma_s(reg_tmp2.xyyy, uniforms.f[3].zwww, reg_tmp4.xyyy)).xy; + reg_tmp3.xy = (uniforms.f[0].yyyy + reg_tmp3.xyyy).xy; + reg_tmp11.xy = (reg_tmp3.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6].wwww).x; + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + reg_tmp3 = reg_tmp14.xyxy; + reg_tmp3.y = (uniforms.f[0].zzzz + -reg_tmp3.yyyy).y; + reg_tmp3.w = (uniforms.f[0].zzzz + -reg_tmp3.wwww).w; + reg_tmp2 = mul_s(uniforms.f[83].zzww, reg_tmp3); + reg_tmp2 = -uniforms.f[0].yyyy + reg_tmp2; + reg_tmp2 = mul_s(reg_tmp2, reg_tmp1.xyyx); + reg_tmp2.x = (reg_tmp2.xxxx + -reg_tmp2.yyyy).x; + reg_tmp2.y = (reg_tmp2.zzzz + reg_tmp2.wwww).y; + reg_tmp4.xy = (uniforms.f[4].xyyy).xy; + reg_tmp3.xy = (fma_s(reg_tmp2.xyyy, uniforms.f[4].zwww, reg_tmp4.xyyy)).xy; + reg_tmp3.xy = (uniforms.f[0].yyyy + reg_tmp3.xyyy).xy; + reg_tmp12.xy = (reg_tmp3.xyyy).xy; + return false; +} +bool sub_7() { + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + return false; +} +bool sub_8() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + return false; +} +bool sub_9() { + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + return false; +} +bool sub_12() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xyz = (mul_s(uniforms.f[2].xyxx, reg_tmp10.xyzz)).xyz; + reg_tmp2 = reg_tmp10.xzyw; + reg_tmp2.z = (-reg_tmp2.zzzz).z; + reg_tmp14 = reg_tmp2; + reg_tmp0 = uniforms.f[7]; + { + sub_2(); + } + reg_tmp2.x = dot_s(reg_tmp14, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp14, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp14, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp14, reg_tmp9); + reg_tmp6 = uniforms.f[8]; + reg_tmp7 = uniforms.f[9]; + reg_tmp8 = uniforms.f[10]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5].xxxx).w; + reg_tmp7.w = (uniforms.f[5].yyyy).w; + reg_tmp8.w = (uniforms.f[5].zzzz).w; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_15(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 07FFAEFECEA88493, 7D68CBC79559621F +// program: 7D68CBC79559621F, 13A54CCD8AA1DDA2, F2B0D3B757EF8F8A +// shader: 8B30, BBB276C35495C4E8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) - (1.0 - rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C19AD795D1DAD706, BBB276C35495C4E8 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, BBB276C35495C4E8 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, B6B08DE0C83FF4C8 +// shader: 8B30, 30B70359CC7FE7BC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0AFE9009BAB13DC4, 30B70359CC7FE7BC +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, 30B70359CC7FE7BC +// shader: 8B30, BFDA75D849404A72 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.ggg); +float alpha_output_0 = (texcolor0.g); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 71719874BAB13DC4, BFDA75D849404A72 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, BFDA75D849404A72 +// shader: 8B30, A1D25A4657970594 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) - (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((const_color[0].a) - (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0 * 4.0, alpha_output_0 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (last_tex_env_out.rgb); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1 * 4.0, alpha_output_1 * 4.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (vec3(1.0) - last_tex_env_out.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (const_color[2].a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: FCC53ADECAA07E74, A1D25A4657970594 +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, A1D25A4657970594 +// shader: 8B30, F6D05D883A3998ED +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor1.g); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B391E55860B491E1, F6D05D883A3998ED +// program: EB3171E0267A0BF2, 2E167B5E5D58FF27, F6D05D883A3998ED +// shader: 8B30, 9D04FE53001BD965 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) - (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) - (1.0 - rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F147A8FC5B18D7F4, 9D04FE53001BD965 +// program: 361AE2AA8DF99CD7, 13A54CCD8AA1DDA2, 9D04FE53001BD965 +// shader: 8B31, 84C4CE8A1020F446 + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_15(); +bool sub_2(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_0(); +bool sub_3(); +bool sub_4(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xyz = (vs_in_reg0.xyzz).xyz; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp11.xy = (vs_in_reg1.xyyy).xy; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_15() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = mul_s(vs_in_reg2, reg_tmp13); + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_5() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_6() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5].wwww).x; + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_7(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_8(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_9(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_10(); + } + reg_tmp3 = reg_tmp14.xyxy; + reg_tmp3.y = (uniforms.f[0].zzzz + -reg_tmp3.yyyy).y; + reg_tmp3.w = (uniforms.f[0].zzzz + -reg_tmp3.wwww).w; + reg_tmp2 = mul_s(uniforms.f[83].xxyy, reg_tmp3); + reg_tmp2 = -uniforms.f[0].yyyy + reg_tmp2; + reg_tmp2 = mul_s(reg_tmp2, reg_tmp1.xyyx); + reg_tmp2.x = (reg_tmp2.xxxx + -reg_tmp2.yyyy).x; + reg_tmp2.y = (reg_tmp2.zzzz + reg_tmp2.wwww).y; + reg_tmp4.xy = (uniforms.f[3].xyyy).xy; + reg_tmp3.xy = (fma_s(reg_tmp2.xyyy, uniforms.f[3].zwww, reg_tmp4.xyyy)).xy; + reg_tmp3.xy = (uniforms.f[0].yyyy + reg_tmp3.xyyy).xy; + reg_tmp11.xy = (reg_tmp3.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6].wwww).x; + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + reg_tmp3 = reg_tmp14.xyxy; + reg_tmp3.y = (uniforms.f[0].zzzz + -reg_tmp3.yyyy).y; + reg_tmp3.w = (uniforms.f[0].zzzz + -reg_tmp3.wwww).w; + reg_tmp2 = mul_s(uniforms.f[83].zzww, reg_tmp3); + reg_tmp2 = -uniforms.f[0].yyyy + reg_tmp2; + reg_tmp2 = mul_s(reg_tmp2, reg_tmp1.xyyx); + reg_tmp2.x = (reg_tmp2.xxxx + -reg_tmp2.yyyy).x; + reg_tmp2.y = (reg_tmp2.zzzz + reg_tmp2.wwww).y; + reg_tmp4.xy = (uniforms.f[4].xyyy).xy; + reg_tmp3.xy = (fma_s(reg_tmp2.xyyy, uniforms.f[4].zwww, reg_tmp4.xyyy)).xy; + reg_tmp3.xy = (uniforms.f[0].yyyy + reg_tmp3.xyyy).xy; + reg_tmp12.xy = (reg_tmp3.xyyy).xy; + return false; +} +bool sub_7() { + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + return false; +} +bool sub_8() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + return false; +} +bool sub_9() { + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_10() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_11() { + reg_tmp14.xy = (vs_in_reg1.xyyy).xy; + return false; +} +bool sub_12() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (uniforms.f[0].zzzz + -vs_in_reg1.xxxx).x; + reg_tmp14.y = (uniforms.f[0].zzzz + -vs_in_reg1.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xyz = (mul_s(uniforms.f[2].xyxx, reg_tmp10.xyzz)).xyz; + reg_tmp14 = reg_tmp10; + reg_tmp0 = uniforms.f[7]; + { + sub_2(); + } + reg_tmp10.x = dot_s(reg_tmp14, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp14, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp14, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp14, reg_tmp9); + reg_tmp6 = uniforms.f[8]; + reg_tmp7 = uniforms.f[9]; + reg_tmp8 = uniforms.f[10]; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp6.w = (uniforms.f[5].xxxx).w; + reg_tmp7.w = (uniforms.f[5].yyyy).w; + reg_tmp8.w = (uniforms.f[5].zzzz).w; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp10 = reg_tmp2; + reg_tmp3.xyz = (uniforms.f[5].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_5(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_6(); + } + { + sub_15(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: 47C1586B5202495C, 84C4CE8A1020F446 +// shader: 8B30, CD234BFB0B5B3996 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) - (1.0 - rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C19AD7956D0B8542, CD234BFB0B5B3996 +// program: 84C4CE8A1020F446, 13A54CCD8AA1DDA2, CD234BFB0B5B3996 +// shader: 8B31, 72719EF5D4E0D07F + +#define mul_s(x, y) mix(x * y, vec4(0.0), isnan(x * y)) +#define fma_s(x, y, z) (mix(x * y, vec4(0.0), isnan(x * y)) + z) +float rcp_s(float x) { + if (x == 0.0) return x; + return 1.0 / x; +} +float rsq_s(float x) { + if (x > 0.0) return inversesqrt(x); + return 0.0; +} +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_19(); +bool sub_2(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_0(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + address_registers.x = (ivec2(vs_in_reg0.zz)).x; + reg_tmp10 = uniforms.f[0].xxxz; + reg_tmp10.xy = (vs_in_reg0.xyyy).xy; + reg_tmp11 = uniforms.f[0].xxxx; + reg_tmp12 = uniforms.f[0].xxxx; + reg_tmp13 = uniforms.f[0].zzzz; + reg_tmp4 = uniforms.f[0].xxxx; + reg_tmp5 = uniforms.f[0].xxxx; + return false; +} +bool sub_19() { + vs_out_attr0 = reg_tmp10; + reg_tmp13 = mul_s(uniforms.f[82], reg_tmp13); + vs_out_attr1 = reg_tmp13; + reg_tmp11.y = (uniforms.f[0].zzzz + -reg_tmp11.yyyy).y; + reg_tmp12.y = (uniforms.f[0].zzzz + -reg_tmp12.yyyy).y; + reg_tmp14.y = (uniforms.f[81].wwww).y; + reg_tmp14.x = (mul_s(uniforms.f[0].wwww, reg_tmp14.yyyy)).x; + reg_tmp2.x = rcp_s(reg_tmp14.x); + reg_tmp14.z = (reg_tmp2.xxxx).z; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp11.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp11.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + reg_tmp3.xy = (uniforms.f[81].wwww + reg_tmp12.xyyy).xy; + reg_tmp5.xy = (mul_s(reg_tmp3.xyyy, reg_tmp14.zzzz)).xy; + reg_tmp4.xy = (floor(reg_tmp5.xyyy)).xy; + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp14.xxxx)).xy; + reg_tmp4.xy = (reg_tmp3.xyyy + -reg_tmp4.xyyy).xy; + reg_tmp12.xy = (-uniforms.f[81].wwww + reg_tmp4.xyyy).xy; + vs_out_attr2 = reg_tmp11; + vs_out_attr3 = reg_tmp12; + return false; +} +bool sub_2() { + reg_tmp6.xyz = (-reg_tmp0.xyzz).xyz; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.xyz = vec3(rcp_s(uniforms.f[81].y)); + reg_tmp8.xyz = (fma_s(reg_tmp6.xyzz, reg_tmp7.xyzz, uniforms.f[0].yyyy)).xyz; + reg_tmp7.xyz = (floor(reg_tmp8.xyzz)).xyz; + reg_tmp6.xyz = (fma_s(reg_tmp7.xyzz, -uniforms.f[81].yyyy, reg_tmp6.xyzz)).xyz; + reg_tmp6 = min(uniforms.f[81].xxxx, reg_tmp6); + reg_tmp6 = max(-uniforms.f[81].xxxx, reg_tmp6); + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.xxxx, reg_tmp6.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.xxxx)).y; + reg_tmp4.x = (reg_tmp1.xxxx).x; + reg_tmp5.x = (reg_tmp1.yyyy).x; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.yyyy, reg_tmp6.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.yyyy)).y; + reg_tmp4.y = (reg_tmp1.xxxx).y; + reg_tmp5.y = (reg_tmp1.yyyy).y; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp6.zzzz, reg_tmp6.zzzz)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp6.zzzz)).y; + reg_tmp4.z = (reg_tmp1.xxxx).z; + reg_tmp5.z = (reg_tmp1.yyyy).z; + reg_tmp2.x = (mul_s(reg_tmp4.yyyy, reg_tmp5.zzzz)).x; + reg_tmp2.y = (mul_s(reg_tmp5.yyyy, reg_tmp5.zzzz)).y; + reg_tmp6.x = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).x; + reg_tmp6.y = (reg_tmp5.zzzz).y; + reg_tmp6.z = (mul_s(-reg_tmp5.yyyy, reg_tmp4.zzzz)).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (mul_s(-reg_tmp2.xxxx, reg_tmp4.xxxx)).x; + reg_tmp7.x = (fma_s(reg_tmp5.yyyy, reg_tmp5.xxxx, reg_tmp7.xxxx)).x; + reg_tmp7.y = (mul_s(reg_tmp4.zzzz, reg_tmp4.xxxx)).y; + reg_tmp7.z = (mul_s(reg_tmp2.yyyy, reg_tmp4.xxxx)).z; + reg_tmp7.z = (fma_s(reg_tmp4.yyyy, reg_tmp5.xxxx, reg_tmp7.zzzz)).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (mul_s(reg_tmp2.xxxx, reg_tmp5.xxxx)).x; + reg_tmp8.x = (fma_s(reg_tmp5.yyyy, reg_tmp4.xxxx, reg_tmp8.xxxx)).x; + reg_tmp8.y = (mul_s(-reg_tmp4.zzzz, reg_tmp5.xxxx)).y; + reg_tmp8.z = (mul_s(-reg_tmp2.yyyy, reg_tmp5.xxxx)).z; + reg_tmp8.z = (fma_s(reg_tmp4.yyyy, reg_tmp4.xxxx, reg_tmp8.zzzz)).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + return false; +} +bool sub_9() { + reg_tmp2 = uniforms.f[90]; + reg_tmp3 = uniforms.f[91]; + reg_tmp4 = uniforms.f[92]; + reg_tmp5 = uniforms.f[0].xxxz; + reg_tmp6 = mul_s(uniforms.f[86].xxxx, reg_tmp2); + reg_tmp6 = fma_s(reg_tmp3, uniforms.f[86].yyyy, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp4, uniforms.f[86].zzzz, reg_tmp6); + reg_tmp6 = fma_s(reg_tmp5, uniforms.f[86].wwww, reg_tmp6); + reg_tmp7 = mul_s(uniforms.f[87].xxxx, reg_tmp2); + reg_tmp7 = fma_s(reg_tmp3, uniforms.f[87].yyyy, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp4, uniforms.f[87].zzzz, reg_tmp7); + reg_tmp7 = fma_s(reg_tmp5, uniforms.f[87].wwww, reg_tmp7); + reg_tmp8 = mul_s(uniforms.f[88].xxxx, reg_tmp2); + reg_tmp8 = fma_s(reg_tmp3, uniforms.f[88].yyyy, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp4, uniforms.f[88].zzzz, reg_tmp8); + reg_tmp8 = fma_s(reg_tmp5, uniforms.f[88].wwww, reg_tmp8); + reg_tmp9 = mul_s(uniforms.f[89].xxxx, reg_tmp2); + reg_tmp9 = fma_s(reg_tmp3, uniforms.f[89].yyyy, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp4, uniforms.f[89].zzzz, reg_tmp9); + reg_tmp9 = fma_s(reg_tmp5, uniforms.f[89].wwww, reg_tmp9); + return false; +} +bool sub_10() { + reg_tmp2.x = rcp_s(uniforms.f[81].y); + reg_tmp2.xy = (mul_s(uniforms.f[2 + address_registers.x].zwww, reg_tmp2.xxxx)).xy; + reg_tmp2.xy = (uniforms.f[0].yyyy + reg_tmp2.xyyy).xy; + reg_tmp3.xy = (floor(reg_tmp2.xyyy)).xy; + reg_tmp2.xy = (mul_s(uniforms.f[81].yyyy, reg_tmp3.xyyy)).xy; + reg_tmp2.xy = (uniforms.f[2 + address_registers.x].zwww + -reg_tmp2.xyyy).xy; + reg_tmp0.xy = (min(uniforms.f[81].xxxx, -reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (max(-uniforms.f[81].xxxx, reg_tmp0.xyyy)).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.xxxx, reg_tmp0.xxxx)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.xxxx)).y; + reg_tmp5.x = (uniforms.f[5 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_11(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_12(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_13(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_14(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].xxxx).z; + reg_tmp4.w = (-uniforms.f[83].yyyy).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[3 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[3 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[3 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp11.xy = (reg_tmp5.xyyy).xy; + reg_tmp2 = uniforms.f[95]; + reg_tmp3 = uniforms.f[94]; + reg_tmp1.z = (mul_s(reg_tmp0.yyyy, reg_tmp0.yyyy)).z; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp2.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp3.zwww)).xy; + reg_tmp2 = uniforms.f[93]; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp1.xy = (fma_s(reg_tmp1.zzzz, reg_tmp1.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1.y = (mul_s(reg_tmp1.yyyy, reg_tmp0.yyyy)).y; + reg_tmp5.x = (uniforms.f[6 + address_registers.x].wwww).x; + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + conditional_code.x = uniforms.f[0].xxxx.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].xxxx.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_15(); + } + conditional_code.x = uniforms.f[0].zzzz.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].zzzz.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_16(); + } + conditional_code.x = uniforms.f[0].wwww.x == reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_17(); + } + conditional_code.x = uniforms.f[0].wwww.x < reg_tmp5.xxxx.x; + conditional_code.y = uniforms.f[0].wwww.y != reg_tmp5.xxxx.y; + if (conditional_code.x) { + sub_18(); + } + reg_tmp4.xy = (mul_s(reg_tmp14.xxxx, reg_tmp1.xyyy)).xy; + reg_tmp4.x = (fma_s(-reg_tmp14.yyyy, reg_tmp1.yyyy, reg_tmp4.xxxx)).x; + reg_tmp4.y = (fma_s(reg_tmp14.yyyy, reg_tmp1.xxxx, reg_tmp4.yyyy)).y; + reg_tmp5.x = (uniforms.f[0].yyyy + reg_tmp4.xxxx).x; + reg_tmp5.y = (-uniforms.f[0].yyyy + reg_tmp4.yyyy).y; + reg_tmp4.z = (uniforms.f[83].zzzz).z; + reg_tmp4.w = (-uniforms.f[83].wwww).w; + reg_tmp5.xy = (fma_s(reg_tmp5.xyyy, reg_tmp4.zwww, uniforms.f[4 + address_registers.x].xyyy)).xy; + reg_tmp4.z = (-uniforms.f[4 + address_registers.x].zzzz).z; + reg_tmp4.w = (-uniforms.f[4 + address_registers.x].wwww).w; + reg_tmp5.z = (uniforms.f[0].zzzz + reg_tmp4.zzzz).z; + reg_tmp5.w = (uniforms.f[0].zzzz + reg_tmp4.wwww).w; + reg_tmp5.x = (fma_s(-reg_tmp5.zzzz, reg_tmp4.xxxx, reg_tmp5.xxxx)).x; + reg_tmp5.y = (fma_s(reg_tmp5.wwww, reg_tmp4.yyyy, reg_tmp5.yyyy)).y; + reg_tmp12.xy = (reg_tmp5.xyyy).xy; + return false; +} +bool sub_11() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_12() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_13() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_14() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_15() { + reg_tmp14.x = (vs_in_reg0.xxxx).x; + reg_tmp14.y = (vs_in_reg0.yyyy).y; + return false; +} +bool sub_16() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + return false; +} +bool sub_17() { + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_18() { + reg_tmp14.x = (-vs_in_reg0.xxxx).x; + reg_tmp14.y = (-vs_in_reg0.yyyy).y; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp10.xy = (uniforms.f[84].xyyy + reg_tmp10.xyyy).xy; + reg_tmp10.xy = (mul_s(uniforms.f[2 + address_registers.x].xyyy, reg_tmp10.xyyy)).xy; + reg_tmp14 = reg_tmp10; + reg_tmp0 = uniforms.f[7 + address_registers.x]; + { + sub_2(); + } + reg_tmp10.x = dot_s(reg_tmp14, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp14, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp14, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp14, reg_tmp9); + reg_tmp2.x = (uniforms.f[8 + address_registers.x].yyyy).x; + reg_tmp2.y = (uniforms.f[9 + address_registers.x].yyyy).y; + reg_tmp2.z = (uniforms.f[10 + address_registers.x].yyyy).z; + reg_tmp3.xyz = (uniforms.f[6 + address_registers.x].xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_3(); + } else { + sub_4(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp4.xyz = (mul_s(reg_tmp2.yzxx, reg_tmp3.zxyy)).xyz; + reg_tmp4.xyz = (fma_s(-reg_tmp3.yzxx, reg_tmp2.zxyy, reg_tmp4)).xyz; + reg_tmp5.x = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp5.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp5.y; + if (conditional_code.x) { + sub_5(); + } else { + sub_6(); + } + reg_tmp4.xyz = (mul_s(reg_tmp4.xyzz, reg_tmp5.xxxx)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp4.yzxx, reg_tmp3.zxyy)).xyz; + reg_tmp5.xyz = (fma_s(-reg_tmp3.yzxx, reg_tmp4.zxyy, reg_tmp5)).xyz; + reg_tmp6.x = (reg_tmp4.xxxx).x; + reg_tmp6.y = (reg_tmp3.xxxx).y; + reg_tmp6.z = (reg_tmp5.xxxx).z; + reg_tmp6.w = (uniforms.f[0].xxxx).w; + reg_tmp7.x = (reg_tmp4.yyyy).x; + reg_tmp7.y = (reg_tmp3.yyyy).y; + reg_tmp7.z = (reg_tmp5.yyyy).z; + reg_tmp7.w = (uniforms.f[0].xxxx).w; + reg_tmp8.x = (reg_tmp4.zzzz).x; + reg_tmp8.y = (reg_tmp3.zzzz).y; + reg_tmp8.z = (reg_tmp5.zzzz).z; + reg_tmp8.w = (uniforms.f[0].xxxx).w; + reg_tmp9 = uniforms.f[0].xxxz; + reg_tmp2.x = dot_s(reg_tmp10, reg_tmp6); + reg_tmp2.y = dot_s(reg_tmp10, reg_tmp7); + reg_tmp2.z = dot_s(reg_tmp10, reg_tmp8); + reg_tmp2.w = dot_s(reg_tmp10, reg_tmp9); + reg_tmp3.xyz = (uniforms.f[5 + address_registers.x].xyzz).xyz; + reg_tmp3.xyz = (uniforms.f[85].xyzz + -reg_tmp3.xyzz).xyz; + reg_tmp4.x = dot_3(reg_tmp3.xyz, reg_tmp3.xyz); + conditional_code.x = uniforms.f[0].xxxx.x >= reg_tmp4.x; + conditional_code.y = uniforms.f[0].xxxx.y == reg_tmp4.y; + if (conditional_code.x) { + sub_7(); + } else { + sub_8(); + } + reg_tmp3.xyz = (mul_s(reg_tmp3.xyzz, reg_tmp4.xxxx)).xyz; + reg_tmp10.xyz = (uniforms.f[5 + address_registers.x].xyzz + reg_tmp2.xyzz).xyz; + reg_tmp10.xyz = (fma_s(reg_tmp3.xyzz, uniforms.f[84].zzzz, reg_tmp10.xyzz)).xyz; + { + sub_9(); + } + reg_tmp2 = reg_tmp10; + reg_tmp10.x = dot_s(reg_tmp2, reg_tmp6); + reg_tmp10.y = dot_s(reg_tmp2, reg_tmp7); + reg_tmp10.z = dot_s(reg_tmp2, reg_tmp8); + reg_tmp10.w = dot_s(reg_tmp2, reg_tmp9); + reg_tmp2 = uniforms.f[1 + address_registers.x]; + reg_tmp3 = max(uniforms.f[0].xxxx, reg_tmp2); + reg_tmp2 = min(uniforms.f[0].zzzz, reg_tmp3); + reg_tmp13 = reg_tmp2; + { + sub_10(); + } + { + sub_19(); + } + return true; +} +bool sub_3() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_4() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +bool sub_5() { + reg_tmp5.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_6() { + reg_tmp5.x = rsq_s(reg_tmp5.x); + return false; +} +bool sub_7() { + reg_tmp4.x = (uniforms.f[0].zzzz).x; + return false; +} +bool sub_8() { + reg_tmp4.x = rsq_s(reg_tmp4.x); + return false; +} +// reference: E006E3BA94E4D768, 72719EF5D4E0D07F +// shader: 8B30, EDB11957E1308F8F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.r); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 963614AE4030BFB2, EDB11957E1308F8F +// program: 72719EF5D4E0D07F, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// shader: 8B30, E0AB1B15483A4CBF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((const_color[0].rgb) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) + (texcolor1.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 48DD229646ED1786, E0AB1B15483A4CBF +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, E0AB1B15483A4CBF +// program: 1B4F5D8F85FA1A43, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// program: 361AE2AA8DF99CD7, 13A54CCD8AA1DDA2, B6B08DE0C83FF4C8 +// shader: 8B30, 1041172C77D1741F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8CF3843FFA3C45C2, 1041172C77D1741F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 1041172C77D1741F +// shader: 8B30, 420D60AE0B5B3996 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor1.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.r) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((last_tex_env_out.a) - (1.0 - rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1 * 1.0, alpha_output_1 * 2.0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - combiner_buffer.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DBBE5FCC6D0B8542, 420D60AE0B5B3996 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 420D60AE0B5B3996 +// program: 84C4CE8A1020F446, 13A54CCD8AA1DDA2, CD234BFB0B5B3996 +// program: 72719EF5D4E0D07F, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, E0AB1B15483A4CBF +// program: 1B4F5D8F85FA1A43, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// program: 361AE2AA8DF99CD7, 13A54CCD8AA1DDA2, B6B08DE0C83FF4C8 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 1041172C77D1741F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 420D60AE0B5B3996 +// reference: CC8B58D7834808DA, BD099273E0557909 +// reference: 80DA69775C520375, 4C0BB907EE40D414 +// reference: 0EA7F8CA4E98ECE4, 69603AA5B061A024 +// reference: 69375C50A88D5D2F, 9D04FE53001BD965 +// reference: D8FAAB0284BA59FF, 3BC00FBFE97A550F +// reference: 4BD6AAC282F36C92, EB3171E0267A0BF2 +// reference: 017B59A1118283C7, 361AE2AA8DF99CD7 +// reference: 15D7A4B50E5BF60D, 856D50001A60785F +// reference: AE521CFA331ABEC1, 840CDA2008BFF630 +// reference: 2BC49DCE3F775D7A, 1B4F5D8F85FA1A43 +// reference: 38430F89BD2374F9, C270E8617D51E2E6 +// reference: 49AB51BECEA88493, 7D68CBC79559621F +// reference: 0995A72B5202495C, 84C4CE8A1020F446 +// program: 84C4CE8A1020F446, 13A54CCD8AA1DDA2, CD234BFB0B5B3996 +// reference: AE521CFA94E4D768, 72719EF5D4E0D07F +// program: 72719EF5D4E0D07F, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, E0AB1B15483A4CBF +// program: 1B4F5D8F85FA1A43, 13A54CCD8AA1DDA2, EDB11957E1308F8F +// program: 361AE2AA8DF99CD7, 13A54CCD8AA1DDA2, B6B08DE0C83FF4C8 +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 1041172C77D1741F +// program: 856D50001A60785F, 13A54CCD8AA1DDA2, 420D60AE0B5B3996 diff --git a/cache/00040000001A4800.shader.meta b/cache/00040000001A4800.shader.meta new file mode 100644 index 00000000000..d2664337180 --- /dev/null +++ b/cache/00040000001A4800.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 79 +reference: 105 +program: 72 diff --git a/cache/000400000FAA5C00.shader b/cache/000400000FAA5C00.shader new file mode 100644 index 00000000000..e42b5002ffe --- /dev/null +++ b/cache/000400000FAA5C00.shader @@ -0,0 +1,3682 @@ +// shader: 8DD9, 85EC09B9168BD0AD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[1].x, vtx.attributes[1].y); + texcoord1 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: B2FBB4AEDB50B6A4, 85EC09B9168BD0AD +// shader: 8B31, 9B700A12F2D75FD8 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + vs_out_attr0 = vs_in_reg0; + vs_out_attr1 = vs_in_reg1; + vs_out_attr2 = vs_in_reg1; + vs_out_attr3 = vs_in_reg2; + return true; +} +// reference: 0BE8ACE18281E2D1, 9B700A12F2D75FD8 +// shader: 8B30, 55DC97714BEADD97 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D9DA7721F42B4556, 55DC97714BEADD97 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 55DC97714BEADD97 +// shader: 8B30, 73AB35B154919C6B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 326FE1A2F42B4556, 73AB35B154919C6B +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 73AB35B154919C6B +// shader: 8B30, 8506EE4EFB0216CC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ECDEBBBD0F96A0A6, 8506EE4EFB0216CC +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 8506EE4EFB0216CC +// shader: 8B30, 8884CF8C8A9364CC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 326FE1A29B511B5D, 8884CF8C8A9364CC +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 8884CF8C8A9364CC +// shader: 8B30, EDC93657D91090A0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 326FE1A260ECFEAD, EDC93657D91090A0 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, EDC93657D91090A0 +// shader: 8B30, 0983C172A70C77DC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 326FE1A20F96A0A6, 0983C172A70C77DC +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 0983C172A70C77DC +// shader: 8B30, 38A97222897F6079 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ECDEBBBD5C9303CF, 38A97222897F6079 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 38A97222897F6079 +// shader: 8B30, 06754142CBE6760F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 46E4BF902F4F74A6, 06754142CBE6760F +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 06754142CBE6760F +// shader: 8B30, 6CDD8F33FCA5AC39 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (const_color[1].a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 46E4BF90D5B30937, 6CDD8F33FCA5AC39 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 6CDD8F33FCA5AC39 +// shader: 8B30, 1E1DA7BD14376D7D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 326FE1A25C9303CF, 1E1DA7BD14376D7D +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 1E1DA7BD14376D7D +// shader: 8B30, 77A0240D939DC4D1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 28AA71335C9303CF, 77A0240D939DC4D1 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 77A0240D939DC4D1 +// shader: 8B30, 5049030991AED6EC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: ECDEBBBD60ECFEAD, 5049030991AED6EC +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 5049030991AED6EC +// shader: 8B30, A33FA169AB83EFC7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F61B2B2C5C9303CF, A33FA169AB83EFC7 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, A33FA169AB83EFC7 +// shader: 8B30, 9BCE57F968749AF3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.aaa) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: F3A827B3AC16DF2F, 9BCE57F968749AF3 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 9BCE57F968749AF3 +// shader: 8B30, 6F97CB83C1CE26ED +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BA57A7C6F709FA9C, 6F97CB83C1CE26ED +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 6F97CB83C1CE26ED +// shader: 8B30, B0DCFFF3C0FF493B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: C31FE7B05C9303CF, B0DCFFF3C0FF493B +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, B0DCFFF3C0FF493B +// shader: 8B30, 0D7FD6B1CB28D05C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 076B2D3E60ECFEAD, 0D7FD6B1CB28D05C +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 0D7FD6B1CB28D05C +// shader: 8B30, 8E0CEDD894B43D89 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 076B2D3E0F96A0A6, 8E0CEDD894B43D89 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 8E0CEDD894B43D89 +// shader: 8B30, F927AB86AE1447BA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D9DA77219B511B5D, F927AB86AE1447BA +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, F927AB86AE1447BA +// shader: 8B30, 4B35A1D179FF5A87 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (texcolor0.aaa) + (rounded_primary_color.rgb) * (vec3(1.0) - (texcolor0.aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 181DB130AC16DF2F, 4B35A1D179FF5A87 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, 4B35A1D179FF5A87 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D9DA77215C9303CF, DC12E218392F9BDB +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, DC12E218392F9BDB +// shader: 8B30, EA0F81D473B04937 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 51E23145F709FA9C, EA0F81D473B04937 +// program: 9B700A12F2D75FD8, 85EC09B9168BD0AD, EA0F81D473B04937 diff --git a/cache/000400000FAA5C00.shader.meta b/cache/000400000FAA5C00.shader.meta new file mode 100644 index 00000000000..160098ac4f6 --- /dev/null +++ b/cache/000400000FAA5C00.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 24 +reference: 24 +program: 22 diff --git a/cache/0004001000021700.shader b/cache/0004001000021700.shader new file mode 100644 index 00000000000..3607596a3cd --- /dev/null +++ b/cache/0004001000021700.shader @@ -0,0 +1,21256 @@ +// shader: 8B31, FC7F4467554D34E5 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); +bool sub_8(); +bool sub_9(); +bool sub_10(); +bool sub_11(); +bool sub_12(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + address_registers.x = (ivec2(vs_in_reg0.xy)).x; + reg_tmp0 = uniforms.f[6 + address_registers.x].wzyx; + reg_tmp1.xy = (vs_in_reg0.zwzw).xy; + reg_tmp1.zw = (uniforms.f[5].xyxy).zw; + address_registers.xy = ivec2(reg_tmp0.xy); + reg_tmp2.xw = (uniforms.f[64 + address_registers.y].wwyy).xw; + reg_tmp2.yz = (uniforms.f[5].xxxx).yz; + reg_tmp4.x = dot_s(reg_tmp1, reg_tmp2); + reg_tmp2.yw = (uniforms.f[64 + address_registers.y].zzxx).yw; + reg_tmp2.xz = (uniforms.f[5].xxxx).xz; + reg_tmp4.y = dot_s(reg_tmp1, reg_tmp2); + reg_tmp4.zw = (reg_tmp1.zwzw).zw; + reg_tmp3.x = dot_s(uniforms.f[32 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.y = dot_s(uniforms.f[33 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.z = dot_s(uniforms.f[34 + address_registers.x].wzyx, reg_tmp4); + reg_tmp3.w = (reg_tmp1.wwww).w; + reg_tmp4.z = (uniforms.f[34 + address_registers.x].xxxx).z; + reg_tmp4.z = (abs(reg_tmp4.zzzz)).z; + reg_tmp4.z = (uniforms.f[4].yyyy + reg_tmp4.zzzz).z; + reg_tmp4.x = (uniforms.f[4].wwww).x; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp4.xz); + if (all(conditional_code)) { + sub_1(); + } + vs_out_attr0.x = dot_s(uniforms.f[0].wzyx, reg_tmp3); + vs_out_attr0.y = dot_s(uniforms.f[1].wzyx, reg_tmp3); + vs_out_attr0.z = dot_s(uniforms.f[2].wzyx, reg_tmp3); + vs_out_attr0.w = dot_s(uniforms.f[3].wzyx, reg_tmp3); + conditional_code = greaterThanEqual(uniforms.f[5].yy, reg_tmp0.ww); + if (all(conditional_code)) { + sub_2(); + } else { + sub_3(); + } + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_8(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_9(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_10(); + } + if (all(conditional_code)) { + sub_11(); + } + reg_tmp8 = uniforms.f[5].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop64 = 0u; loop64 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop64) { + sub_12(); + } + vs_out_attr2 = reg_tmp5; + vs_out_attr3 = reg_tmp6; + vs_out_attr4 = reg_tmp7; + return true; +} +bool sub_1() { + reg_tmp4.x = (uniforms.f[4].wwww).x; + reg_tmp4.y = (-uniforms.f[4].zzzz + reg_tmp4.zzzz).y; + reg_tmp4.z = rcp_s(reg_tmp4.z); + reg_tmp4.z = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).z; + reg_tmp3.x = (fma_s(reg_tmp4.xxxx, reg_tmp4.zzzz, reg_tmp3.xxxx)).x; + return false; +} +bool sub_2() { + vs_out_attr1.xyz = (uniforms.f[5].yyyy).xyz; + vs_out_attr1.w = (reg_tmp0.wwww).w; + return false; +} +bool sub_3() { + address_registers.y = (ivec2(reg_tmp0.ww)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_4(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_5(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_6(); + } + if (all(conditional_code)) { + sub_7(); + } + return false; +} +bool sub_4() { + vs_out_attr1 = uniforms.f[32 + address_registers.y].wzyx; + return false; +} +bool sub_5() { + vs_out_attr1 = uniforms.f[33 + address_registers.y].wzyx; + return false; +} +bool sub_6() { + vs_out_attr1 = uniforms.f[34 + address_registers.y].wzyx; + return false; +} +bool sub_7() { + vs_out_attr1 = uniforms.f[35 + address_registers.y].wzyx; + return false; +} +bool sub_8() { + reg_tmp5 = uniforms.f[5].xyyy; + reg_tmp6 = uniforms.f[5].xyyy; + reg_tmp7 = uniforms.f[5].xyyy; + return false; +} +bool sub_9() { + reg_tmp5 = uniforms.f[5].yyyy; + reg_tmp6 = uniforms.f[5].yyyy; + reg_tmp7 = uniforms.f[5].yyyy; + return false; +} +bool sub_10() { + reg_tmp5 = uniforms.f[5].xxyy; + reg_tmp6 = uniforms.f[5].xxyy; + reg_tmp7 = uniforms.f[5].xxyy; + return false; +} +bool sub_11() { + reg_tmp5 = uniforms.f[5].yxyy; + reg_tmp6 = uniforms.f[5].yxyy; + reg_tmp7 = uniforms.f[5].yxyy; + return false; +} +bool sub_12() { + conditional_code = equal(uniforms.f[5].yy, reg_tmp8.xy); + if (all(conditional_code)) { + sub_13(); + } + conditional_code = lessThan(uniforms.f[5].ww, reg_tmp8.xy); + if (all(conditional_code)) { + sub_18(); + } + reg_tmp8 = uniforms.f[5].yyyy + reg_tmp8; + return false; +} +bool sub_13() { + address_registers.y = (ivec2(reg_tmp0.zz)).y; + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(not(conditional_code))) { + sub_14(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_15(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_16(); + } + if (all(conditional_code)) { + sub_17(); + } + return false; +} +bool sub_14() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wzzz).xy; + return false; +} +bool sub_15() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yzzz).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yzzz).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yzzz).xy; + return false; +} +bool sub_16() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].wxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].wxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].wxxx).xy; + return false; +} +bool sub_17() { + reg_tmp5.xy = (uniforms.f[64 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[65 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[66 + address_registers.y].yxxx).xy; + return false; +} +bool sub_18() { + conditional_code = notEqual(uniforms.f[5].xx, reg_tmp1.xy); + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_19(); + } + if (all(bvec2(!conditional_code.x, conditional_code.y))) { + sub_20(); + } + return false; +} +bool sub_19() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].yxxx).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].yxxx).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].yxxx).xy; + return false; +} +bool sub_20() { + reg_tmp5.xy = (uniforms.f[67 + address_registers.y].wzzz).xy; + reg_tmp6.xy = (uniforms.f[68 + address_registers.y].wzzz).xy; + reg_tmp7.xy = (uniforms.f[69 + address_registers.y].wzzz).xy; + return false; +} +// reference: FDD61A8370EFA141, FC7F4467554D34E5 +// shader: 8DD9, 1C4CBC8096EA16CD + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +struct Vertex { + vec4 attributes[5]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(0.0, 0.0, 0.0, 0.0); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[2].x, vtx.attributes[2].y); + texcoord1 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + + texcoord0_w = 0.0; + view = vec3(0.0, 0.0, 0.0); + texcoord2 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[5](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0]); + prim_buffer[1].attributes = vec4[5](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1]); + prim_buffer[2].attributes = vec4[5](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 5DAD5699F59B3586, 1C4CBC8096EA16CD +// shader: 8B30, 36710957A681BE0D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].aaa) * (last_tex_env_out.rgb) + (const_color[3].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (rounded_primary_color.rgb) + (const_color[4].rgb) * (vec3(1.0) - (rounded_primary_color.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E6D9F391DC93F028, 36710957A681BE0D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 36710957A681BE0D +// reference: A1374A2DF31AC733, FC7F4467554D34E5 +// shader: 8B30, 51CB5E6E49DE5BFA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 194CA22E7F9DCA65, 51CB5E6E49DE5BFA +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 51CB5E6E49DE5BFA +// shader: 8B30, B4827B1159226B77 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (1.0 - last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 94F1A03093E4273B, B4827B1159226B77 +// program: 0000000000000000, 0000000000000000, B4827B1159226B77 +// shader: 8B30, 56E39B78761D4B9B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF97322A0F3, 56E39B78761D4B9B +// program: 0000000000000000, 0000000000000000, 56E39B78761D4B9B +// shader: 8B30, 896DA0E74D8DAAA2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 3A146E84156479AC, 896DA0E74D8DAAA2 +// program: 0000000000000000, 0000000000000000, 896DA0E74D8DAAA2 +// shader: 8B30, 9444C4B0C1563378 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF9CC90E899, 9444C4B0C1563378 +// program: 0000000000000000, 0000000000000000, 9444C4B0C1563378 +// shader: 8B30, A956F9A654768EDC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF988C2D14A, A956F9A654768EDC +// program: 0000000000000000, 0000000000000000, A956F9A654768EDC +// shader: 8B30, DD514AADA8203F09 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D4F4BEF993E4273B, DD514AADA8203F09 +// program: 0000000000000000, 0000000000000000, DD514AADA8203F09 +// shader: 8B30, 4F0C7CD16F28734A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8ECA464FBF4B4934, 4F0C7CD16F28734A +// program: 0000000000000000, 0000000000000000, 4F0C7CD16F28734A +// shader: 8B31, 2ADB5861BD9769B7 + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_23(); +bool sub_6(); +bool sub_11(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_7(); +bool sub_9(); +bool sub_10(); +bool sub_12(); +bool sub_22(); +bool sub_24(); +bool sub_25(); +bool sub_26(); +bool sub_27(); +bool sub_28(); +bool sub_29(); +bool sub_30(); +bool sub_31(); +bool sub_32(); +bool sub_8(); +bool sub_13(); +bool sub_14(); +bool sub_15(); +bool sub_16(); +bool sub_17(); +bool sub_18(); +bool sub_19(); +bool sub_20(); +bool sub_21(); +bool sub_33(); +bool sub_34(); +bool sub_35(); +bool sub_47(); +bool sub_36(); +bool sub_37(); +bool sub_38(); +bool sub_39(); +bool sub_40(); +bool sub_41(); +bool sub_42(); +bool sub_43(); +bool sub_44(); +bool sub_45(); +bool sub_46(); +bool sub_48(); +bool sub_49(); +bool sub_55(); +bool sub_56(); +bool sub_57(); +bool sub_58(); +bool sub_60(); +bool sub_50(); +bool sub_51(); +bool sub_52(); +bool sub_53(); +bool sub_54(); +bool sub_59(); +bool sub_61(); +bool sub_62(); +bool sub_63(); +bool sub_64(); +bool sub_65(); +bool sub_66(); +bool sub_67(); +bool sub_68(); +bool sub_69(); +bool sub_70(); +bool sub_71(); +bool sub_72(); +bool sub_73(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + { + sub_1(); + } + { + sub_33(); + } + { + sub_48(); + } + { + sub_62(); + } + { + sub_69(); + } + return true; +} +bool sub_23() { + address_registers.x = (ivec2(reg_tmp1.xx)).x; + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + return false; +} +bool sub_6() { + reg_tmp1.y = (reg_tmp1.yyyy + reg_tmp2.yyyy).y; + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + return false; +} +bool sub_11() { + reg_tmp1.y = (reg_tmp1.yyyy + reg_tmp2.yyyy).y; + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp3.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp3.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp3.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp4.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp4.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp5.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp5.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp5.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp7 = fma_s(reg_tmp1.wwww, reg_tmp3, reg_tmp7); + reg_tmp12 = fma_s(reg_tmp1.wwww, reg_tmp4, reg_tmp12); + reg_tmp11 = fma_s(reg_tmp1.wwww, reg_tmp5, reg_tmp11); + return false; +} +bool sub_1() { + reg_tmp15.xyz = (mul_s(uniforms.f[7].xxxx, vs_in_reg0)).xyz; + reg_tmp14.xyz = (mul_s(uniforms.f[7].yyyy, vs_in_reg1)).xyz; + reg_tmp13.xyz = (mul_s(uniforms.f[7].zzzz, vs_in_reg2)).xyz; + reg_tmp15.xyz = (uniforms.f[6] + reg_tmp15).xyz; + reg_tmp15.w = (uniforms.f[93].yyyy).w; + if (uniforms.b[1]) { + sub_2(); + } else { + sub_25(); + } + return false; +} +bool sub_2() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp12 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp2.x = (uniforms.f[9].xxxx).x; + if (uniforms.b[4]) { + sub_3(); + } else { + sub_4(); + } + reg_tmp2.xy = (mul_s(uniforms.f[93].wwww, reg_tmp2.xyyy)).xy; + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_5(); + } else { + sub_9(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_3() { + reg_tmp2.y = (uniforms.f[9].zzzz).y; + return false; +} +bool sub_4() { + reg_tmp2.y = (uniforms.f[93].xxxx).y; + return false; +} +bool sub_5() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (mul_s(vs_in_reg7.xxxx, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_6(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.yyyy, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_6(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.zzzz, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_6(); + } + if (uniforms.b[8]) { + sub_7(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_8(); + } + return false; +} +bool sub_7() { + reg_tmp1.xy = (mul_s(vs_in_reg7.wwww, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_6(); + } + return false; +} +bool sub_9() { + if (all(conditional_code)) { + sub_10(); + } else { + sub_22(); + } + return false; +} +bool sub_10() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (mul_s(vs_in_reg7.xxxx, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_11(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.yyyy, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_11(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.zzzz, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_11(); + } + if (uniforms.b[8]) { + sub_12(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + { + sub_13(); + } + return false; +} +bool sub_12() { + reg_tmp1.xy = (mul_s(vs_in_reg7.wwww, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_11(); + } + return false; +} +bool sub_22() { + conditional_code = notEqual(uniforms.f[93].xx, vs_in_reg8.zw); + reg_tmp1.xy = (mul_s(vs_in_reg7.xxxx, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.xxxx)).w; + { + sub_23(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.yyyy, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.yyyy)).w; + { + sub_23(); + } + reg_tmp1.xy = (mul_s(vs_in_reg7.zzzz, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.zzzz)).w; + if (conditional_code.x) { + sub_23(); + } + if (uniforms.b[8]) { + sub_24(); + } + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_24() { + reg_tmp1.xy = (mul_s(vs_in_reg7.wwww, reg_tmp2.xxxx)).xy; + reg_tmp1.w = (mul_s(uniforms.f[8].wwww, vs_in_reg8.wwww)).w; + if (conditional_code.y) { + sub_23(); + } + return false; +} +bool sub_25() { + reg_tmp0 = uniforms.f[7]; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.yz); + if (uniforms.b[2]) { + sub_26(); + } else { + sub_28(); + } + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_29(); + } else { + sub_30(); + } + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + return false; +} +bool sub_26() { + reg_tmp1.xy = (mul_s(uniforms.f[9].xxxx, vs_in_reg7.xxxx)).xy; + if (uniforms.b[4]) { + sub_27(); + } + reg_tmp1.xy = (mul_s(uniforms.f[93].wwww, reg_tmp1.xyyy)).xy; + address_registers.xy = ivec2(reg_tmp1.xy); + reg_tmp7.x = dot_s(uniforms.f[25 + address_registers.x], reg_tmp15); + reg_tmp7.y = dot_s(uniforms.f[26 + address_registers.x], reg_tmp15); + reg_tmp7.z = dot_s(uniforms.f[27 + address_registers.x], reg_tmp15); + reg_tmp7.w = (uniforms.f[93].yyyy).w; + reg_tmp10.x = dot_s(uniforms.f[0], reg_tmp7); + reg_tmp10.y = dot_s(uniforms.f[1], reg_tmp7); + reg_tmp10.z = dot_s(uniforms.f[2], reg_tmp7); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_27() { + reg_tmp1.y = (uniforms.f[9].zzzz + reg_tmp1.yyyy).y; + return false; +} +bool sub_28() { + address_registers.xy = ivec2(uniforms.f[93].xx); + reg_tmp10.x = dot_s(uniforms.f[25], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[26], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[27], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + return false; +} +bool sub_29() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + { + sub_8(); + } + return false; +} +bool sub_30() { + if (all(conditional_code)) { + sub_31(); + } else { + sub_32(); + } + return false; +} +bool sub_31() { + reg_tmp12.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp12.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp12.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp14.xyz); + reg_tmp11.x = dot_3(uniforms.f[25 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp11.y = dot_3(uniforms.f[26 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp11.z = dot_3(uniforms.f[27 + address_registers.y].xyz, reg_tmp13.xyz); + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp14.x = dot_3(uniforms.f[3].xyz, reg_tmp12.xyz); + reg_tmp14.y = dot_3(uniforms.f[4].xyz, reg_tmp12.xyz); + reg_tmp14.z = dot_3(uniforms.f[5].xyz, reg_tmp12.xyz); + reg_tmp13.x = dot_3(uniforms.f[3].xyz, reg_tmp11.xyz); + reg_tmp13.y = dot_3(uniforms.f[4].xyz, reg_tmp11.xyz); + reg_tmp13.z = dot_3(uniforms.f[5].xyz, reg_tmp11.xyz); + { + sub_13(); + } + return false; +} +bool sub_32() { + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + vs_out_attr1 = uniforms.f[93].xxxx; + return false; +} +bool sub_8() { + uint jmp_to = 211u; + while (true) { + switch (jmp_to) { + case 211u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 227u; break; } + } + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (conditional_code.x) { + { jmp_to = 227u; break; } + } + reg_tmp0.z = rcp_s(reg_tmp4.x); + reg_tmp0.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + } + case 227u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_13() { + uint jmp_to = 228u; + while (true) { + switch (jmp_to) { + case 228u: { + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp7.x = dot_3(reg_tmp12.xyz, reg_tmp12.xyz); + reg_tmp6.x = rsq_s(reg_tmp6.x); + reg_tmp7.x = rsq_s(reg_tmp7.x); + reg_tmp14.xyz = (mul_s(reg_tmp14.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp12.xyz = (mul_s(reg_tmp12.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp0 = uniforms.f[93].yxxx; + if (!uniforms.b[15]) { + { jmp_to = 303u; break; } + } + reg_tmp13.xyz = (mul_s(reg_tmp13.xyzz, reg_tmp6.xxxx)).xyz; + reg_tmp11.xyz = (mul_s(reg_tmp11.xyzz, reg_tmp7.xxxx)).xyz; + reg_tmp5 = mul_s(reg_tmp14.yzxx, reg_tmp13.zxyy); + reg_tmp5 = fma_s(-reg_tmp13.yzxx, reg_tmp14.zxyy, reg_tmp5); + reg_tmp5.w = dot_3(reg_tmp5.xyz, reg_tmp5.xyz); + reg_tmp5.w = rsq_s(reg_tmp5.w); + reg_tmp5 = mul_s(reg_tmp5, reg_tmp5.wwww); + reg_tmp6.w = (reg_tmp14.zzzz + reg_tmp5.yyyy).w; + reg_tmp13 = mul_s(reg_tmp5.yzxx, reg_tmp14.zxyy); + reg_tmp13 = fma_s(-reg_tmp14.yzxx, reg_tmp5.zxyy, reg_tmp13); + reg_tmp6.w = (reg_tmp13.xxxx + reg_tmp6).w; + reg_tmp13.w = (reg_tmp5.zzzz).w; + reg_tmp5.z = (reg_tmp13.xxxx).z; + reg_tmp6.w = (uniforms.f[93].yyyy + reg_tmp6).w; + reg_tmp14.w = (reg_tmp5.xxxx).w; + reg_tmp5.x = (reg_tmp14.zzzz).x; + conditional_code = lessThan(uniforms.f[94].yy, reg_tmp6.ww); + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp6.y = (-uniforms.f[93].yyyy).y; + if (!conditional_code.x) { + { jmp_to = 265u; break; } + } + reg_tmp7.xz = (reg_tmp13.wwyy + -reg_tmp14.yyww).xz; + reg_tmp7.y = (reg_tmp14.xxxx + -reg_tmp13.zzzz).y; + reg_tmp7.w = (reg_tmp6).w; + reg_tmp6 = vec4(dot_s(reg_tmp7, reg_tmp7)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp7, reg_tmp6); + if (uniforms.b[0]) { + { jmp_to = 303u; break; } + } + } + case 265u: { + conditional_code = greaterThan(reg_tmp5.zy, reg_tmp5.yx); + if (conditional_code.x) { + sub_14(); + } else { + sub_19(); + } + reg_tmp6 = vec4(dot_s(reg_tmp8, reg_tmp8)); + reg_tmp6 = vec4(rsq_s(reg_tmp6.x)); + reg_tmp0 = mul_s(reg_tmp8, reg_tmp6); + } + case 303u: { + vs_out_attr1 = reg_tmp0; + } + default: return false; + } + } + return false; +} +bool sub_14() { + if (conditional_code.y) { + sub_15(); + } else { + sub_16(); + } + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_15() { + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_16() { + conditional_code = greaterThan(reg_tmp5.zz, reg_tmp5.xx); + reg_tmp8 = mul_s(reg_tmp13.yyzw, reg_tmp6.xxxy); + reg_tmp8.x = (uniforms.f[93].yyyy + -reg_tmp5.yyyy).x; + if (conditional_code.x) { + sub_17(); + } else { + sub_18(); + } + return false; +} +bool sub_17() { + reg_tmp9 = reg_tmp5.zzzz + -reg_tmp5.xxxx; + reg_tmp8.yzw = (reg_tmp8 + reg_tmp14.wwxy).yzw; + reg_tmp8.x = (reg_tmp9 + reg_tmp8).x; + return false; +} +bool sub_18() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + return false; +} +bool sub_19() { + if (conditional_code.y) { + sub_20(); + } else { + sub_21(); + } + return false; +} +bool sub_20() { + reg_tmp8 = mul_s(reg_tmp13.yywz, reg_tmp6.xxxy); + reg_tmp8.y = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).y; + reg_tmp9 = reg_tmp5.yyyy + -reg_tmp5.xxxx; + reg_tmp8.xzw = (reg_tmp8 + reg_tmp14.wwyx).xzw; + reg_tmp8.y = (reg_tmp9 + reg_tmp8).y; + return false; +} +bool sub_21() { + reg_tmp8 = mul_s(reg_tmp13.zwwy, reg_tmp6.xxxy); + reg_tmp8.z = (uniforms.f[93].yyyy + -reg_tmp5.zzzz).z; + reg_tmp9 = reg_tmp5.xxxx + -reg_tmp5.yyyy; + reg_tmp8.xyw = (reg_tmp8 + reg_tmp14.xyyw).xyw; + reg_tmp8.z = (reg_tmp9 + reg_tmp8).z; + reg_tmp8.w = (-reg_tmp8).w; + return false; +} +bool sub_33() { + reg_tmp8.xy = (uniforms.f[93].xxxx).xy; + reg_tmp0.y = (uniforms.f[7].wwww).y; + conditional_code = notEqual(uniforms.f[93].xx, reg_tmp0.xy); + reg_tmp9.xyz = (uniforms.f[93].xxxx).xyz; + reg_tmp9.w = (uniforms.f[21].wwww).w; + if (conditional_code.y) { + sub_34(); + } + if (uniforms.b[12]) { + sub_36(); + } + if (uniforms.b[5]) { + sub_45(); + } + conditional_code = equal(uniforms.f[93].xx, reg_tmp8.xy); + if (all(conditional_code)) { + sub_47(); + } + vs_out_attr3 = max(uniforms.f[93].xxxx, reg_tmp9); + return false; +} +bool sub_34() { + reg_tmp0 = mul_s(uniforms.f[7].wwww, vs_in_reg3); + if (uniforms.b[7]) { + sub_35(); + } + reg_tmp9.xyz = (mul_s(uniforms.f[20].wwww, reg_tmp0.xyzz)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_35() { + reg_tmp9.w = (mul_s(reg_tmp9.wwww, reg_tmp0.wwww)).w; + return false; +} +bool sub_47() { + reg_tmp9 = uniforms.f[21]; + return false; +} +bool sub_36() { + reg_tmp1 = uniforms.f[20]; + reg_tmp2 = uniforms.f[21]; + reg_tmp3 = uniforms.f[93].xxxx; + address_registers.z = int(uniforms.i[0].y); + for (uint loop324 = 0u; loop324 <= uniforms.i[0].x; address_registers.z += int(uniforms.i[0].z), ++loop324) { + sub_37(); + } + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_37() { + address_registers.x = (ivec2(reg_tmp3.xy)).x; + reg_tmp4.x = (uniforms.f[81 + address_registers.x].wwww).x; + reg_tmp4.y = (uniforms.f[83 + address_registers.x].wwww).y; + conditional_code = equal(uniforms.f[93].xy, reg_tmp4.xy); + if (conditional_code.x) { + sub_38(); + } else { + sub_39(); + } + conditional_code.x = uniforms.f[93].xxxx.x == reg_tmp6.xyyy.x; + conditional_code.y = uniforms.f[93].xxxx.y < reg_tmp6.xyyy.y; + if (conditional_code.y) { + sub_44(); + } + reg_tmp3 = -uniforms.f[95].wwww + reg_tmp3; + return false; +} +bool sub_38() { + reg_tmp6.x = dot_3(uniforms.f[81 + address_registers.x].xyz, reg_tmp14.xyz); + reg_tmp6.y = (uniforms.f[93].yyyy).y; + return false; +} +bool sub_39() { + reg_tmp4 = uniforms.f[81 + address_registers.x] + -reg_tmp15; + reg_tmp6.y = (uniforms.f[93].yyyy).y; + if (conditional_code.y) { + sub_40(); + } + reg_tmp5 = uniforms.f[82 + address_registers.x]; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.ww); + reg_tmp4.w = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp4.w = rsq_s(reg_tmp4.w); + reg_tmp4 = mul_s(reg_tmp4, reg_tmp4.wwww); + if (conditional_code.x) { + sub_41(); + } + reg_tmp6.x = dot_3(reg_tmp14.xyz, reg_tmp4.xyz); + return false; +} +bool sub_40() { + reg_tmp5.x = (uniforms.f[93].yyyy).x; + reg_tmp5.z = dot_3(reg_tmp4.xyz, reg_tmp4.xyz); + reg_tmp5.y = (mul_s(reg_tmp5.zzzz, reg_tmp5.zzzz)).y; + reg_tmp6.y = dot_3(uniforms.f[83 + address_registers.x].xyz, reg_tmp5.xyz); + reg_tmp6.y = rcp_s(reg_tmp6.y); + return false; +} +bool sub_41() { + reg_tmp5.x = dot_3(uniforms.f[82 + address_registers.x].xyz, -reg_tmp4.xyz); + reg_tmp5.y = (vec4(lessThan(reg_tmp5.xxxx, uniforms.f[84 + address_registers.x].yyyy))).y; + conditional_code = equal(uniforms.f[93].yy, reg_tmp5.xy); + if (conditional_code.y) { + sub_42(); + } else { + sub_43(); + } + reg_tmp6.y = (mul_s(reg_tmp6.yyyy, reg_tmp5.xxxx)).y; + return false; +} +bool sub_42() { + reg_tmp5.x = (uniforms.f[93].xxxx).x; + return false; +} +bool sub_43() { + reg_tmp5.y = log2(reg_tmp5.x); + reg_tmp5.y = (mul_s(uniforms.f[84 + address_registers.x].xxxx, reg_tmp5.yyyy)).y; + reg_tmp5.x = exp2(reg_tmp5.y); + return false; +} +bool sub_44() { + reg_tmp6.x = (max(uniforms.f[93].xxxx, reg_tmp6.xxxx)).x; + reg_tmp9.xyz = (fma_s(reg_tmp1.xyzz, uniforms.f[79 + address_registers.x].xyzz, reg_tmp9.xyzz)).xyz; + reg_tmp4 = mul_s(uniforms.f[80 + address_registers.x], reg_tmp2); + reg_tmp5.xyz = (mul_s(reg_tmp6.xxxx, reg_tmp4.xyzz)).xyz; + reg_tmp5.xyz = (mul_s(reg_tmp6.yyyy, reg_tmp5.xyzz)).xyz; + reg_tmp9.xyz = (reg_tmp9.xyzz + reg_tmp5.xyzz).xyz; + reg_tmp9.w = (reg_tmp9.wwww + reg_tmp4.wwww).w; + return false; +} +bool sub_45() { + reg_tmp1 = vec4(dot_3(uniforms.f[24].xyz, reg_tmp14.xyz)); + reg_tmp2 = uniforms.f[24].wwww; + reg_tmp1 = fma_s(reg_tmp1, reg_tmp2, reg_tmp2); + reg_tmp3 = uniforms.f[22]; + reg_tmp2 = uniforms.f[23] + -reg_tmp3; + reg_tmp4 = fma_s(reg_tmp2, reg_tmp1, reg_tmp3); + if (uniforms.b[6]) { + sub_46(); + } + reg_tmp9.xyz = (fma_s(reg_tmp4, uniforms.f[21], reg_tmp9)).xyz; + reg_tmp8.x = (uniforms.f[93].yyyy).x; + return false; +} +bool sub_46() { + reg_tmp4 = mul_s(reg_tmp4, reg_tmp9.wwww); + return false; +} +bool sub_48() { + reg_tmp0.xy = (uniforms.f[10].xxxx).xy; + if (uniforms.b[9]) { + sub_49(); + } else { + sub_55(); + } + return false; +} +bool sub_49() { + { + sub_50(); + } + reg_tmp3.x = dot_s(uniforms.f[11].xywz, reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12].xywz, reg_tmp6); + reg_tmp3.zw = (uniforms.f[93].xxxx).zw; + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_55() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + if (all(not(conditional_code))) { + sub_56(); + } else { + sub_57(); + } + vs_out_attr4 = reg_tmp3; + return false; +} +bool sub_56() { + reg_tmp6 = reg_tmp10; + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + reg_tmp3.z = dot_s(uniforms.f[13], reg_tmp6); + reg_tmp0.xy = (mul_s(uniforms.f[19].xyyy, reg_tmp3.zzzz)).xy; + reg_tmp3.xy = (reg_tmp3.xyyy + reg_tmp0.xyyy).xy; + return false; +} +bool sub_57() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_58(); + } else { + sub_60(); + } + return false; +} +bool sub_58() { + { + sub_59(); + } + reg_tmp3.x = dot_3(uniforms.f[11].xyz, reg_tmp6.xyz); + reg_tmp3.y = dot_3(uniforms.f[12].xyz, reg_tmp6.xyz); + reg_tmp3.z = dot_3(uniforms.f[13].xyz, reg_tmp6.xyz); + return false; +} +bool sub_60() { + { + sub_61(); + } + reg_tmp3.x = dot_s(uniforms.f[11], reg_tmp6); + reg_tmp3.y = dot_s(uniforms.f[12], reg_tmp6); + return false; +} +bool sub_50() { + conditional_code = equal(uniforms.f[93].yz, reg_tmp0.xy); + if (all(not(conditional_code))) { + sub_51(); + } else { + sub_52(); + } + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_51() { + reg_tmp6.xy = (mul_s(uniforms.f[8].xxxx, vs_in_reg4.xyyy)).xy; + return false; +} +bool sub_52() { + if (all(bvec2(conditional_code.x, !conditional_code.y))) { + sub_53(); + } else { + sub_54(); + } + return false; +} +bool sub_53() { + reg_tmp6.xy = (mul_s(uniforms.f[8].yyyy, vs_in_reg5.xyyy)).xy; + return false; +} +bool sub_54() { + reg_tmp6.xy = (mul_s(uniforms.f[8].zzzz, vs_in_reg6.xyyy)).xy; + return false; +} +bool sub_59() { + reg_tmp2 = -reg_tmp15; + reg_tmp2.w = dot_3(reg_tmp2.xyz, reg_tmp2.xyz); + reg_tmp2.w = rsq_s(reg_tmp2.w); + reg_tmp2 = mul_s(reg_tmp2, reg_tmp2.wwww); + reg_tmp1 = vec4(dot_3(reg_tmp2.xyz, reg_tmp14.xyz)); + reg_tmp1 = reg_tmp1 + reg_tmp1; + reg_tmp6 = fma_s(reg_tmp1, reg_tmp14, -reg_tmp2); + return false; +} +bool sub_61() { + reg_tmp1.xy = (uniforms.f[94].zzzz).xy; + reg_tmp1.zw = (uniforms.f[93].xxxx).zw; + reg_tmp6 = fma_s(reg_tmp14, reg_tmp1, reg_tmp1); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + return false; +} +bool sub_62() { + reg_tmp0.xy = (uniforms.f[10].yyyy).xy; + if (uniforms.b[10]) { + sub_63(); + } else { + sub_64(); + } + return false; +} +bool sub_63() { + { + sub_50(); + } + reg_tmp4.x = dot_s(uniforms.f[14].xywz, reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15].xywz, reg_tmp6); + reg_tmp4.zw = (reg_tmp6.zwww).zw; + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_64() { + if (uniforms.b[13]) { + sub_65(); + } else { + sub_68(); + } + return false; +} +bool sub_65() { + conditional_code = equal(uniforms.f[95].xy, reg_tmp0.xy); + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp4.zw = (reg_tmp6.zwww).zw; + if (all(not(conditional_code))) { + sub_66(); + } else { + sub_67(); + } + vs_out_attr5 = reg_tmp4; + return false; +} +bool sub_66() { + reg_tmp6 = reg_tmp10; + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + reg_tmp4.z = dot_s(uniforms.f[16], reg_tmp6); + reg_tmp6.w = rcp_s(reg_tmp4.z); + reg_tmp4.xy = (mul_s(reg_tmp4.xyyy, reg_tmp6.wwww)).xy; + reg_tmp4.xy = (uniforms.f[19].zwww + reg_tmp4.xyyy).xy; + return false; +} +bool sub_67() { + { + sub_61(); + } + reg_tmp4.x = dot_s(uniforms.f[14], reg_tmp6); + reg_tmp4.y = dot_s(uniforms.f[15], reg_tmp6); + return false; +} +bool sub_68() { + vs_out_attr5 = uniforms.f[93].xxxx; + return false; +} +bool sub_69() { + reg_tmp0.xy = (uniforms.f[10].zzzz).xy; + if (uniforms.b[11]) { + sub_70(); + } else { + sub_71(); + } + return false; +} +bool sub_70() { + { + sub_50(); + } + reg_tmp5.x = dot_s(uniforms.f[17].xywz, reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18].xywz, reg_tmp6); + reg_tmp5.zw = (reg_tmp6.zwww).zw; + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_71() { + if (uniforms.b[14]) { + sub_72(); + } else { + sub_73(); + } + return false; +} +bool sub_72() { + reg_tmp6.zw = (uniforms.f[93].xxyy).zw; + reg_tmp5.zw = (reg_tmp6.zwww).zw; + { + sub_61(); + } + reg_tmp5.x = dot_s(uniforms.f[17], reg_tmp6); + reg_tmp5.y = dot_s(uniforms.f[18], reg_tmp6); + vs_out_attr6 = reg_tmp5; + return false; +} +bool sub_73() { + vs_out_attr6 = uniforms.f[93].xxxx; + return false; +} +// reference: 4C1D534FDB2D8FA7, 2ADB5861BD9769B7 +// shader: 8DD9, 0D30074279C2FEED + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +struct Vertex { + vec4 attributes[7]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = vtx.attributes[4].z; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(vtx.attributes[6].x, vtx.attributes[6].y); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[7](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0], vs_out_attr4[0], vs_out_attr5[0], vs_out_attr6[0]); + prim_buffer[1].attributes = vec4[7](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1], vs_out_attr4[1], vs_out_attr5[1], vs_out_attr6[1]); + prim_buffer[2].attributes = vec4[7](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2], vs_out_attr4[2], vs_out_attr5[2], vs_out_attr6[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: FC74FA4ACA1C8C74, 0D30074279C2FEED +// shader: 8B30, E669BC8EBBE76C55 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (rounded_primary_color.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0C5E54FAEAC20A28, E669BC8EBBE76C55 +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, E669BC8EBBE76C55 +// shader: 8B31, 11C050FC6CB4D5AA + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_1() { + reg_tmp11.x = dot_s(uniforms.f[7], vs_in_reg0); + reg_tmp11.y = dot_s(uniforms.f[8], vs_in_reg0); + reg_tmp11.z = dot_s(uniforms.f[9], vs_in_reg0); + reg_tmp11.w = (uniforms.f[93].yyyy).w; + reg_tmp13.x = dot_s(uniforms.f[4], reg_tmp11); + reg_tmp13.y = dot_s(uniforms.f[5], reg_tmp11); + reg_tmp13.z = dot_s(uniforms.f[6], reg_tmp11); + reg_tmp13.w = (uniforms.f[93].yyyy).w; + vs_out_attr2 = -reg_tmp13; + reg_tmp14.x = dot_3(uniforms.f[10].xyz, vs_in_reg1.xyz); + reg_tmp14.y = dot_3(uniforms.f[11].xyz, vs_in_reg1.xyz); + reg_tmp14.z = dot_3(uniforms.f[12].xyz, vs_in_reg1.xyz); + vs_out_attr0.x = dot_s(uniforms.f[0], reg_tmp13); + vs_out_attr0.y = dot_s(uniforms.f[1], reg_tmp13); + vs_out_attr0.z = dot_s(uniforms.f[2], reg_tmp13); + vs_out_attr0.w = dot_s(uniforms.f[3], reg_tmp13); + reg_tmp3.x = dot_3(reg_tmp14.xyz, reg_tmp14.xyz); + reg_tmp3.x = rsq_s(reg_tmp3.x); + reg_tmp14 = mul_s(reg_tmp14, reg_tmp3.xxxx); + reg_tmp4 = uniforms.f[93].yyyy + reg_tmp14.zzzz; + reg_tmp4 = mul_s(uniforms.f[94].zzzz, reg_tmp4); + conditional_code = greaterThanEqual(uniforms.f[93].xx, reg_tmp4.xx); + vs_out_attr1.w = (uniforms.f[93].xxxx).w; + reg_tmp4 = vec4(rsq_s(reg_tmp4.x)); + reg_tmp5 = mul_s(uniforms.f[94].zzzz, reg_tmp14); + if (!conditional_code.x) { + sub_2(); + } else { + sub_3(); + } + return false; +} +bool sub_2() { + vs_out_attr1.z = rcp_s(reg_tmp4.x); + vs_out_attr1.xy = (mul_s(reg_tmp5, reg_tmp4)).xy; + return false; +} +bool sub_3() { + vs_out_attr1.xyz = (uniforms.f[93].yxxx).xyz; + return false; +} +bool sub_0() { + { + sub_1(); + } + reg_tmp15.x = dot_s(uniforms.f[13], vs_in_reg2); + reg_tmp15.y = dot_s(uniforms.f[14], vs_in_reg2); + vs_out_attr3 = reg_tmp15.xyxy; + return true; +} +// reference: E35D53F6DC4A4A4E, 11C050FC6CB4D5AA +// shader: 8DD9, 0CB5B5B0F7196203 + +layout(triangles) in; +layout(triangle_strip, max_vertices = 3) out; + +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +struct Vertex { + vec4 attributes[4]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(0.0, 0.0, 0.0, 0.0); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[3].x, vtx.attributes[3].y); + texcoord1 = vec2(vtx.attributes[3].z, vtx.attributes[3].w); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +void main() { + Vertex prim_buffer[3]; + prim_buffer[0].attributes = vec4[4](vs_out_attr0[0], vs_out_attr1[0], vs_out_attr2[0], vs_out_attr3[0]); + prim_buffer[1].attributes = vec4[4](vs_out_attr0[1], vs_out_attr1[1], vs_out_attr2[1], vs_out_attr3[1]); + prim_buffer[2].attributes = vec4[4](vs_out_attr0[2], vs_out_attr1[2], vs_out_attr2[2], vs_out_attr3[2]); + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); +} +// reference: 1EA377C1D7B39071, 0CB5B5B0F7196203 +// shader: 8B30, 5E789D7BDB4BCB0A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8ECA464F0231BF33, 5E789D7BDB4BCB0A +// program: 11C050FC6CB4D5AA, 0CB5B5B0F7196203, 5E789D7BDB4BCB0A +// shader: 8B30, DA7BE12D15EF0882 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = vec3(0.0, 0.0, 1.0); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8ECA464FAAD46DE3, DA7BE12D15EF0882 +// program: 11C050FC6CB4D5AA, 0CB5B5B0F7196203, DA7BE12D15EF0882 +// shader: 8B30, F0169B6CE270E875 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 72E65B0A933100AB, F0169B6CE270E875 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F0169B6CE270E875 +// shader: 8B30, FAFA4C36CAA49E97 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BD7EBFF512CE1611, FAFA4C36CAA49E97 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FAFA4C36CAA49E97 +// shader: 8B30, F7455A543EEB5D4C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].aaa) * (last_tex_env_out.rgb) + (const_color[3].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (rounded_primary_color.rgb) + (const_color[4].rgb) * (vec3(1.0) - (rounded_primary_color.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4C5817601B02A4BE, F7455A543EEB5D4C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F7455A543EEB5D4C +// shader: 8B30, A5595B48E81B170F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3CD46DFB80C9EF3, A5595B48E81B170F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, A5595B48E81B170F +// shader: 8B30, AFD20F4A1268CCB8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 7C55A22039F38849, AFD20F4A1268CCB8 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, AFD20F4A1268CCB8 +// shader: 8B30, 65FC5DE37303C8FD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (last_tex_env_out.rgb) + (const_color[4].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 18ABDD28B761DF72, 65FC5DE37303C8FD +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 65FC5DE37303C8FD +// shader: 8B30, 88C2297A7BBDD605 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3CD46DFD41D8BD6, 88C2297A7BBDD605 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 88C2297A7BBDD605 +// shader: 8B30, 534DED0A2BA353EA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 133E2C71730914AD, 534DED0A2BA353EA +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 534DED0A2BA353EA +// shader: 8B30, 19E84E01798EDB01 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9D9AD8077358CDAB, 19E84E01798EDB01 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 19E84E01798EDB01 +// shader: 8B30, 516974E70095088C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52023CF8F2A7DB11, 516974E70095088C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 516974E70095088C +// shader: 8B30, 366536DAB9D37B59 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor2.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 133E2C7129C5B508, 366536DAB9D37B59 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 366536DAB9D37B59 +// shader: 8B30, CE7474C69094206F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (texcolor1.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) + (const_color[5].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) == alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0B10048870630A42, CE7474C69094206F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, CE7474C69094206F +// shader: 8B30, 6D9040996A75F7C5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9D9AD8077A813661, 6D9040996A75F7C5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 6D9040996A75F7C5 +// shader: 8B30, DA6D4F40F367D492 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 52023CF8FB7E20DB, DA6D4F40F367D492 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, DA6D4F40F367D492 +// shader: 8B30, 3A0738775AF8B5EA +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((texcolor0.aaa) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.aaa) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) + (const_color[5].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4A41263353422252, 3A0738775AF8B5EA +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3A0738775AF8B5EA +// shader: 8B30, E68CF6BABF607A76 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B83EFB6B9F53B31A, E68CF6BABF607A76 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, E68CF6BABF607A76 +// shader: 8B30, B404B060228D2EE7 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 77A61F941EACA5A0, B404B060228D2EE7 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B404B060228D2EE7 +// shader: 8B30, 57286D0B56C87A60 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor2.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A18BA9E1DF1257DC, 57286D0B56C87A60 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 57286D0B56C87A60 +// shader: 8B30, 28660AE5C2E9264D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2F2F5D9788E0B0BD, 28660AE5C2E9264D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 28660AE5C2E9264D +// shader: 8B30, 60E73003BBF2F5C0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0B7B968091FA607, 60E73003BBF2F5C0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 60E73003BBF2F5C0 +// shader: 8B30, CCBF0FD1EDFD6DDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].aaa) * (last_tex_env_out.rgb) + (const_color[3].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (rounded_primary_color.rgb) + (const_color[4].rgb) * (vec3(1.0) - (rounded_primary_color.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A5285391D5973570, CCBF0FD1EDFD6DDB +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, CCBF0FD1EDFD6DDB +// shader: 8B30, B8E1748B0F535E68 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = byteround(clamp((texcolor0.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 5ABD022E76990F3D, B8E1748B0F535E68 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B8E1748B0F535E68 +// shader: 8B30, B19E10A87802A9AB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((secondary_fragment_color.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 07E3BEE908628E40, B19E10A87802A9AB +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, B19E10A87802A9AB +// shader: 8B30, 6336AB914B9CA562 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B3F9190892053736, 6336AB914B9CA562 +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, 6336AB914B9CA562 +// reference: 8ECA464F5A9F5885, 5E789D7BDB4BCB0A +// reference: 8ECA464FF27A8A55, DA7BE12D15EF0882 +// shader: 8B30, 7F0F0F4472FD8CF1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (last_tex_env_out.rgb) + (const_color[4].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D980C0FD64B23ED4, 7F0F0F4472FD8CF1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 7F0F0F4472FD8CF1 +// shader: 8B30, D0179ECD63BB70D3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 72E65B0A07CE6A70, D0179ECD63BB70D3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D0179ECD63BB70D3 +// reference: B382E5C3F31AC733, FC7F4467554D34E5 +// reference: 5EA8FCA1DB2D8FA7, 2ADB5861BD9769B7 +// reference: F1E8FC18DC4A4A4E, 11C050FC6CB4D5AA +// shader: 8B30, 56586C4E81AD9DF0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (last_tex_env_out.rgb) + (const_color[4].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 4BD1229FDDC2EE34, 56586C4E81AD9DF0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 56586C4E81AD9DF0 +// shader: 8B30, B0B720E1B3E4B028 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0B7B968BEBEBA90, B0B720E1B3E4B028 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B0B720E1B3E4B028 +// shader: 8B30, 57286D0B7F58A005 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A18BA9E17C18DC5C, 57286D0B7F58A005 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 57286D0B7F58A005 +// shader: 8B30, 28660AE57AFA48A3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2F2F5D977C49055A, 28660AE57AFA48A3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 28660AE57AFA48A3 +// shader: 8B30, 60E7300303E19B2E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0B7B968FDB613E0, 60E7300303E19B2E +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 60E7300303E19B2E +// shader: 8B30, 4D2ACE10D8E06AD6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor2.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A18BA9E126D47DF9, 4D2ACE10D8E06AD6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4D2ACE10D8E06AD6 +// shader: 8B30, B0FAFCE5C91C0957 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (texcolor1.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) + (const_color[5].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) == alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: B9A581187F72C2B3, B0FAFCE5C91C0957 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B0FAFCE5C91C0957 +// shader: 8B30, 342706688A5B19D5 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2F2F5D977590FE90, 342706688A5B19D5 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 342706688A5B19D5 +// shader: 8B30, 7CF5C10FE78D430B +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (rounded_primary_color.rgb); +float alpha_output_0 = byteround(clamp(min((texcolor2.a) + (texcolor0.a), 1.0) * (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: E0B7B968F46FE82A, 7CF5C10FE78D430B +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 7CF5C10FE78D430B +// shader: 8B30, ADDC7B5CA0382F99 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp(min((const_color[0].a) + (const_color[0].a), 1.0) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (1.0 - last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A025E53CBF4B4934, ADDC7B5CA0382F99 +// program: 0000000000000000, 0000000000000000, ADDC7B5CA0382F99 +// shader: 8B30, 828B17C8889F4FA8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 393F874199613147, 828B17C8889F4FA8 +// program: 0000000000000000, 0000000000000000, 828B17C8889F4FA8 +// shader: 8B30, EE9D59D3D057292A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 393F874179A7B68F, EE9D59D3D057292A +// program: 0000000000000000, 0000000000000000, EE9D59D3D057292A +// shader: 8B30, F789075555A6DC0C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rrr) * (const_color[0].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((texcolor0.ggg) * (const_color[1].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((texcolor0.bbb) * (const_color[2].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D7DF573C1FE16FD0, F789075555A6DC0C +// program: 0000000000000000, 0000000000000000, F789075555A6DC0C +// shader: 8B30, B35EFE43E319BB63 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = (const_color[0].a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 393F8741C615FEE5, B35EFE43E319BB63 +// program: 0000000000000000, 0000000000000000, B35EFE43E319BB63 +// shader: 8B30, DC12E218392F9BDB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 393F87418247C736, DC12E218392F9BDB +// program: 0000000000000000, 0000000000000000, DC12E218392F9BDB +// reference: BFBC03585FBF2C3C, 11C050FC6CB4D5AA +// shader: 8B30, B4A64D0795650622 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: EEBC7DE98D3A4204, B4A64D0795650622 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, B4A64D0795650622 +// shader: 8B30, 8AF3A0ABE75F9B3D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 72E65B0ADDC989B1, 8AF3A0ABE75F9B3D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 8AF3A0ABE75F9B3D +// shader: 8B30, 4DFACA5C31333609 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BD7EBFF586317CCA, 4DFACA5C31333609 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4DFACA5C31333609 +// shader: 8B30, 861D5E5624294BF2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[3].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 087F26714C85D1A6, 861D5E5624294BF2 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 861D5E5624294BF2 +// shader: 8B30, 824A96ABB3866DAC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A5906F736B9D458A, 824A96ABB3866DAC +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 824A96ABB3866DAC +// shader: 8B30, 91705D91B23B3FE2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A5906F732565CC90, 91705D91B23B3FE2 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 91705D91B23B3FE2 +// shader: 8B30, D0C2D0712E6B393D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6A088B8CEA625330, D0C2D0712E6B393D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, D0C2D0712E6B393D +// shader: 8B30, ED97ED72B6BF3C00 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (texcolor0.rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 175B3EC84A4D24FB, ED97ED72B6BF3C00 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, ED97ED72B6BF3C00 +// shader: 8B30, EB55EE05EC4BDD70 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6A088B8C3356DAA5, EB55EE05EC4BDD70 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, EB55EE05EC4BDD70 +// shader: 8B30, 5DE4933E58A6E48F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A5906F73B2A9CC1F, 5DE4933E58A6E48F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 5DE4933E58A6E48F +// shader: 8B30, DF34BF806BC5EFE6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = (texcolor0.a); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[1].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A5906F73FC514505, DF34BF806BC5EFE6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, DF34BF806BC5EFE6 +// reference: 10FC03E158D8E9D5, 2ADB5861BD9769B7 +// shader: 8B30, 48DB8E77D28262AC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); + +vec4 diffuse_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec4 specular_sum = vec4(0.0, 0.0, 0.0, 1.0); +vec3 light_vector = vec3(0.0); +vec3 refl_value = vec3(0.0); +vec3 spot_dir = vec3(0.0); +vec3 half_vector = vec3(0.0); +float dot_product = 0.0; +float clamp_highlights = 1.0; +float geo_factor = 1.0; +vec3 surface_normal = 2.0 * (texcolor1).rgb - 1.0; +surface_normal.z = sqrt(max((1.0 - (surface_normal.x*surface_normal.x + surface_normal.y*surface_normal.y)), 0.0)); +vec3 surface_tangent = vec3(1.0, 0.0, 0.0); +vec4 normalized_normquat = normalize(normquat); +vec3 normal = quaternion_rotate(normalized_normquat, surface_normal); +vec3 tangent = quaternion_rotate(normalized_normquat, surface_tangent); +vec4 shadow = vec4(1.0); +light_vector = normalize(light_src[0].position); +spot_dir = light_src[0].spot_direction; +half_vector = normalize(view) + light_vector; +dot_product = max(dot(light_vector, normal), 0.0); +refl_value.r = 1.0; +refl_value.g = refl_value.r; +refl_value.b = refl_value.r; +diffuse_sum.rgb += ((light_src[0].diffuse * dot_product) + light_src[0].ambient) * 1.0; +specular_sum.rgb += (((lut_scale_d0 * LookupLightingLUTUnsigned(0, max(dot(normal, normalize(half_vector)), 0.0))) * light_src[0].specular_0) + (light_src[0].specular_1)) * clamp_highlights * 1.0; +diffuse_sum.rgb += lighting_global_ambient; +primary_fragment_color = clamp(diffuse_sum, vec4(0.0), vec4(1.0)); +secondary_fragment_color = clamp(specular_sum, vec4(0.0), vec4(1.0)); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[1].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((vec3(1.0) - primary_fragment_color.rgb) * (const_color[2].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - last_tex_env_out.rgb) * (combiner_buffer.rgb) + (secondary_fragment_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb) + (const_color[4].rgb) * (vec3(1.0) - (rounded_primary_color.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D3B98F0A1FC29BCC, 48DB8E77D28262AC +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, 48DB8E77D28262AC +// shader: 8B30, 7C4022F449D50355 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = byteround(clamp((texcolor0.rgb) * (vec3(1.0) - rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (combiner_buffer.rgb) + (const_color[2].rgb) * (vec3(1.0) - (combiner_buffer.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb) + (const_color[3].rgb) * (vec3(1.0) - (rounded_primary_color.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 6AED7EC209FBFA08, 7C4022F449D50355 +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, 7C4022F449D50355 +// shader: 8B30, C177EDF23A5BAC37 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) <= alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 778DD386A2E1352B, C177EDF23A5BAC37 +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, C177EDF23A5BAC37 +// shader: 8B30, 1A48563EE40699E2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 778DD3864E56DE28, 1A48563EE40699E2 +// program: 2ADB5861BD9769B7, 0D30074279C2FEED, 1A48563EE40699E2 +// shader: 8B30, 056C410B097A43B3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508A7ABA43A2, 056C410B097A43B3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 056C410B097A43B3 +// shader: 8B30, F5AE26271A408889 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508A3442CAB8, F5AE26271A408889 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F5AE26271A408889 +// shader: 8B30, 15586A7B4B24FD5A +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CEFFB475FB455518, 15586A7B4B24FD5A +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 15586A7B4B24FD5A +// shader: 8B30, 81282BFD35AAB889 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (last_tex_env_out.rgb) + (const_color[4].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: AA01CB7DAAD16F99, 81282BFD35AAB889 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 81282BFD35AAB889 +// shader: 8B30, BA5F925B658D244F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 0167508AC9AD3B3D, BA5F925B658D244F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, BA5F925B658D244F +// shader: 8B30, C34441D62D0C1EA9 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CEFFB47548522D87, C34441D62D0C1EA9 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C34441D62D0C1EA9 +// shader: 8B30, 8A982AF524F410E0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[3].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 668A080E681A1FB5, 8A982AF524F410E0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 8A982AF524F410E0 +// shader: 8B30, 8FEDD56EF2BBD188 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410C4F028B99, 8FEDD56EF2BBD188 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 8FEDD56EF2BBD188 +// shader: 8B30, 81B61685706BFD36 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410C01FA0283, 81B61685706BFD36 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 81B61685706BFD36 +// shader: 8B30, DB22EE597B668C7F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F3CEFD9D23, DB22EE597B668C7F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, DB22EE597B668C7F +// shader: 8B30, 73F67A8D81DA6FAD +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (texcolor0.rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 79AE10B76ED2EAE8, 73F67A8D81DA6FAD +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 73F67A8D81DA6FAD +// shader: 8B30, FCAC831851EB5EB3 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F317C914B6, FCAC831851EB5EB3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FCAC831851EB5EB3 +// shader: 8B30, EDD5A12AA4F9DC40 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410C9636020C, EDD5A12AA4F9DC40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, EDD5A12AA4F9DC40 +// shader: 8B30, 42EFF074B096B3A6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410CD8CE8B16, 42EFF074B096B3A6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 42EFF074B096B3A6 +// shader: 8B30, 436B12C29C089B40 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) * (const_color[3].aaa) + (texcolor1.rgb) * (vec3(1.0) - (const_color[3].aaa)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (last_tex_env_out.rgb) + (combiner_buffer.rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (rounded_primary_color.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (texcolor2.r), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: A74F64CC17F544C5, 436B12C29C089B40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 436B12C29C089B40 +// shader: 8B30, 04E95F5C3256E3FF +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F37ACEA24C, 04E95F5C3256E3FF +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 04E95F5C3256E3FF +// shader: 8B30, 547E771FC720FA85 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9D3D7669F59E8351, 547E771FC720FA85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 547E771FC720FA85 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FCAC831851EB5EB3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, EDD5A12AA4F9DC40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 42EFF074B096B3A6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 436B12C29C089B40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 04E95F5C3256E3FF +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FCAC831851EB5EB3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, EDD5A12AA4F9DC40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 42EFF074B096B3A6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 436B12C29C089B40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 04E95F5C3256E3FF +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FCAC831851EB5EB3 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, EDD5A12AA4F9DC40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 42EFF074B096B3A6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 436B12C29C089B40 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 04E95F5C3256E3FF +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 547E771FC720FA85 +// shader: 8B30, 1271E264589097DB +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((const_color[0].a) * (const_color[0].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (last_tex_env_out.rgb); +float alpha_output_2 = byteround(clamp((last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (vec3(1.0) - last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((last_tex_env_out.a) * (1.0 - last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (last_tex_env_out.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (last_tex_env_out.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = (const_color[5].rgb); +float alpha_output_5 = (const_color[5].a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 8940A7ED4CE24A81, 1271E264589097DB +// program: 0000000000000000, 0000000000000000, 1271E264589097DB +// reference: D4F4BEF9AC24CD49, EE9D59D3D057292A +// reference: 3A146E84CA621416, F789075555A6DC0C +// reference: D4F4BEF913968523, B35EFE43E319BB63 +// reference: D4F4BEF957C4BCF0, DC12E218392F9BDB +// reference: D4F4BEF94CE24A81, 828B17C8889F4FA8 +// shader: 8B30, C033F297622D7D3F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[3].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 79AE10B7DC2920DA, C033F297622D7D3F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, C033F297622D7D3F +// shader: 8B30, 34050859E56E7D3C +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[3].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 2C3138E39DF39870, 34050859E56E7D3C +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 34050859E56E7D3C +// shader: 8B30, 49D4D85F5E590002 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F334362B56, 49D4D85F5E590002 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 49D4D85F5E590002 +// shader: 8B30, 1C2F1F9407CA64C8 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((texcolor1.rgb) * (const_color[5].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 79AE10B7879B4BF0, 1C2F1F9407CA64C8 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 1C2F1F9407CA64C8 +// shader: 8B30, 4EEF94FC3EEF3358 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410CFB31B4F6, 4EEF94FC3EEF3358 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 4EEF94FC3EEF3358 +// shader: 8B30, 03D213FF7F58A906 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CB65410CB5C93DEC, 03D213FF7F58A906 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 03D213FF7F58A906 +// shader: 8B30, 18D783B7F9B6A0C1 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (const_color[2].rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F380051439, 18D783B7F9B6A0C1 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 18D783B7F9B6A0C1 +// shader: 8B30, 3AC69EAFD047E177 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (texcolor0.rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = (texcolor0.rgb); +float alpha_output_2 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (const_color[5].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (const_color[5].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 04FDA5F359319DAC, 3AC69EAFD047E177 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 3AC69EAFD047E177 +// reference: 456A7DE6F31AC733, FC7F4467554D34E5 +// reference: A8406484DB2D8FA7, 2ADB5861BD9769B7 +// reference: BFBC0358DC4A4A4E, 11C050FC6CB4D5AA +// reference: FDD61A83F31AC733, FC7F4467554D34E5 +// reference: BAF5CB6ADB2D8FA7, 2ADB5861BD9769B7 +// reference: 15B5CBD3DC4A4A4E, 11C050FC6CB4D5AA +// shader: 8DD9, B326B1D273D9548B + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) +layout(points) in; +layout(triangle_strip, max_vertices = 30) out; +out vec4 primary_color; +out vec2 texcoord0; +out vec2 texcoord1; +out vec2 texcoord2; +out float texcoord0_w; +out vec4 normquat; +out vec3 view; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +in vec4 vs_out_attr0[]; +in vec4 vs_out_attr1[]; +in vec4 vs_out_attr2[]; +in vec4 vs_out_attr3[]; +in vec4 vs_out_attr4[]; +in vec4 vs_out_attr5[]; +in vec4 vs_out_attr6[]; +in vec4 vs_out_attr7[]; + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms gs_uniforms +layout (std140) uniform gs_config { + pica_uniforms uniforms; +}; +struct Vertex { + vec4 attributes[6]; +}; + +vec4 GetVertexQuaternion(Vertex vtx) { + return vec4(vtx.attributes[1].x, vtx.attributes[1].y, vtx.attributes[1].z, vtx.attributes[1].w); +} + +void EmitVtx(Vertex vtx, bool quats_opposite) { + vec4 vtx_pos = vec4(vtx.attributes[0].x, vtx.attributes[0].y, vtx.attributes[0].z, vtx.attributes[0].w); + gl_Position = vtx_pos; +#if !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + gl_ClipDistance[0] = -vtx_pos.z; + gl_ClipDistance[1] = dot(clip_coef, vtx_pos); +#endif // !defined(CITRA_GLES) || defined(GL_EXT_clip_cull_distance) + + vec4 vtx_quat = GetVertexQuaternion(vtx); + normquat = mix(vtx_quat, -vtx_quat, bvec4(quats_opposite)); + + vec4 vtx_color = vec4(vtx.attributes[3].x, vtx.attributes[3].y, vtx.attributes[3].z, vtx.attributes[3].w); + primary_color = min(abs(vtx_color), vec4(1.0)); + + texcoord0 = vec2(vtx.attributes[4].x, vtx.attributes[4].y); + texcoord1 = vec2(vtx.attributes[5].x, vtx.attributes[5].y); + + texcoord0_w = 0.0; + view = vec3(vtx.attributes[2].x, vtx.attributes[2].y, vtx.attributes[2].z); + texcoord2 = vec2(0.0, 0.0); + + EmitVertex(); +} + +bool AreQuaternionsOpposite(vec4 qa, vec4 qb) { + return (dot(qa, qb) < 0.0); +} + +void EmitPrim(Vertex vtx0, Vertex vtx1, Vertex vtx2) { + EmitVtx(vtx0, false); + EmitVtx(vtx1, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx1))); + EmitVtx(vtx2, AreQuaternionsOpposite(GetVertexQuaternion(vtx0), GetVertexQuaternion(vtx2))); + EndPrimitive(); +} + +Vertex output_buffer; +Vertex prim_buffer[3]; +uint vertex_id = 0u; +bool prim_emit = false; +bool winding = false; +void setemit(uint vertex_id_, bool prim_emit_, bool winding_); +void emit(); +void main() { + output_buffer.attributes[0] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[1] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[2] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[3] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[4] = vec4(0.0, 0.0, 0.0, 1.0); + output_buffer.attributes[5] = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} + +void setemit(uint vertex_id_, bool prim_emit_, bool winding_) { + vertex_id = vertex_id_; + prim_emit = prim_emit_; + winding = winding_; +} +void emit() { + prim_buffer[vertex_id] = output_buffer; + if (prim_emit) { + if (winding) { + EmitPrim(prim_buffer[1], prim_buffer[0], prim_buffer[2]); + winding = false; + } else { + EmitPrim(prim_buffer[0], prim_buffer[1], prim_buffer[2]); + } + } +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + vs_out_attr6[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].xyyy).xy; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].zwww).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(0u, false, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + -vs_out_attr7[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].xyyy).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(1u, false, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + vs_out_attr7[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + reg_tmp0 = vs_out_attr4[0]; + reg_tmp0.xy = (reg_tmp0.xyyy + vs_out_attr5[0].zwww).xy; + output_buffer.attributes[4] = reg_tmp0; + output_buffer.attributes[5] = reg_tmp0; + setemit(2u, true, false); + emit(); + reg_tmp0 = vs_out_attr0[0]; + reg_tmp0 = reg_tmp0 + -vs_out_attr6[0]; + output_buffer.attributes[0] = reg_tmp0; + output_buffer.attributes[1] = vs_out_attr1[0]; + output_buffer.attributes[2] = vs_out_attr2[0]; + output_buffer.attributes[3] = vs_out_attr3[0]; + output_buffer.attributes[4] = vs_out_attr4[0]; + output_buffer.attributes[5] = vs_out_attr4[0]; + setemit(0u, true, true); + emit(); + return true; +} +// reference: 5D026BBB2268FCFB, B326B1D273D9548B +// shader: 8B31, 59B04B6EAAAB8C6A + +#define mul_s(x, y) (x * y) +#define fma_s(x, y, z) fma(x, y, z) +#define rcp_s(x) (1.0 / x) +#define rsq_s(x) inversesqrt(x) +#define dot_s(x, y) dot(x, y) +#define dot_3(x, y) dot(x, y) + +struct pica_uniforms { + bool b[16]; + uvec4 i[4]; + vec4 f[96]; +}; + +bool exec_shader(); + +#define uniforms vs_uniforms +layout (std140) uniform vs_config { + pica_uniforms uniforms; +}; +layout(location = 0) in vec4 vs_in_reg0; +layout(location = 1) in vec4 vs_in_reg1; +layout(location = 2) in vec4 vs_in_reg2; +layout(location = 3) in vec4 vs_in_reg3; +layout(location = 4) in vec4 vs_in_reg4; +layout(location = 5) in vec4 vs_in_reg5; +layout(location = 6) in vec4 vs_in_reg6; +layout(location = 7) in vec4 vs_in_reg7; +layout(location = 8) in vec4 vs_in_reg8; + +out vec4 vs_out_attr0; +out vec4 vs_out_attr1; +out vec4 vs_out_attr2; +out vec4 vs_out_attr3; +out vec4 vs_out_attr4; +out vec4 vs_out_attr5; +out vec4 vs_out_attr6; +out vec4 vs_out_attr7; + +void main() { + vs_out_attr0 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr1 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr2 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr3 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr4 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr5 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr6 = vec4(0.0, 0.0, 0.0, 1.0); + vs_out_attr7 = vec4(0.0, 0.0, 0.0, 1.0); + exec_shader(); +} +bvec2 conditional_code = bvec2(false); +ivec3 address_registers = ivec3(0); +vec4 reg_tmp0 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp1 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp2 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp3 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp4 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp5 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp6 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp7 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp8 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp9 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp10 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp11 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp12 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp13 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp14 = vec4(0.0, 0.0, 0.0, 1.0); +vec4 reg_tmp15 = vec4(0.0, 0.0, 0.0, 1.0); + +bool sub_0(); +bool sub_1(); +bool sub_2(); +bool sub_3(); +bool sub_4(); +bool sub_5(); +bool sub_6(); +bool sub_7(); + +bool exec_shader() { + sub_0(); + return true; +} + +bool sub_0() { + reg_tmp0 = vs_in_reg2; + reg_tmp0 = uniforms.f[39] + reg_tmp0; + reg_tmp0 = mul_s(uniforms.f[84].xxxx, reg_tmp0); + reg_tmp1 = floor(reg_tmp0); + reg_tmp12 = reg_tmp0 + -reg_tmp1; + reg_tmp0 = vs_in_reg1; + reg_tmp0 = mul_s(reg_tmp0, vs_in_reg8); + reg_tmp13 = mul_s(uniforms.f[38], reg_tmp0); + if (uniforms.b[1]) { + sub_1(); + } + if (uniforms.b[3]) { + sub_2(); + } else { + sub_3(); + } + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp15.xyz = (uniforms.f[6] + vs_in_reg0).xyz; + reg_tmp10.x = dot_s(uniforms.f[34], reg_tmp15); + reg_tmp10.y = dot_s(uniforms.f[35], reg_tmp15); + reg_tmp10.z = dot_s(uniforms.f[36], reg_tmp15); + reg_tmp10.w = (uniforms.f[93].yyyy).w; + reg_tmp15.x = dot_s(uniforms.f[90], reg_tmp10); + reg_tmp15.y = dot_s(uniforms.f[91], reg_tmp10); + reg_tmp15.z = dot_s(uniforms.f[92], reg_tmp10); + reg_tmp15.w = (uniforms.f[93].yyyy).w; + reg_tmp0 = mul_s(uniforms.f[37].xxxx, reg_tmp6); + reg_tmp1 = mul_s(uniforms.f[37].yyyy, reg_tmp7); + reg_tmp15.xyz = (reg_tmp15 + -reg_tmp0).xyz; + reg_tmp15.xyz = (reg_tmp15 + -reg_tmp1).xyz; + vs_out_attr1 = uniforms.f[93].xxxx; + vs_out_attr2 = -reg_tmp15; + vs_out_attr0.x = dot_s(uniforms.f[86], reg_tmp15); + vs_out_attr0.y = dot_s(uniforms.f[87], reg_tmp15); + vs_out_attr0.z = dot_s(uniforms.f[88], reg_tmp15); + vs_out_attr0.w = dot_s(uniforms.f[89], reg_tmp15); + vs_out_attr3.xyz = (vs_in_reg3.xyzz).xyz; + vs_out_attr3.w = (vs_in_reg4.xxxx).w; + reg_tmp0 = mul_s(uniforms.f[84].xxxx, vs_in_reg7); + reg_tmp1 = floor(reg_tmp0); + reg_tmp3 = reg_tmp0 + -reg_tmp1; + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp0.z = (mul_s(reg_tmp3.xxxx, reg_tmp3.xxxx)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp3.xxxx)).y; + reg_tmp0.x = (fma_s(reg_tmp0.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp1 = mul_s(vs_in_reg6.xyxy, reg_tmp0.yxxy); + reg_tmp1.x = (-reg_tmp1.xxxx).x; + reg_tmp2.x = (-uniforms.f[94].zzzz + -vs_in_reg5.xxxx).x; + reg_tmp2.y = (-uniforms.f[94].zzzz + vs_in_reg5.yyyy).y; + reg_tmp0 = mul_s(reg_tmp1, reg_tmp2.yyxx); + reg_tmp2.xy = (uniforms.f[94].zzzz + reg_tmp0.xyyy).xy; + reg_tmp0.xy = (reg_tmp0.zwww + reg_tmp2.xyyy).xy; + reg_tmp2.xy = (reg_tmp0).xy; + reg_tmp2.zw = (uniforms.f[93].xxxy).zw; + reg_tmp0.x = dot_s(uniforms.f[11], reg_tmp2); + reg_tmp0.y = dot_s(uniforms.f[12], reg_tmp2); + reg_tmp0.z = dot_s(uniforms.f[13], reg_tmp2); + vs_out_attr4 = reg_tmp0; + reg_tmp2.xy = (reg_tmp1.xyyy).xy; + reg_tmp0.x = dot_3(uniforms.f[11].xyz, reg_tmp2.xyz); + reg_tmp0.y = dot_3(uniforms.f[12].xyz, reg_tmp2.xyz); + vs_out_attr5.xy = (reg_tmp0.xyyy).xy; + reg_tmp2.xy = (reg_tmp1.zwww).xy; + reg_tmp0.x = dot_3(uniforms.f[11].xyz, reg_tmp2.xyz); + reg_tmp0.y = dot_3(uniforms.f[12].xyz, reg_tmp2.xyz); + vs_out_attr5.zw = (reg_tmp0.xxxy).zw; + reg_tmp0.xyz = (reg_tmp6.xyzz + reg_tmp7.xyzz).xyz; + vs_out_attr6.x = dot_3(uniforms.f[86].xyz, reg_tmp0.xyz); + vs_out_attr6.y = dot_3(uniforms.f[87].xyz, reg_tmp0.xyz); + vs_out_attr6.z = dot_3(uniforms.f[88].xyz, reg_tmp0.xyz); + vs_out_attr6.w = dot_3(uniforms.f[89].xyz, reg_tmp0.xyz); + reg_tmp0.xyz = (reg_tmp6.xyzz + -reg_tmp7.xyzz).xyz; + vs_out_attr7.x = dot_3(uniforms.f[86].xyz, reg_tmp0.xyz); + vs_out_attr7.y = dot_3(uniforms.f[87].xyz, reg_tmp0.xyz); + vs_out_attr7.z = dot_3(uniforms.f[88].xyz, reg_tmp0.xyz); + vs_out_attr7.w = dot_3(uniforms.f[89].xyz, reg_tmp0.xyz); + return true; +} +bool sub_1() { + reg_tmp9 = uniforms.f[93].xxxx; + reg_tmp10 = uniforms.f[93].xxxx; + reg_tmp11 = uniforms.f[93].xxxx; + reg_tmp3 = mul_s(reg_tmp12, reg_tmp12); + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp5 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.xxxx, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.xxxx)).y; + reg_tmp0.x = (fma_s(reg_tmp3.xxxx, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp4.xy = (reg_tmp0).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.yyyy, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.yyyy)).y; + reg_tmp0.x = (fma_s(reg_tmp3.yyyy, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp4.zw = (reg_tmp0.xxxy).zw; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp5.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp3.zzzz, reg_tmp0.xyyy, reg_tmp5.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.zzzz)).y; + reg_tmp0.x = (fma_s(reg_tmp3.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp11.x = (-reg_tmp4.wwww).x; + reg_tmp9.x = (mul_s(reg_tmp0.xxxx, reg_tmp4.zzzz)).x; + reg_tmp10.x = (mul_s(reg_tmp0.yyyy, reg_tmp4.zzzz)).x; + reg_tmp11.y = (mul_s(reg_tmp4.yyyy, reg_tmp4.zzzz)).y; + reg_tmp11.z = (mul_s(reg_tmp4.xxxx, reg_tmp4.zzzz)).z; + reg_tmp1.xy = (mul_s(reg_tmp4.xyyy, reg_tmp0.yxxx)).xy; + reg_tmp9.y = (fma_s(reg_tmp1.yyyy, reg_tmp4.wwww, -reg_tmp1.xxxx)).y; + reg_tmp10.z = (fma_s(reg_tmp1.xxxx, reg_tmp4.wwww, -reg_tmp1.yyyy)).z; + reg_tmp1.xy = (mul_s(reg_tmp4.yxxx, reg_tmp0.yxxx)).xy; + reg_tmp9.z = (fma_s(reg_tmp1.yyyy, reg_tmp4.wwww, reg_tmp1.xxxx)).z; + reg_tmp10.y = (fma_s(reg_tmp1.xxxx, reg_tmp4.wwww, reg_tmp1.yyyy)).y; + return false; +} +bool sub_2() { + reg_tmp6.yz = (uniforms.f[93].xxxx).yz; + reg_tmp7.xz = (uniforms.f[93].xxxx).xz; + reg_tmp6.xw = (uniforms.f[93].yyyy).xw; + reg_tmp7.yw = (uniforms.f[93].yyyy).yw; + reg_tmp6.xyz = (mul_s(reg_tmp6, reg_tmp13.xxxx)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp7, reg_tmp13.yyyy)).xyz; + reg_tmp0.x = dot_3(reg_tmp6.xyz, reg_tmp9.xyz); + reg_tmp0.y = dot_3(reg_tmp6.xyz, reg_tmp10.xyz); + reg_tmp0.z = dot_3(reg_tmp6.xyz, reg_tmp11.xyz); + reg_tmp6 = reg_tmp0; + reg_tmp1.x = dot_3(reg_tmp7.xyz, reg_tmp9.xyz); + reg_tmp1.y = dot_3(reg_tmp7.xyz, reg_tmp10.xyz); + reg_tmp1.z = dot_3(reg_tmp7.xyz, reg_tmp11.xyz); + reg_tmp7 = reg_tmp1; + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + return false; +} +bool sub_3() { + if (uniforms.b[2]) { + sub_4(); + } else { + sub_5(); + } + return false; +} +bool sub_4() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp6 = uniforms.f[93].xxxx; + reg_tmp7 = uniforms.f[93].xxxx; + reg_tmp6.x = (uniforms.f[93].yyyy).x; + reg_tmp7.y = (uniforms.f[93].yyyy).y; + reg_tmp0.x = dot_3(reg_tmp6.xyz, reg_tmp9.xyz); + reg_tmp0.y = dot_3(reg_tmp6.xyz, reg_tmp10.xyz); + reg_tmp0.z = dot_3(reg_tmp6.xyz, reg_tmp11.xyz); + reg_tmp6 = reg_tmp0; + reg_tmp1.x = dot_3(reg_tmp7.xyz, reg_tmp9.xyz); + reg_tmp1.y = dot_3(reg_tmp7.xyz, reg_tmp10.xyz); + reg_tmp1.z = dot_3(reg_tmp7.xyz, reg_tmp11.xyz); + reg_tmp7 = reg_tmp1; + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp8.xyz = (mul_s(reg_tmp0.yzxx, reg_tmp7.zxyy)).xyz; + reg_tmp8.xyz = (fma_s(-reg_tmp7.yzxx, reg_tmp0.zxyy, reg_tmp8)).xyz; + reg_tmp1 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp3 = vec4(rsq_s(reg_tmp1.x)); + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + reg_tmp0 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp1.xxxx); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp3.xxxx); + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp13.xxxx); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp13.yyyy); + return false; +} +bool sub_5() { + if (uniforms.b[4]) { + sub_6(); + } else { + sub_7(); + } + reg_tmp0 = vec4(dot_3(reg_tmp6.xyz, reg_tmp6.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp1.xxxx); + reg_tmp0 = vec4(dot_3(reg_tmp7.xyz, reg_tmp7.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp1.xxxx); + reg_tmp0 = reg_tmp6; + reg_tmp6.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp6.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp6.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp0 = reg_tmp7; + reg_tmp7.x = dot_3(uniforms.f[25].xyz, reg_tmp0.xyz); + reg_tmp7.y = dot_3(uniforms.f[26].xyz, reg_tmp0.xyz); + reg_tmp7.z = dot_3(uniforms.f[27].xyz, reg_tmp0.xyz); + reg_tmp6 = mul_s(reg_tmp6, reg_tmp13.xxxx); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp13.yyyy); + reg_tmp1 = uniforms.f[83]; + reg_tmp2 = uniforms.f[82]; + reg_tmp0.z = (mul_s(reg_tmp12.zzzz, reg_tmp12.zzzz)).z; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp1.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp2.zwww)).xy; + reg_tmp1 = uniforms.f[81]; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.xyyy)).xy; + reg_tmp0.xy = (fma_s(reg_tmp0.zzzz, reg_tmp0.xyyy, reg_tmp1.zwww)).xy; + reg_tmp0.y = (mul_s(reg_tmp0.yyyy, reg_tmp12.zzzz)).y; + reg_tmp0.x = (fma_s(reg_tmp0.zzzz, reg_tmp0.xxxx, uniforms.f[93].yyyy)).x; + reg_tmp0.z = (-reg_tmp0.yyyy).z; + reg_tmp1 = mul_s(reg_tmp0.xzyx, reg_tmp6.xyxy); + reg_tmp6.xy = (reg_tmp1.xzzz + reg_tmp1.ywww).xy; + reg_tmp6.zw = (uniforms.f[93].xxxx).zw; + reg_tmp1 = mul_s(reg_tmp0.xzyx, reg_tmp7.xyxy); + reg_tmp7.xy = (reg_tmp1.xzzz + reg_tmp1.ywww).xy; + reg_tmp7.zw = (uniforms.f[93].xxxx).zw; + return false; +} +bool sub_6() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp7.xz = (uniforms.f[93].xxxx).xz; + reg_tmp7.yw = (uniforms.f[93].yyyy).yw; + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp8.yzxx, reg_tmp0.zxyy)).xyz; + reg_tmp7.xyz = (fma_s(-reg_tmp0.yzxx, reg_tmp8.zxyy, reg_tmp7)).xyz; + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + return false; +} +bool sub_7() { + reg_tmp8.x = (uniforms.f[28].zzzz).x; + reg_tmp8.y = (uniforms.f[29].zzzz).y; + reg_tmp8.z = (uniforms.f[30].zzzz).z; + reg_tmp0 = vec4(dot_3(reg_tmp8.xyz, reg_tmp8.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp8 = mul_s(reg_tmp8, reg_tmp1.xxxx); + reg_tmp7.x = (uniforms.f[28].yyyy).x; + reg_tmp7.y = (uniforms.f[29].yyyy).y; + reg_tmp7.z = (uniforms.f[30].yyyy).z; + reg_tmp0 = vec4(dot_3(reg_tmp7.xyz, reg_tmp7.xyz)); + reg_tmp1 = vec4(rsq_s(reg_tmp0.x)); + reg_tmp7 = mul_s(reg_tmp7, reg_tmp1.xxxx); + reg_tmp0.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp0.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp0)).xyz; + reg_tmp7.xyz = (mul_s(reg_tmp8.yzxx, reg_tmp0.zxyy)).xyz; + reg_tmp7.xyz = (fma_s(-reg_tmp0.yzxx, reg_tmp8.zxyy, reg_tmp7)).xyz; + reg_tmp6.xyz = (mul_s(reg_tmp7.yzxx, reg_tmp8.zxyy)).xyz; + reg_tmp6.xyz = (fma_s(-reg_tmp8.yzxx, reg_tmp7.zxyy, reg_tmp6)).xyz; + return false; +} +// reference: B27B1465AA6A6345, 59B04B6EAAAB8C6A +// shader: 8B30, C6D6FCB25C40207E +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 640B2A452CDB7C3D, C6D6FCB25C40207E +// program: 59B04B6EAAAB8C6A, B326B1D273D9548B, C6D6FCB25C40207E +// shader: 8B30, BD4A5D7640E6D63F +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: BA74EA4756403455, BD4A5D7640E6D63F +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, BD4A5D7640E6D63F +// shader: 8B30, 24587E21F71BD9E6 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 75EC0EB8D7BF22EF, 24587E21F71BD9E6 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 24587E21F71BD9E6 +// shader: 8B30, F581CDA357B7B6CC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((texcolor0.rgb) + (rounded_primary_color.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (texcolor0.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].aaa) * (last_tex_env_out.rgb) + (const_color[4].rgb) * (vec3(1.0) - (last_tex_env_out.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (rounded_primary_color.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: DE8A954F07D40ED4, F581CDA357B7B6CC +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, F581CDA357B7B6CC +// shader: 8B30, 6422B814E1A27859 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = byteround(clamp((const_color[1].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_1 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 75EC0EB864A85A70, 6422B814E1A27859 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 6422B814E1A27859 +// shader: 8B30, 47989A330044D8B4 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D74AE6FF8EF91FEA, 47989A330044D8B4 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 47989A330044D8B4 +// shader: 8B30, 52B23EB76EBD9526 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 59EE12898EA8C6EC, 52B23EB76EBD9526 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 52B23EB76EBD9526 +// shader: 8B30, FF212C0585AE36EC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor0.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((const_color[2].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9676F6760F57D056, FF212C0585AE36EC +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, FF212C0585AE36EC +// shader: 8B30, 51F2F7AF26D9CDF0 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.a = last_tex_env_out.a; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_3 = byteround(clamp((last_tex_env_out.rgb) * (texcolor2.aaa), vec3(0.0), vec3(1.0))); +float alpha_output_3 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; +next_combiner_buffer.rgb = last_tex_env_out.rgb; + +vec3 color_output_4 = byteround(clamp((rounded_primary_color.rgb) * (const_color[4].aaa) + (const_color[4].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) * (texcolor1.rgb) + (combiner_buffer.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: D74AE6FFD435BE4F, 51F2F7AF26D9CDF0 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 51F2F7AF26D9CDF0 +// shader: 8B30, 60C8D7C656E4BDFC +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = (const_color[3].rgb); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (texcolor2.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (texcolor1.rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((last_tex_env_out.a) * (const_color[4].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((last_tex_env_out.rgb) + (const_color[5].aaa), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((last_tex_env_out.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +if (int(last_tex_env_out.a * 255.0) == alphatest_ref) discard; +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: CF64CE068D930105, 60C8D7C656E4BDFC +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 60C8D7C656E4BDFC +// shader: 8B30, 9430E12906D4655D +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((vec3(1.0) - texcolor0.rgb) * (const_color[3].rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((texcolor0.a) * (const_color[3].a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((texcolor0.rgb) * (const_color[4].rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((1.0 - texcolor0.a) * (const_color[4].a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 59EE128987713D26, 9430E12906D4655D +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 9430E12906D4655D +// shader: 8B30, 22819C12B2395CA2 +in vec4 primary_color; +in vec2 texcoord0; +in vec2 texcoord1; +in vec2 texcoord2; +in float texcoord0_w; +in vec4 normquat; +in vec3 view; + +#ifndef CITRA_GLES +in vec4 gl_FragCoord; +#endif // CITRA_GLES +out vec4 color; + +uniform sampler2D tex0; +uniform sampler2D tex1; +uniform sampler2D tex2; +uniform samplerCube tex_cube; +uniform samplerBuffer texture_buffer_lut_lf; +uniform samplerBuffer texture_buffer_lut_rg; +uniform samplerBuffer texture_buffer_lut_rgba; + +#define NUM_TEV_STAGES 6 +layout (std140) uniform shader_data { + int alphatest_ref; + float depth_scale; + float depth_offset; + float shadow_bias_constant; + float shadow_bias_linear; + int scissor_x1; + int scissor_y1; + int scissor_x2; + int scissor_y2; + int fog_lut_offset; + int proctex_noise_lut_offset; + int proctex_color_map_offset; + int proctex_alpha_map_offset; + int proctex_lut_offset; + int proctex_diff_lut_offset; + float proctex_bias; + vec3 fog_color; + vec2 proctex_noise_f; + vec2 proctex_noise_a; + vec2 proctex_noise_p; + vec4 const_color[NUM_TEV_STAGES]; + vec4 tev_combiner_buffer_color; + vec4 clip_coef; +}; + +#define NUM_LIGHTS 8 +#define NUM_LIGHTING_SAMPLERS 24 +struct LightSrc { + vec3 specular_0; + vec3 specular_1; + vec3 diffuse; + vec3 ambient; + vec3 position; + vec3 spot_direction; + float dist_atten_bias; + float dist_atten_scale; +}; +layout (std140) uniform shader_light_data { + ivec4 lighting_lut_offset[NUM_LIGHTING_SAMPLERS / 4]; + vec3 lighting_global_ambient; + LightSrc light_src[NUM_LIGHTS]; + float lut_scale_d0; + float lut_scale_d1; + float lut_scale_sp; + float lut_scale_fr; + float lut_scale_rb; + float lut_scale_rg; + float lut_scale_rr; + int shadow_texture_bias; +}; + +// Rotate the vector v by the quaternion q +vec3 quaternion_rotate(vec4 q, vec3 v) { + return v + 2.0 * cross(q.xyz, cross(q.xyz, v) + q.w * v); +} + +float LookupLightingLUT(int lut_index, int index, float delta) { + vec2 entry = texelFetch(texture_buffer_lut_lf, lighting_lut_offset[lut_index >> 2][lut_index & 3] + index).rg; + return entry.r + entry.g * delta; +} + +float LookupLightingLUTUnsigned(int lut_index, float pos) { + int index = clamp(int(pos * 256.0), 0, 255); + float delta = pos * 256.0 - float(index); + return LookupLightingLUT(lut_index, index, delta); +} + +float LookupLightingLUTSigned(int lut_index, float pos) { + int index = clamp(int(pos * 128.0), -128, 127); + float delta = pos * 128.0 - float(index); + if (index < 0) index += 256; + return LookupLightingLUT(lut_index, index, delta); +} + +float byteround(float x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec2 byteround(vec2 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec3 byteround(vec3 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +vec4 byteround(vec4 x) { + return round(x * 255.0) * (1.0 / 255.0); +} + +float getLod(vec2 coord) { + vec2 d = max(abs(dFdx(coord)), abs(dFdy(coord))); + return log2(max(d.x, d.y)); +} + +vec4 shadowTexture(vec2 uv, float w) { + return vec4(1.0); +} + +vec4 shadowTextureCube(vec2 uv, float w) { + return vec4(1.0); +} + +void main() { +vec4 rounded_primary_color = byteround(primary_color); +vec4 primary_fragment_color = vec4(0.0); +vec4 secondary_fragment_color = vec4(0.0); +if (!(gl_FragCoord.x >= float(scissor_x1) && gl_FragCoord.y >= float(scissor_y1) && gl_FragCoord.x < float(scissor_x2) && gl_FragCoord.y < float(scissor_y2))) discard; +float z_over_w = 2.0 * gl_FragCoord.z - 1.0; +float depth = z_over_w * depth_scale + depth_offset; +vec4 texcolor0 = textureLod(tex0, texcoord0, getLod(texcoord0 * vec2(textureSize(tex0, 0)))); +vec4 texcolor1 = textureLod(tex1, texcoord1, getLod(texcoord1 * vec2(textureSize(tex1, 0)))); +vec4 texcolor2 = textureLod(tex2, texcoord2, getLod(texcoord2 * vec2(textureSize(tex2, 0)))); +vec4 combiner_buffer = vec4(0.0); +vec4 next_combiner_buffer = tev_combiner_buffer_color; +vec4 last_tex_env_out = vec4(0.0); +vec3 color_output_0 = (const_color[0].rgb); +float alpha_output_0 = byteround(clamp((rounded_primary_color.a) * (texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_0, alpha_output_0); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_1 = (const_color[1].rgb); +float alpha_output_1 = byteround(clamp((texcolor2.a) + (texcolor1.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_1, alpha_output_1); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_2 = byteround(clamp((last_tex_env_out.rgb) * (texcolor0.rgb) + (const_color[2].rgb) * (vec3(1.0) - (texcolor0.rgb)), vec3(0.0), vec3(1.0))); +float alpha_output_2 = (last_tex_env_out.a); +last_tex_env_out = vec4(color_output_2, alpha_output_2); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_3 = byteround(clamp((const_color[3].rgb) * (vec3(1.0) - texcolor0.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_3 = byteround(clamp((const_color[3].a) * (1.0 - texcolor0.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_3, alpha_output_3); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_4 = byteround(clamp((const_color[4].rgb) * (texcolor0.rgb) + (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_4 = byteround(clamp((const_color[4].a) * (texcolor0.a) + (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_4, alpha_output_4); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +vec3 color_output_5 = byteround(clamp((rounded_primary_color.rgb) * (last_tex_env_out.rgb), vec3(0.0), vec3(1.0))); +float alpha_output_5 = byteround(clamp((rounded_primary_color.a) * (last_tex_env_out.a), 0.0, 1.0)); +last_tex_env_out = vec4(color_output_5, alpha_output_5); +last_tex_env_out = clamp(last_tex_env_out, vec4(0.0), vec4(1.0)); +combiner_buffer = next_combiner_buffer; + +gl_FragDepth = depth; +color = byteround(last_tex_env_out); +} +// reference: 9676F676068E2B9C, 22819C12B2395CA2 +// program: FC7F4467554D34E5, 1C4CBC8096EA16CD, 22819C12B2395CA2 diff --git a/cache/0004001000021700.shader.meta b/cache/0004001000021700.shader.meta new file mode 100644 index 00000000000..ec158a97cd5 --- /dev/null +++ b/cache/0004001000021700.shader.meta @@ -0,0 +1,4 @@ +version: 8 +shader: 114 +reference: 133 +program: 106 diff --git a/src/android/app/src/main/assets/3dstdb-zh_CN.txt b/src/android/app/src/main/assets/3dstdb-zh_CN.txt index 4cd1b7d1396..c6f494d1be6 100644 --- a/src/android/app/src/main/assets/3dstdb-zh_CN.txt +++ b/src/android/app/src/main/assets/3dstdb-zh_CN.txt @@ -4,6 +4,20 @@ 000400300000A102 = Home Menu 000400300000A902 = Home Menu 000400300000B102 = Home Menu +0004000000090700 = 任天狗 +0004000000030B00 = 任天狗 +0004000000030C00 = 任天狗 +0004000000030D00 = 任天狗 +0004000000090800 = 任天狗 +0004000000031000 = 任天狗 +0004000000031100 = 任天狗 +0004000000031200 = 任天狗 +0004000000090900 = 任天狗 +0004000000031500 = 任天狗 +0004000000031600 = 任天狗 +0004000000031700 = 任天狗 +00040000001C1C00 = 超回转 寿司强袭者 寿司道 +0004000000196700 = 超回转 寿司强袭者 寿司道 000400000012E000 = 僵尸梦游仙境DX 0004000000167A00 = 僵尸梦游仙境DX 00040000000F5600 = 僵尸梦游仙境DX @@ -72,6 +86,14 @@ 00040000001A6C00 = 第七龙神3 代号VFD 0004000000039A00 = 卡片召唤师 0004000000053700 = 终极兵团 +0004000000095800 = 新绘心教室 +0004000000095700 = 新绘心教室 +0004000000084F00 = 新绘心教室 +00040000000DA000 = 刺猬索尼克 +00040000000DB500 = 刺猬索尼克 +0004000000158D00 = 刺猬索尼克 2 +0004000000162700 = 刺猬索尼克 2 +0004000000048000 = 初音未来 未来计划 0004000000148900 = 初音未来 未来计划DX 0004000000148C00 = 初音未来 未来计划DX 000400000014A800 = 初音未来 未来计划DX