Commit Graph

1243 Commits

Author SHA1 Message Date
Henrik Rydgård
1507358b45 Merge pull request #4322 from unknownbrackets/gpu-minor
Make sure frag shader ID matches generated code
2013-10-26 08:28:41 -07:00
Unknown W. Brackets
2c56ccef18 Make sure frag shader ID matches generated code.
Before, we would use an id with alphatest on, but not actually compile in
alphatest.  Or, we would use a shader with alphatest, when we actually
could compile it out.
2013-10-26 02:19:02 -07:00
Unknown W. Brackets
f9352ad0b8 Update fbos even if they're not the display.
But only when coming from a video or other safe source, to ensure we don't
hurt speed.  Although, might be interesting to do it always?

With the previous commit, fixes #4273.
2013-10-26 00:36:37 -07:00
Unknown W. Brackets
7aa70b473b Set the viewport properly on video frame draw.
Fixes #3771, video frames being drawn at the wrong size at non-1x.
2013-10-26 00:32:03 -07:00
Henrik Rydgård
b896a29ec0 New attempt at solving #4272 by not using alpha in the backbuffer.
If some effect ends up requiring destination alpha, just use buffered
rendering.
2013-10-25 12:44:21 +02:00
Unknown W. Brackets
deaaa99763 Exclude 0xFF from logging, happens a lot. 2013-10-24 22:03:10 -07:00
Unknown W. Brackets
ac027fac81 Fix missing uniform for GE_TEXMAP_TEXTURE_MATRIX. 2013-10-24 21:59:44 -07:00
Henrik Rydgård
5705acba04 Cleanup 2013-10-23 16:10:58 +02:00
Sacha
b0d7f758be Remove QCOM binning control detection. Qualcomm suggests not to use it and it causes crashes on my Adrenos anyway. 2013-10-23 15:02:48 +10:00
Sacha
78d6ad6f80 Clean up GLES3init. Pass Blackberry version through to defines. Update QCOM binning comment. 2013-10-23 15:02:48 +10:00
Henrik Rydgard
5d47aabb08 Seems we need high precision for fog on PowerVR. #4287 might be fixed by this. 2013-10-22 19:56:06 +02:00
Henrik Rydgard
726de7086d Fix postprocessing shaders on Tegra 2013-10-22 15:56:07 +02:00
Henrik Rydgard
2292531dd6 Small optimization for Disable Alpha Test - makes sure we don't generate the same shader twice. 2013-10-22 15:15:13 +02:00
Henrik Rydgard
a88ab80477 Only clear the shader cache when toggling "Disable alpha test" 2013-10-22 14:34:16 +02:00
Henrik Rydgard
cae2934c70 Buildfix 2013-10-22 13:40:51 +02:00
Henrik Rydgard
bf59f3db73 Add ugly hack setting for PowerVR to disable alpha test
Causes glitches but the speedup is truly massive in some games so I relent :/

Please do not report graphics bugs when this is enabled...

Future: Maybe remove this setting except on PowerVR?
2013-10-22 13:00:19 +02:00
Henrik Rydgard
7d8aed096a Add proper support for upscaling shaders, add Spline36 upscaling
Spline36 isn't as amazing as I had hoped heh. And it will need work to
work in GLSL ES. Anyway...

This also renames u_texcoordDelta to u_texelDelta to fit in with u_pixelDelta.
2013-10-22 12:18:49 +02:00
Henrik Rydgard
492fcb261b Reset viewport in CopyDisplayToOutput. Fixes flickering video in non-1:1 resolutions in some games. 2013-10-22 11:19:06 +02:00
Henrik Rydgard
0dd0948f81 The built-in draw2d shader doesn't need a version number specified 2013-10-21 00:42:46 +02:00
danyalzia
4567acaf92 Only turn on filtering in FMV when alpha test isn't enabled 2013-10-20 20:15:25 +05:00
Unknown W. Brackets
edb4472927 Fix some formatting warnings. 2013-10-19 14:57:45 -07:00
Henrik Rydgard
80702109f5 Move gpu vendor detection to native with the rest of the gl init.
Also disable vertical layout for mainscreen entirely.
2013-10-16 00:48:44 +02:00
Henrik Rydgard
8b5eff3677 Only turn off filtering on color test in through mode. Should fix #4192, #4202 2013-10-15 11:59:32 +02:00
raven02
bf7c9fe631 Force Nearest when color test enabled and rendering resolution greater than 480x272 2013-10-14 17:07:45 +08:00
Unknown W. Brackets
9cbb1cb8d3 Warning fix. 2013-10-13 09:34:54 -07:00
Henrik Rydgard
e54107033d Don't crash on post-shader compile errors. 2013-10-13 12:06:55 +02:00
Unknown W. Brackets
85c013c5b6 Fix a crash in OpenGL on game shutdown. 2013-10-12 01:39:50 -07:00
Sacha
d49b4fad9a Miscellaneous changes for Blackberry. 2013-10-12 17:19:02 +10:00
Henrik Rydgard
e0b19decca Add generic "PostShader" functionality, replacing FXAA (it's one of them).
Replaces #4018, sorry DanyalZia :)
2013-10-12 02:05:55 +02:00
danyalzia
8bed8f922e fix a bug :/ 2013-10-11 19:54:26 +05:00
danyalzia
88c36b5b25 Add Auto-texture scaling
Update resource.h

Update WndMainWindow.h

Update WndMainWindow.cpp

Update ppsspp.rc

position fix

Update TextureCache.cpp

Update TextureCache.cpp
2013-10-11 18:30:06 +05:00
Henrik Rydgård
e7a9661cad Fix stupidest crash bug ever. How the hell did this work on any platform? 2013-10-10 23:32:04 +02:00
Henrik Rydgard
b832508c4b Let's put the stencil parameters in the right order.. 2013-10-10 21:41:00 +02:00
Henrik Rydgard
5c8a74d911 Stencil rectangle clears: Take the value from the second vertex. 2013-10-10 21:36:32 +02:00
Henrik Rydgård
ae94e5c078 Must reset lastShader after swtiching shaders outside the "framework". 2013-10-10 20:11:57 +02:00
Henrik Rydgård
d696e5b02f Try a different heuristic for the bezier subdivision factor 2013-10-10 17:49:29 +02:00
raven02
7bf6f6411c Set stencil ref value to 255 (8 bitplanes) 2^8-1=255 2013-10-10 21:59:37 +08:00
Henrik Rydgard
5c3f6bae25 Prescale UV bugfixes 2013-10-09 23:09:16 +02:00
Henrik Rydgård
95fda8dffa Set line width in constructor too. 2013-10-09 19:01:28 +02:00
raven02
23b817f86c Use glLineWidth/glPointSize to specify the width of rasterized lines and size of points. 2013-10-09 19:01:21 +02:00
Henrik Rydgård
39d28c27e2 Update native with gl shutdown fix (helps orientation change).
This also adds some logging that helped me figure things out.
2013-10-09 16:09:16 +02:00
Henrik Rydgård
6d6ea77df2 Add comments (speedup plans for GLES) and reformat a bit (no changes) 2013-10-09 11:56:46 +02:00
Henrik Rydgård
ab759a9350 If bPrescaleUV is enabled, no need to flush on change of these params.
Also disable the QCOM hint, not sure it does any good at all.
2013-10-09 10:44:12 +02:00
Henrik Rydgård
31f5610292 Disable the glTexStorage2D path for now, too many issues. 2013-10-09 09:44:23 +02:00
Henrik Rydgard
4c2c015774 Expose the experimental "bPrescaleUV" as "Texture Coord Speedhack"
It's actually quite beneficial in some games, can substantially reduce
glUniform4fv calls.

Also throw in a second shot at glDrawRangeElements.
2013-10-08 22:59:40 +02:00
Henrik Rydgard
7a0b1e40c6 Update native (making GLES3 features possible on desktop). Minor optimization. 2013-10-08 21:50:43 +02:00
Henrik Rydgård
0a4750909e Try to avoid unnecessary calls to glEnable/DisableVertexAttribArray 2013-10-08 17:47:47 +02:00
Henrik Rydgård
4b019bfcbb Remove '_' from attribute names as Adreno hates them in glBindAttribLocation.
Sigh.

Also remove some logging.
2013-10-08 17:26:33 +02:00
Henrik Rydgård
0ecac31abd Use glBindAttribLocation to simplify shader usage a little. 2013-10-08 17:18:59 +02:00
Henrik Rydgård
df29da0b13 GLES3: Use glTexStorage2D for (possibly) more efficient texture uploading 2013-10-08 15:00:48 +02:00