summaryrefslogtreecommitdiff
path: root/Source/Plugins/Plugin_VideoOGL/Src/PixelShaderCache.cpp
AgeCommit message (Collapse)Author
2010-02-20Some code clean up, and take care of some compiler warnings.Glenn Rice
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5090 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-06D3D and Opengl:Rodolfo Osvaldo Bogado
reverted a tiny leftover of my safe texture cache commit D3D renamed the SSAA modes to use samples as MSAA now they are 2,25x and 4x. OpenGL: fixed a nasty logical bug introduced in 4984 that causes efb corruption when efb to texture is used re enabled shader caching as it was not producing errors. fixed efb misalignment caused by integer rounding still a bit misaligned but many games will look better now git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5020 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-02-02Linux global build. At least the basic footwork is done here.Glenn Rice
Basic usage: "sudo scons install=global install" Hopefully this doesn't break builds on Macs. I have tested this on linux and windows. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4994 8ced0084-cf51-0410-be5f-012b33b47a6e
2010-01-17Shader Disk Cache implementation for D3D. Saves generated shaders on disk. ↵hrydgard
Eliminates "freeze jerks" in D3D plugin the _second_ and later times you play something.... not much to do about the first time. The D3D shader compiler is just slow. Also assorted cleanup around the shader code. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4869 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-11-27small code reorganization.Rodolfo Osvaldo Bogado
Now efb to ram display correctly but still is misaligned by one pixel please test and give me feedback git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4618 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-11-02This is a "Try to fix" commit, reverted all the changes made by my first ↵Rodolfo Osvaldo Bogado
commit that could affect texturing, so please everyone with texture problems please test this, also in opengl let the viewport calculations the way they where, opengl can handle any values in the viewport. in direct3d this is different, the only valid values are between 0.0 an 1.0 so fix this and let the shader handle the rest. please test all this and let me know the results. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4494 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-10-31Some errors in the values passed to e pixel shader caused the menu error, no ↵Rodolfo Osvaldo Bogado
they are fixed, thanks to LordMark for help me with the testing. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4490 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-10-31fixed z textures, don't know where this is used but a fix is a fixRodolfo Osvaldo Bogado
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4486 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-10-30small code cleanup, and little fixing of errors introduced by mi in my first ↵Rodolfo Osvaldo Bogado
commit :( fixed scissor test in direct 3d git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4480 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-10-25small code clean up:Rodolfo Osvaldo Bogado
d3d: remove the depth texture path it will not work so for now only lockable textures were available. i thing the only way will be a use a secondary render target and do a depth pass to mimic depth textures. opengl: minor cleanup here and there and a possible fix to issue 1509, but not tested because in my system the errors remarked in the issue don't show. commond: code reorganization an optimization in the pixel shader generator, trying to understand the tev stages, make some changes to make the generator faster (not much only started for the alpha test and fog). this changes try start solving the diferences bethen the hardware plugins and the soft plugin. i hope with i don't brake nothing but please test this a lot. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4465 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-26OpenGL: commit rodolfoosvaldobogado's (what a name!) speedup patches.hrydgard
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4322 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-19D3D various: "Safe texture cache" option, texture replace instead of ↵hrydgard
destroy/create when possible, a commented out "optimization" that didn't speed things up (use DrawPrimitive instead of DrawIndexedPrimitive when possible), reduce code duplication in Flush(), don't periodically clean out the shader caches since it's not really beneficial - shaders are cheap to keep. some code cleanup. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4302 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-16Fix some shader problems caused by my previous commits to reduce API calls ↵rice1964
(back screen after a while in Zelda WW intro, maybe also in other games). git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4283 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-14psyjoe's patch to shader compilation. ector/some "shader person" check this ↵Shawn Hoffman
please :) looks reasonable to me though. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4267 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-13Rename Config.cpp/h to VideoConfig.cpp/h.hrydgard
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4260 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-13Lots of code and warning cleanup. OGL/D3D: Moved to a shared config class in ↵hrydgard
VideoCommon. This lets VideoCommon code read the config without ugly hacks. Fixed various config race conditions by keeping a copy (g_ActiveConfig) of the g_Config struct which is updated once per frame. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4256 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-12D3D supports setting multiple shader constants at once, so let's add support ↵hrydgard
for that. Very tiny speedup. Also remove the annoying black window in the background when configuring D3D before starting a game. Also make sure to write all values when converting normals - might help the cpu's write gather cache. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4255 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-09-10OGL: API call reduction. Again, I don't see much a difference on my 9800GT, ↵rice1964
maybe make some games running faster. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4245 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-28Now ALL copyright dates are fixed to the legally correct year: The year in ↵XTra.KrazzY
which the project began. Now we don't have to change it every year :) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3898 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-19Roll back r3833 for render targets but keep it for static textures. Most ↵hrydgard
mirroring issues are OK and we shouldn't see any slowdown. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3844 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-07-18GL: Delete code for GL_TEXTURE_RECTANGLE_ARB in case of non-pow2 textures - ↵hrydgard
all modern GFX cards that can run Dolphin should support non-pow2 textures anyway. This removes some complexity and reduces the numbers of pixel shaders that need to be generated in some situations. Also fixes some texture mirroring problems. Let me know if this breaks things on ATI for some reason. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3833 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-06-09Post-processing: Added options to graphics config dialog.hrydgard
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3391 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-06-07Change the screenshots rescale function to always work according to the A/R ↵sl1nk3.s
setting, and not just on native res: fixes 16/9 wii games. remove IsATIDrawBuffer(), this might have been fixed in the drivers since some years already ? git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3359 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-05-15Changing where depth is read. Trying to use the same depth buffer GL uses ↵donkopunchstania
when copying depth to a texture. This eliminates some quirky code and gets depth copies working in AA, but may not work on older graphics cards. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3234 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-04-03OpenGL Plugin: code cleanup trying to follow code style wiki and updated ↵omegadox
copyright date git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2850 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-22Clean up OpenGL plugin error handling macros. No longer bother with enabling ↵hrydgard
TEXTURE_2D and TEXTURE_RECTANGLE_ARB - they don't apply when using shaders. Change a PanicAlert when looking for valid plugins into a LOG_WARN. Let me know if this breaks anything - it shouldn't. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2726 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-21remove newlines from OGL logging (they get added by logmanager)Shawn Hoffman
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2720 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-20Fixed some log messagesnakeee
Fixed a crash when no game ini exists git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2690 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-16Change destination alpha handling. The blending method introduced in rev ↵donkopunchstania
1921 was not the correct way to do it. This way was suggested by hrydgard in October and I should have listened. A simple pixel shader as hrydgard suggested cannot be used because the alpha is not set if the pixel is discarded due to failing depth (after z texture) or alpha (result of tev stages) tests. There is a bit of a performance hit so there should be an option to disable the second render pass which sets the alpha because it is probably not needed most of the time. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2662 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-08First version of MSAA code added. No UI yet. No CSAA yet. Doesn't work in ↵hrydgard
Zeldas and Metroids for unknown reason. Automatic texture invalidation when using copy efb to ram (fixes weird flickery scanner in metroid 2). git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2617 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-05GL plugin: VSync option, some renaming, a little bit of MSAA preparations ↵hrydgard
(not there yet) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2563 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-03-01An alert is displayed once per run if pixel shaders or vertex shaders fail ↵donkopunchstania
to compile. Resources are cleaned up if shader compilation fails. Tev coords are zeroed in the pixel shader if there are no tex gens. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2493 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-02-28OGL plugin: +Autoscale option (attempts to remove borders, even without ↵hrydgard
XFB). Lots of cleanup, especially around aspect ratio and similar stuff. MP2 scanner still broken, wonder when that happened? git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2470 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-02-28Merge large parts of nakeee's "Soap" branch into trunk, after fixing a few ↵hrydgard
crash bugs in FileUtil.cpp. Not really anything interesting, just some better comments, some slightly more portable/cleaner code in places. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2459 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-02-23Update svn:eol-style=native ( r1442 ) for Source/*.cppLPFaint99
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2384 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-02-04remove stuff from ogl debugger that did nothing. (copied from dsp hle a ↵Shawn Hoffman
while ago) git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2111 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-01-30build fix for those non-WIP OGL people out thereXTra.KrazzY
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2040 8ced0084-cf51-0410-be5f-012b33b47a6e
2009-01-29More WIP OGL EventHandler work by shuffle2 and myself. Wiimote isn't ↵XTra.KrazzY
implemented yet and OGL window is too small (should take window borders into account when creating window). Not committing VideoOGL.vcproj so that project compiles with old OGL video window. In order to test just replace main.cpp/GLUtil.cpp/GLUtil.h with nmain.cpp/nGLUtil.cpp/nGLUtil.h in the project. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2038 8ced0084-cf51-0410-be5f-012b33b47a6e
2008-12-26More renaming.hrydgard
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1696 8ced0084-cf51-0410-be5f-012b33b47a6e
2008-12-26rename some fileshrydgard
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1695 8ced0084-cf51-0410-be5f-012b33b47a6e
2008-12-26Split out the shader caches into their own files. The goal is to eventually ↵hrydgard
be able to move the "Managers" to VideoCommon. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1681 8ced0084-cf51-0410-be5f-012b33b47a6e