Commit graph

172 commits

Author SHA1 Message Date
bunnei
021cb0bced renderer_opengl: Use textures for fragment shader LUTs instead of UBOs.
- Gets us LUT interpolation for free.
- Some older Intel GPU drivers did not support the big UBOs needed to store the LUTs.
2016-02-05 17:17:31 -05:00
bunnei
bf89870437 renderer_opengl: Initial implementation of basic specular lighting. 2016-02-05 17:17:30 -05:00
bunnei
e34fa6365f renderer_opengl: Implement HW fragment lighting distance attenuation. 2016-02-05 17:17:30 -05:00
bunnei
e9af70eaf3 renderer_opengl: Implement HW fragment lighting LUTs within our default UBO. 2016-02-05 17:17:29 -05:00
bunnei
afbef52516 renderer_opengl: Implement diffuse component of HW fragment lighting. 2016-02-05 17:17:29 -05:00
tfarley
f53dbafdae hwrasterizer: Use depth offset 2016-01-20 21:57:59 -05:00
Yuri Kunde Schlesner
cf81e08389 OpenGL: Flip framebuffers during transfer rather than when rendering 2015-12-04 22:23:39 -08:00
Yuri Kunde Schlesner
e9c209ccc8 PICA: Properly emulate 1-stage delay in the combiner buffer
This was discovered and verified by @fincs. The tev combiner buffer
actually lags behind by one stage, meaning stage 1 reads the initial
color, stage 2 reads stage 0's output, and so on.

Fixes character portraits in Fire Emblem: Awakening and world textures
in Zelda: ALBW. Closes #1140.
2015-11-30 22:45:18 -08:00
bunnei
f008dfbaca renderer_opengl: Fix uniform issues introduced with kemenaran/avoid-explicit-uniform-location. 2015-11-25 22:33:24 -05:00
Pierre de La Morinerie
0735630744 Use regular uniform location
The support for GL_ARB_explicit_uniform_location is not that good
(53% according to http://feedback.wildfiregames.com/report/opengl/feature/GL_ARB_explicit_uniform_location).

This fix the shader compilation on Intel HD 4000 (#1222).
2015-11-25 11:56:11 +01:00
Subv
823ce62f2f FragShader: Use an UBO instead of several individual uniforms 2015-11-18 21:03:56 -05:00
bunnei
74186a5f01 gl_shader_gen: Use explicit locations for vertex shader attributes. 2015-10-21 22:29:56 -04:00
bunnei
e663f5c914 gl_shader_gen: Optimize code for AppendAlphaTestCondition.
- Also add a comment to AppendColorCombiner.
2015-10-21 22:29:56 -04:00
bunnei
0ebcff710e gl_shader_gen: Various cleanups to shader generation. 2015-10-21 21:59:44 -04:00
bunnei
240a3b80d9 gl_rasterizer: Use MMH3 hash for shader cache hey.
- Includes a check to confirm no hash collisions.
2015-10-21 21:58:59 -04:00
bunnei
71edb55114 gl_shader_gen: Require explicit uniform locations.
- Fixes uniform issue on AMD.
2015-10-21 21:54:56 -04:00
bunnei
5ef2df056d gl_shader_gen: Rename 'o' to 'attr' in vertex/fragment shaders. 2015-10-21 21:53:19 -04:00
bunnei
c2c4faef4c gl_shader_gen: AppendAlphaModifier default should be 0.0, not vec4(0.0). 2015-10-21 21:53:18 -04:00
bunnei
bd833b8dd8 gl_shader_gen: Fix bug where TEV stage outputs should be clamped. 2015-10-21 21:53:18 -04:00
bunnei
4b5141954e gl_shader_gen: Add additional function documentation. 2015-10-21 21:53:17 -04:00
bunnei
a74774257e gl_shader_gen: Various cleanups + moved TEV stage generation to its own function. 2015-10-21 21:53:16 -04:00
bunnei
c86b9d4242 renderer_opengl: Refactor shader generation/caching to be more organized + various cleanups. 2015-10-21 21:53:14 -04:00