raven02
7f3a3ccd6c
Projection mapping : Initialize z as 1.0f
2013-10-01 09:01:38 +08:00
Henrik Rydgard
01def3b6cc
Missed these
2013-09-21 23:44:11 +02:00
Henrik Rydgard
82e5787bbe
Preparation for proper spline/bez: Convert control points to a simple format.
...
The bezier/spline code will no longer need to handle morph and splines,
when it's finally written. This is done by pre-skinning in software and
pre-decoding to get rid of the morph.
2013-09-21 23:37:14 +02:00
raven02
8ccaa733b9
Use and applu new bool , doShadeMapping
2013-09-14 14:29:37 +08:00
raven02
ef2399d5b3
Use GE state accessor more often : gstate.isSkinningEnabled()
2013-09-14 14:11:25 +08:00
Unknown W. Brackets
0e82ecca86
Fix lighting when lightpos and spec coef are 0.
...
Zero to the power of zero is mathematically undefined, NVIDIA chokes but
AMD seems to accept it. Not well tested on Android.
Fixes #2424 .
2013-09-01 03:11:02 -07:00
Unknown W. Brackets
7f6cf3ec29
Add a few gstate accessors for texture type stuff.
2013-08-24 11:34:37 -07:00
Henrik Rydgård
d9897719b7
Merge pull request #3260 from raven02/patch-8
...
Treat light type 3 as GE_LIGHTTYPE_SPOT
2013-08-20 05:13:26 -07:00
raven02
4899f67fa1
Missing one case type == GE_LIGHTTYPE_UNKNOWN
2013-08-20 19:43:26 +08:00
raven02
a328bc968c
HW: Use GETexProjMapMode constants
2013-08-20 11:56:43 +08:00
raven02
4e533adf52
HW : Treat light type 3 as light type 2
2013-08-20 11:43:18 +08:00
Unknown W. Brackets
12c5f5e1e6
Use constants for other uv gen mode usages.
...
And also change them to treat 3 as coords as well.
2013-08-19 00:43:54 -07:00
raven02
0daa550538
Add getWeightMask()
2013-07-30 23:55:11 +08:00
raven02
ba458bf421
VertexShader : Set case 3 as default #1
2013-07-29 16:53:06 +08:00
Unknown W. Brackets
7b7801d59a
Switch to including Windows.h from an intermediate.
...
This makes it easier for Xbox which uses a separate header.
2013-07-28 21:04:19 -07:00
Henrik Rydgard
50a2d1b87f
More work on prescaled UV
2013-07-28 00:33:51 +02:00
Henrik Rydgard
2eaf581bbe
Add experimental UV prescaling hack, hidden as it's not finished yet.
...
Most people should ignore this for now, it's a step towards faster skinning in the future.
2013-07-27 23:23:17 +02:00
Henrik Rydgard
8602c276ca
Remove that silly factor 2 for floating point texcoords and weights.
...
No longer needed since we treat the various vertex formats separately.
2013-07-27 22:14:34 +02:00
Henrik Rydgard
e36e976877
Collapse skinning shaders with #bones < 4 to a single one.
...
Significant perf win for skinned characters in FF:CC and maybe other games.
2013-07-27 20:09:22 +02:00
Henrik Rydgard
0ae3c041d2
Minor shader simplification
2013-07-27 18:16:32 +02:00
Unknown W. Brackets
abd9dc6137
Use the light computation/type GE accessors.
2013-07-21 19:44:30 -07:00
Unknown W. Brackets
988614f6d0
Use lightning GE state accessors where appropriate.
2013-07-21 19:44:30 -07:00
Henrik Rydgard
bf1e07661a
Cheap HW transform solution for raven02's texture scaling fix.
2013-07-10 01:23:35 +02:00
Henrik Rydgard
79110638c9
Unbreak things (silly mistake in last commit, remove *2.0 factor which just can't be right)
2013-07-06 22:50:06 +02:00
raven02
23a22a4931
HW : revert multiple with 2.0
2013-07-06 22:47:35 +08:00
raven02
7983bdb448
HW T&L: remove multiple with 2.0
2013-07-01 08:12:43 +08:00
Henrik Rydgard
afb596f3c3
Reorder things a little in VertexShaderGenerator. Strangely solves a specular lighting issue I saw.
2013-06-24 19:11:04 +02:00
Henrik Rydgard
6a9e6ce5fe
Simplify vertex shaders a little more in the common case of directional lights.
2013-06-24 00:29:30 +02:00
Henrik Rydgard
916184d2f4
Optimize the most common light type, directional, by doing the normalization beforehand. May shorten some shaders below Mali's limit with luck.
2013-06-20 23:30:21 +02:00
Henrik Rydgard
e7097ca95a
Fall back to software transform when hardware transform fails. Should help Mali devices.
...
This is done per shader so the speed hit should not be as bad as turning hw transform off entirely.
Displays a red error at the top of the screen so that we don't trigger this accidentally.
2013-06-06 10:09:37 +02:00
Unknown W. Brackets
d3e488400c
Multiply by the base color in ambient lighting.
...
JPCSP seems to do it this way. Fixes #1692 , and makes it consistent with
specular and diffuse, which seems right.
2013-06-04 22:54:19 -07:00
King_DuckZ
61500281a9
Warning fix on Intel compiler.
2013-05-30 15:42:11 +02:00
King_DuckZ
1455452850
Trailing whitespaces removed.
2013-05-30 15:42:11 +02:00
jeid3
fc38cfe798
Fix VertexShaderGenerator Command line for Gpu last generation on ios (hwXform)
2013-05-28 17:53:43 +02:00
Henrik Rydgard
cdef31f9fc
Turn off the use of uniform arrays in shaders as some devices don't like them, and the speedup seems to be very small if any.
2013-05-26 14:03:02 +02:00
Henrik Rydgard
7ffdac39bc
Disable the for loop in the vertex shader again. Some lame drivers don't seem to like it.
2013-05-23 12:49:34 +02:00
Henrik Rydgard
e2024674a4
Undo an optimization that broke skinning a bit...
2013-05-22 19:49:58 +02:00
Henrik Rydgard
199907b9ed
Shader simplification - well, more of it. Hopefully this helps the mali problems a bit more.
2013-05-22 15:52:10 +02:00
Henrik Rydgard
29ab5e7801
Shader simplification: Flip skinning math around. Remove a temporary from the texcoord generation code. Update ffmpeg submodule pointer.
2013-05-20 00:16:29 +02:00
Henrik Rydgard
d9ed61c04a
Shader simplification: Get rid of some uniforms when possible.
2013-05-19 16:38:52 +02:00
Henrik Rydgard
063e23dc0d
Shader simplification: Share even more variables between lights.
2013-05-19 14:45:56 +02:00
Henrik Rydgard
a1d549c59f
Shader simplification: Share some variables between lights to help bad register allocators
2013-05-19 14:36:07 +02:00
Henrik Rydgard
0ff8be1b1a
Shader simplification: Get rid of lightSum1 when not needed.
2013-05-19 14:23:17 +02:00
Henrik Rydgard
b3cc5859dc
Shader simplification: Get rid of lightscale where possible
2013-05-19 13:52:47 +02:00
Henrik Rydgard
06e4441213
Shader simplification: .rgb += instead of vec4(..., 0.0f)
2013-05-19 13:51:46 +02:00
Henrik Rydgard
b1dd449f8f
Remove accidentally-added extra "precision highp float" from vshader gen
2013-05-18 23:21:42 +02:00
Henrik Rydgard
1b210fab14
Use arrays and for loops in GLSL shaders for bone processing, to shrink the shaders which are becoming too big for some mobile GPUs. Might fix #1816 .
2013-05-18 20:45:52 +02:00
Henrik Rydgard
dca2406374
Add more precision specifiers to vertex shader
2013-05-18 19:51:52 +02:00
Unknown W. Brackets
a0e6917ee8
If unspecified, default normal to 0, 0, 1.
...
Fixes Trails in the Sky buttons and improves Kingdom Hearts lighting.
2013-05-04 13:23:50 -07:00
Henrik Rydgard
6f23a56779
Remove use of setlocale() in Osk as I could not figure out the purpose, and it broke stuff.
...
If this is actually needed, please send a pull request adding it back, turning it off when not used, and also add an explanation in a comment.
2013-04-25 10:42:31 +02:00