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
Henrik Rydgard
4d4b2990ec
GPU ShaderManager: Naming convention, inline a function
2013-08-10 18:39:27 +02:00
raven02
08a315b7db
Fix typo
2013-07-31 02:35:03 +08:00
raven02
271171dbe3
Use getUVGenMode()
2013-07-31 01:44:03 +08:00
raven02
0daa550538
Add getWeightMask()
2013-07-30 23:55:11 +08:00
raven02
50f98fe498
Add texture level parameter
2013-07-30 23:23:02 +08:00
raven02
75c9ce2498
GPUstate :Add getTextureWidth() & getTextureHeight()
...
and
2013-07-30 23:09:22 +08:00
Unknown W. Brackets
b46ab5f5a4
Always defined WIN32_LEAN_AND_MEAN.
...
Might as well, less mess everywhere else.
2013-07-28 21:04:20 -07: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
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
bccfd9f2d7
Don't set the projection matrix twice, check for -1 bone matrices (seen in logs..)
2013-07-27 17:32:24 +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
Unknown W. Brackets
c0da6b97c5
Add and use some color/alpha test accessors.
2013-07-21 19:44:30 -07:00
raven02
7ac496529b
Vendor Based Alpha and Color Testing
2013-07-21 01:14:36 +08:00
Henrik Rydgard
3e24949f8a
Try different approach to rounding the inputs to the alpha test. Appears to fix some problems on PowerVR.
2013-07-17 23:03:21 +02:00
Henrik Rydgard
81411a74ed
Experimental: Make orientation change possible on Android.
2013-07-16 22:51:25 +02:00
Henrik Rydgard
bf1e07661a
Cheap HW transform solution for raven02's texture scaling fix.
2013-07-10 01:23:35 +02:00
Unknown W. Brackets
9608067ca2
Cleanup initialization order.
2013-07-07 20:31:04 -07:00
Unknown W. Brackets
386d51081c
Optimize linked shader lookup in ApplyShader().
...
We already iterate all (skipping that with an if helps, though), and the
list of shaders in most games is pretty small. Using a map is not gaining
much, and actually makes the whole thing slower.
Cuts from 9.84% time in Tales of Phantasia X (lots of flushes) to 1.85%.
2013-06-30 20:33:50 -07:00
Henrik Rydgard
8aca797f21
Fix silly light direction math bug (probably no effect mostly).
2013-06-24 20:48:31 +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
raven02
a945cf0e13
Fix incorrect texture in Dragon Ball Z Shin Budokai 2
2013-05-31 23:00:35 +08:00
Henrik Rydgard
2d8632cd7a
Remove texture coordinate difference between HW and SW transform. Partly fixes #1963
2013-05-30 13:37:18 +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
9af5499b21
Optimize bone matrix updates.
2013-05-18 21:18:45 +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
Unknown W. Brackets
03f3f99e39
Don't use ivec in the fragment shader.
...
Attempt at #1777 . Needs the + 0.5 to round properly on mobile.
2013-05-12 13:09:02 -07:00
Henrik Rydgård
b3355b2f7c
Mac build fix. Rename WindowZoom ini parameter to force-reset it as it
...
should always be 1 on Android for now.
2013-05-07 23:28:19 +02:00
Unknown W. Brackets
f2b4c4a0bc
Pre-round the colortest/alphatest reference val.
2013-05-07 07:52:49 -07:00
Henrik Rydgard
c04ce5a64e
Implement projective texture mapping. It's not used a great deal but good to have.
2013-04-17 21:41:47 +02:00
BeaR
fa3a1fbd52
Add support for spotlights
2013-04-09 18:26:06 +02:00
Henrik Rydgard
5427f20b90
Don't "DirtyShader" at the end of frame, instead just "stop". Fixes issues caused by vertex arrays left enabled still hanging around.
2013-04-07 23:31:04 +02:00
Unknown W. Brackets
afbde31b42
Add some OpenGL related reporting errors.
2013-03-24 09:45:43 -07:00
Henrik Rydgard
b1108f3290
Respect the size of the current FBO when drawing. Some cleanup.
2013-03-16 00:40:37 +01:00
Henrik Rydgard
bc15617392
Make un-buffered rendering much smarter, removing flicker.
...
This turns it into a very viable option for many games. You do lose some FX
but it can as a result even be used as a workaround for the massive glow
in Wipeout...
2013-03-03 13:00:21 +01:00
raven02
d99ca71a47
Add u_colormask and use it in enableColorTest
2013-02-25 05:45:35 +08:00
Henrik Rydgard
28979e9250
Some work toward better FBO handling. Fixes some things, breaks some things..
2013-02-21 21:37:19 +01:00
Henrik Rydgard
eb130db387
Fix sign of depth in "Through" projection matrix. Thanks xele02. Fixes ToE, Dissidia, etc.
2013-02-20 00:13:18 +01:00
Henrik Rydgard
2301a3b49e
Flip texcoord vertically when texturing from FBO to compensate for OpenGL coordinate systems
2013-02-15 00:31:39 +01:00
Henrik Rydgard
36f49706e0
Add option to stretch to display (turns off the black bars fixing the aspect ratio).
2013-02-13 18:21:21 +01:00
Unknown W. Brackets
3503d4ed68
Clear the shader ids when clearing the cache.
2013-02-13 02:10:51 -08:00
Henrik Rydgard
6b3ddae554
Fix UV error introduced in previous commit
2013-02-06 21:38:19 +01:00
Henrik Rydgard
aaf00e047b
Don't convert texcoords to float either.
2013-02-06 20:30:10 +01:00
Henrik Rydgard
bdc467769e
Some shader and vertex format optimizations
2013-02-05 01:37:00 +01:00
Henrik Rydgard
bf51291527
Don't translate bone weights to floats unnecessarily. Minor optimization to ApplyShader, pushing it down the profile from 2% to 0.5% in Wipeout.
2013-02-04 23:10:40 +01:00
Henrik Rydgard
e04f5156ee
Fix a few graphics issues, optimize shader ID generation (fewer shaders)
2013-01-22 22:03:41 +01:00