Commit graph

544 commits

Author SHA1 Message Date
Rachel Bryk
7c2c4662a7 Disable Vsync while holding tab to disable the frame limit, and allow toggling vsync while emulation is running in OGL.
D3D9 still doesn't support changing vsync while emulation is running.

Fixes issue 6111.
2013-03-18 20:42:18 -04:00
degasus
234604e067 GLSL: also define pinned_memory in renderer.cpp 2013-03-17 19:03:23 +01:00
degasus
2312a8d9d5 GLSL: don't apply unsupported msaa settings 2013-03-17 10:44:57 +01:00
degasus
4a8ab0fafa disable pinned memory for fglrx 2013-03-17 10:06:16 +01:00
degasus
4a929f85b6 GLSL: fix transparency issues on dual source blend. fix issue 6104 2013-03-17 00:36:13 +01:00
degasus
f673e33a7d fix hotkey osd position 2013-03-07 21:42:40 +01:00
degasus
7af0838e98 disable ubo for intel/mesa
our ubo workaround isn't much better, but not corrupted and much faster (on hd4000) than the ubo one
2013-03-07 21:07:57 +01:00
degasus
800a58f01c reimplement postprocessing and fix one shader as example 2013-03-07 17:00:11 +01:00
degasus
a1c5e90083 Merge branch 'master' into GLSL-master
Conflicts:
	CMakeLists.txt
	Source/Core/DolphinWX/CMakeLists.txt
	Source/Core/DolphinWX/Src/GLInterface.h
	Source/Core/VideoCommon/Src/PixelShaderGen.cpp
	Source/Core/VideoCommon/Src/TextureCacheBase.cpp
	Source/Core/VideoCommon/Src/VertexManagerBase.cpp
	Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoDX9/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoOGL/Plugin_VideoOGL.vcxproj
	Source/Plugins/Plugin_VideoOGL/Plugin_VideoOGL.vcxproj.filters
	Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h
	Source/Plugins/Plugin_VideoOGL/Src/PixelShaderCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoOGL/Src/VertexShaderCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/main.cpp
2013-03-06 15:59:29 +01:00
Jordan Woyak
2b1af36900 Merge branch 'master' into windows-unicode 2013-03-02 15:33:32 -06:00
NeoBrainX
7682ed22c6 Merge branch 'master' into perfqueries.
Conflicts:
	Source/Core/VideoCommon/Src/VideoConfig.h
	Source/Core/VideoCommon/VideoCommon.vcxproj.filters
	Source/Plugins/Plugin_VideoDX11/Src/VertexManager.cpp
	Source/Plugins/Plugin_VideoSoftware/Src/Rasterizer.cpp
	Source/Plugins/Plugin_VideoSoftware/Src/Tev.cpp
2013-03-01 01:07:34 +01:00
Jordan Woyak
03ec9a2e08 Kill some unnecessary c_str and use StrToWxStr in a few places that I missed. 2013-02-28 02:40:03 -06:00
Jordan Woyak
56f09d3b91 Attempt to be consistent with conversions between std::string and wxString. 2013-02-28 02:30:05 -06:00
Jordan Woyak
a680d17eef Buildfix. 2013-02-26 19:59:33 -06:00
Jordan Woyak
f1c990069c Yell at the user if they change window size while dumping frames, and some other avi dumping stuff. 2013-02-26 20:47:48 -05:00
degasus
ae481068cd cleanup ogl extension osd 2013-02-26 23:36:22 +01:00
degasus
a650ae8c7b workaround for base vertex. damn old nvidia driver 2013-02-26 23:15:55 +01:00
degasus
9bc8d6e02b make samplercache global and call constructor/destructor 2013-02-26 18:30:13 +01:00
Jordan Woyak
55c2a01744 Check for sampler object support, just to be nice. 2013-02-19 21:24:08 -06:00
Jordan Woyak
f2647a1216 Implement OGL sampler cache. Allows binding a texture multiple times with different parameters. Also possibly gives a very small speed improvement. 2013-02-19 21:18:53 -06:00
degasus
0f2ee45d96 remove ati workaroung for mipmap creation
isn't needed any more by merging mapmap_fixes
2013-02-19 15:40:34 +01:00
degasus
a629dea4dc Merge branch 'master' into GLSL-master
Conflicts:
	CMakeLists.txt
	Source/Core/DolphinWX/Dolphin.vcxproj
	Source/Core/DolphinWX/Src/GLInterface/WX.cpp
	Source/Core/DolphinWX/Src/GLInterface/WX.h
	Source/Core/VideoCommon/Src/TextureCacheBase.cpp
	Source/Core/VideoCommon/Src/TextureCacheBase.h
	Source/Plugins/Plugin_VideoDX11/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoDX11/Src/TextureCache.h
	Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoDX9/Src/TextureCache.h
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.h
	Source/Plugins/Plugin_VideoSoftware/Src/SWmain.cpp

damn mipmap_fixes ...
2013-02-18 18:49:20 +01:00
NeoBrainX
0f617183a8 Add a possible TODO.
Dunno if the hardware behaves like this, but it likely does.
2013-02-18 14:54:24 +00:00
degasus
bef24b5c6b new format for gl extensions 2013-02-17 21:41:00 +01:00
degasus
0325e37bfb merge glsl headers into one place 2013-02-13 21:34:48 +01:00
degasus
b3675d15dc enable shader cache again 2013-02-13 16:30:15 +01:00
degasus
bbc292c210 merge Vertex and PixelShaderCache into ProgramShaderCache
this is the first step, uniform handling is still missing
2013-02-13 13:12:19 +01:00
NeoBrainX
6870c1fdd5 Fix some potential issues when blending on EFB formats without alpha.
Clean up state transition tables.
2013-02-07 18:01:24 +01:00
degasus
9987765b1f build fix 2013-02-07 10:48:42 +01:00
degasus
376a807dea first try of osx fix, mostly by pauldachz 2013-02-07 10:34:29 +01:00
degasus
e7a8d3f854 check for GL_ARB_sync, it's in ogl 3.2 2013-02-06 01:05:19 +01:00
degasus
f677b8cba3 update to glew1.9, win binaries also from official release 2013-02-04 21:11:12 +01:00
degasus
011e326698 remove glIsEnabled(GL_BLEND), we do restore state after it, so it doesn't matter 2013-01-31 13:49:20 +01:00
degasus
c05f66bdd0 first try for osx core profile
now it doesn't crash, but it still hangs on startup
2013-01-31 12:20:17 +01:00
Jordan Woyak
0e04e0c305 Fix some shadowing warnings. 2013-01-29 16:43:22 -06:00
degasus
13e9bb56f8 fix bug when rasterfont disappears sometimes 2013-01-25 20:39:19 +01:00
Ryan Houdek
73eb98ed8e Move swap control to the host specific GLInterface files. 2013-01-24 10:31:08 -06:00
degasus
e0ffdda26e Merge branch 'immediate-removal' into GLSL-master
Conflicts:
	Source/Core/VideoCommon/Src/PixelShaderGen.cpp
	Source/Plugins/Plugin_VideoSoftware/Src/SWRenderer.cpp

immediate-removal is a new created branch seperated from master but reverted the revert of immediate-removal
so we get less conflicts by merging
2013-01-24 16:58:28 +01:00
degasus
d60cc373d1 Revert "Revert 30dd9c2 e9d00bf db5f4c8 and bff0fae"
This reverts commit d0301ca89d.

Conflicts:
	.gitignore
2013-01-24 16:11:07 +01:00
degasus
da0ec6618f always init ogl configs 2013-01-21 18:44:33 +01:00
degasus
ebaaf6d468 glShadeModel is also obsolete 2013-01-21 10:37:16 +01:00
degasus
074f73c641 move utils texture to sampler 8+9
rasterfont tex will aways bound to samp8.
efb copy utils will be done in samp9.
2013-01-19 00:39:31 +01:00
degasus
714ff50fdf set blending if dual source might be triggered 2013-01-18 00:44:35 +01:00
degasus
a87fd89fce disable ogl shader cache
it doesn't check the shader itself only the id of the shaders.
So there are cache mismatch atm
2013-01-17 12:36:20 +01:00
degasus
3054d36534 use glBindFragDataLocation instead of glDrawBuffer 2013-01-17 11:16:12 +01:00
lioncash
0ef3bd9c77 Revert "Made several variables/parameters unsigned in the DX9, DX11 and OGL plugins. They make more sense like this (given their names)."
Turns out I was wrong in my previous commit. My bad.

This reverts commit 8743166663.
2013-01-16 15:46:11 -05:00
degasus
8a7f1e9264 workaround for older ati drivers 2013-01-16 19:37:57 +01:00
lioncash
8743166663 Made several variables/parameters unsigned in the DX9, DX11 and OGL plugins. They make more sense like this (given their names).
This also gets rid of some more typecasts in some cases.
2013-01-16 09:42:51 -05:00
degasus
687d74e6c2 only change shader if needed 2013-01-15 14:22:40 +01:00
degasus
2f78986e2c Merge branch 'Graphic_Update' into GLSL-master
Conflicts:
	Source/Core/VideoCommon/Src/VertexManagerBase.cpp
	Source/Plugins/Plugin_VideoOGL/Src/NativeVertexFormat.cpp
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
	Source/Plugins/Plugin_VideoOGL/Src/VertexManager.cpp
2013-01-14 21:36:31 +01:00
degasus
5fe3def64c videoConfig cleanup 2013-01-14 20:00:33 +01:00
degasus
adeac6f4a5 remove old deprecated calls and fixed functions parameters 2013-01-14 17:48:38 +01:00
degasus
2838077313 fix warnings 2013-01-11 21:24:59 +01:00
degasus
60b8e4fb1c vertex shader for texture converter 2013-01-11 11:59:42 +01:00
degasus
092a99cbd2 glsl shaders for showEfbCopyRegions 2013-01-09 20:08:55 +01:00
degasus
bff02b3b73 Merge branch 'arb_framebuffer' into GLSL-master
Conflicts:
	Source/Plugins/Plugin_VideoOGL/Src/FramebufferManager.cpp
	Source/Plugins/Plugin_VideoOGL/Src/RasterFont.cpp
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureConverter.cpp
2013-01-09 11:00:26 +01:00
degasus
84debc17d5 fix msaa
blitting between msaa fbos may not scale. So we need to resolve the efb before swapping.
2013-01-09 01:50:52 +01:00
NeoBrainX
be706a3977 Disable color writing when alpha test always fails. 2013-01-08 18:56:01 +01:00
NeoBrainX
e979b2d4a2 DX11: Fix a small mistake.
Remove some incorrect and/or confusing comments.

Fixes issue 5251. Thanks to limburgerite :)
2013-01-08 18:16:48 +01:00
Ryan Houdek
d0301ca89d Revert 30dd9c2 e9d00bf db5f4c8 and bff0fae 2013-01-07 13:47:34 -06:00
degasus
ef32231431 fix screenshots 2013-01-03 21:40:54 +01:00
degasus
fc02427d54 xfb draw by blit - disable postprocessing
blitting can't do postprocessing - so for postprocessing, we have to add a new stage
2013-01-03 20:44:47 +01:00
degasus
363ffd3a5f swap() by blitting 2013-01-03 12:33:18 +01:00
degasus
ecedf56eb4 uses the ARB_framebuffer_object syntax
also require this extention (OGL3.0), but it have one _realy_ big advantage:
- now it's possible to blit between different texture sizes, so all util draw calls can be implemented as blit
2013-01-03 12:06:47 +01:00
degasus
a1ca288555 fix some AMD issues
This is only a hack. The correct solution would be:
1. don't use GL_TEXTURE_RECT ever. GL_TEXTURE_2D should also be faster
2. use GL_TEXTURE8+ for util textures
3. both
2013-01-03 09:45:12 +01:00
degasus
b38b62afc6 remove glsl binding support. convert every shader to version 130 2013-01-02 16:56:08 +01:00
degasus
30dd9c2e17 always calls glBindBuffer(0) after disabling vao 2012-12-29 12:50:42 +01:00
degasus
316a33d1e6 Merge branch 'master' into GLSL-master
Conflicts:
	Source/Core/DolphinWX/Src/VideoConfigDiag.h
	Source/Plugins/Plugin_VideoOGL/Src/GLUtil.h
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureCache.cpp
	Source/Plugins/Plugin_VideoOGL/Src/TextureConverter.cpp
2012-12-27 10:36:54 +01:00
Ryan Houdek
67c1c6b062 Merge branch 'GLES-software' 2012-12-26 12:54:58 -06:00
Ryan Houdek
9a58f9a3bb Rename another function... 2012-12-26 00:34:09 -06:00
degasus
bff0faea2d Merge branch 'immediate-removal'
Conflicts:
	Source/Plugins/Plugin_VideoOGL/Src/Render.cpp
2012-12-25 12:39:00 +01:00
NeoBrainX
2fedab3bad OGL: Make OSD messages fade out properly instead of having them disappear spontaneously. 2012-12-24 19:50:16 +01:00
Ryan Houdek
9209253e0d Initial removal of Nvidia CG. Still some more cleanup to go 2012-12-24 11:09:52 -06:00
Ryan Houdek
b78f5debe6 Initial push of GLES and GLUtil file breakup. 2012-12-17 14:54:20 -06:00
degasus
1919a458e8 only use one buffer, orphaning should do the rest 2012-12-15 17:28:58 +01:00
degasus
ba8264c2ac use VAO in VertexManager
to use VAO, we must use VBO, so some legency code was removed:

- ARB_map_buffer_range must be available (OGL 3.0), don't call glBufferSubData if not
- ARB_draw_elements_base_vertex also (OGL 3.2), else we have to set the pointers every time
- USE_JIT was removed, it was broken and it isn't needed any more

And the index and vertex buffers are now synchronized, so that there will be one VAO per
NativeVertexFormat and Buffer.
2012-12-15 14:43:01 +01:00
degasus
79a7ce4827 move glBindBuffer and glBindVertexArray out of VertexManager
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:52 -06:00
degasus
75dd48247f initial release of new RasterFont without color support
this new design will once create a texture for all chars.
while rendering a string, a list of polygons (position on screen + texture)
for this string is generated on the fly and print at once by glDrawArrays.
atm, there is no support for colors, so everything will display white.

Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:28 -06:00
degasus
c207422987 using of vao, warning: ARB_vertex_array_object is needed
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:25 -06:00
degasus
34b1451fbe cache vbos in TextureCache::TCacheEntry::FromRenderTarget
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:15 -06:00
degasus
d0c4332d99 don't update vbo, if there are no changes in Renderer::Swap
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:13 -06:00
degasus
bbcb442983 in the end, also Renderer::Swap in vbo
two last draw-calls are missing:
VertexManager::Draw (see Graphic_Update branch)
RasterFont::printString (perhaps reimplement with an texture)

Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:28:10 -06:00
degasus
6b3125728b use vbo for ShowEFBCopyRegions
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:27:53 -06:00
degasus
8b62be2025 fix ShowEFBCopyRegions
those fancy colors were the result of the usage of non-allocated heap

Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:27:49 -06:00
degasus
6864b40e26 reset glEnableClientState befor every draw
should be done with VAO, but atm, this is not possible :-(
this also partial revert the fix in fb92c338af (activating texture0 globally).

Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:27:46 -06:00
degasus
888b5fb061 remove usage of glMultiTexCoord2f
Signed-off-by: Ryan Houdek <Sonicadvance1@gmail.com>
2012-12-13 15:27:38 -06:00
rog
30718230b2 Fix some warnings. 2012-12-06 20:25:07 -05:00
NeoBrainX
4ff9e03509 Merge branch 'efb_scaling_fixes'. 2012-11-19 13:18:57 +01:00
NeoBrainX
a38bb488d2 Remove Renderer::xScale and Renderer::yScale. 2012-11-16 14:29:09 +01:00
NeoBrainX
78031c2d54 Move ComputeDrawRectangle() to Renderer::UpdateDrawRectangle(). 2012-11-16 14:25:49 +01:00
rog
14aa7150d9 Add option for author name for movies. Also, minor cleanup for previous options i've added. 2012-11-14 16:23:20 -05:00
rog
a5d210129d Add an on screen lag counter. 2012-11-11 17:57:06 -05:00
Ryan Houdek
fb92c338af Bit of cleanup and fixing of one issue that was noticeable in SMS with Mario's shadow. 2012-10-27 22:50:06 -05:00
Ryan Houdek
dfb3c44d1a Remove glMatrixMode and glLoadIdentity calls in Render.cpp which do absolutely nothing. 2012-10-27 18:27:16 -05:00
Ryan Houdek
8c1d104ca3 Change EFB copy location rectangles over to a Vertex array 2012-10-27 18:10:31 -05:00
Ryan Houdek
c1fd640964 Rebase immediate-removal on master 2012-10-27 17:22:48 -05:00
Ryan Houdek
2e15440896 Add support for Dual source blending to older ATI cards that don't support 420pack but do support GL_ARB_blend_func_extended. This is more proper as well anyways. 2012-10-09 23:56:00 -05:00
Ryan Houdek
5085cebaf3 These checks aren't needed when using CG. 2012-10-09 23:55:59 -05:00
Ryan Houdek
e3854ded73 Woops, better not forget the ing 2012-10-09 23:54:18 -05:00
Ryan Houdek
4cd748bbec Remove some warnings in ProgramShadercache, Was using wrong variable for checking dual source blending. 2012-10-09 23:54:18 -05:00