Commit Graph

1007 Commits

Author SHA1 Message Date
f9d2f7e88c D3D11: Use appropriate shader for PEEK_Z.
Trying to use GetDepthMatrixProgram outside of
TCacheEntry::FromRenderTarget is a bad idea, so don't.  Instead, use a
shader which only copies the input.

Fixes lens flare depth test in Twilight Princess. See
http://code.google.com/p/dolphin-emu/issues/detail?id=5999 .
2014-03-30 19:50:53 -07:00
9b03178673 Merge pull request #222 from comex/more-clang-fixes
More clang fixes
2014-03-30 13:24:08 +02:00
92dd498fa7 Fix harmless warnings. 2014-03-30 01:40:11 -04:00
bdcd5ba39b SW backend: make shaders work on Intel/Windows.
Apparently the Intel shader compiler doesn't implement "#if" correctly...
so use "#ifdef" instead.
2014-03-29 13:10:43 -07:00
0661efea84 Software backend: Delete forked PixelEngine.
Mostly just zapping a bunch of duplicated code; the only interesting thing
going on here is the changes to the performance counter implementation.
2014-03-29 12:07:20 -07:00
664c8d30a0 Remove all trailing whitespaces from our codebase. 2014-03-29 11:05:44 +01:00
1dead05cae Software renderer: Properly calculate tev combiner output.
As pointed out by dolphin-emu/hwtests@461476112.
2014-03-26 00:23:58 +01:00
a8c8db8da7 Software renderer: Use color combiner configuration for alpha combiner compare mode inputs.
As pointed out by dolphin-emu/hwtests@f684f2498.
2014-03-26 00:23:58 +01:00
16105db709 BPMemory: Make use of BitField in a number of structures. 2014-03-25 23:57:58 +01:00
8941f19cdb BPMemory: Expose the pixel_format and zformat fields in PE_CONTROL as enumerations. 2014-03-25 23:57:58 +01:00
77a7bab5ae BPMemory: Use the new BitField class in two selected structures. 2014-03-25 23:57:57 +01:00
89efec6109 Merge pull request #167 from neobrain/ogl-efbpokes
Implement EFB pokes in the OpenGL backend.
2014-03-20 15:25:56 -05:00
ae260e55e4 OGL/VertexManager: Do not check if g_nativeVertexFmt is zero
The variable is already dereferenced both before and after this
check which means that if this variable would ever be zero it would
have crashed dolphin already.
2014-03-18 21:33:30 +01:00
80421156b6 OGL/VertexManager: Minor cleanup of if case 2014-03-18 21:33:30 +01:00
7e39cf3b0d .gitignore: fix the build directory pattern 2014-03-17 02:55:56 +01:00
2fcaca0603 More range-based loops and overrides 2014-03-17 02:55:55 +01:00
8d679e76d2 Merge pull request #164 from lioncash/cstr-cull
Kill off some usages of c_str.
2014-03-15 00:57:56 +01:00
d946e4e238 OpenGL: Implement color and z pokes. 2014-03-14 23:39:52 +01:00
3a6389992e PixelShaderGen: Treat UV coordinates like S17.7 integers (they're still stored as float, though). 2014-03-14 22:31:30 +01:00
0238a56816 PixelShaderGen: Change indirect texture matrix uniforms to use integers. 2014-03-14 22:31:18 +01:00
cff952c397 PixelShaderGen: Use integer math for indirect tev stage texcoord calculation. 2014-03-14 22:30:27 +01:00
fa77e1d2b6 PixelShaderGen: Use integer math for alpha testing. 2014-03-14 22:26:48 +01:00
2af50f04c2 OGL: Force highp for integers. 2014-03-14 22:26:26 +01:00
032c920247 OGL: Remove some dead code. 2014-03-14 22:26:26 +01:00
a82675b7d5 Kill off some usages of c_str.
Also changes some function params, but this is ok.
Some simplifications were also able to be made (ie. killing off strcmps with ==, etc).
2014-03-14 13:51:23 -04:00
31cfc73a09 Fixes spacing for "for", "while", "switch" and "if"
Also moved && and || to ends of lines instead of start.
Fixed misc vertical alignments and some { needed newlining.
2014-03-11 00:35:07 +13:00
d802d39281 clang-modernize -use-nullptr
and s/\bNULL\b/nullptr/g for *.cpp/h/mm files not compiled on my machine
2014-03-09 21:14:26 +01:00
f28116b7da clang-modernize -add-override 2014-03-09 21:12:01 +01:00
c89f04a7c5 clang-modernize -loop-convert
and some manual adjustments
2014-03-09 21:11:59 +01:00
d461b3f33c SW renderer: add missing ClearCurrent()
courtesy of degasus
2014-03-06 01:53:29 +01:00
4f02132f93 Make our architecture defines less stupid.
Our defines were never clear between what meant 64bit or x86_64
This makes a clear cut between bitness and architecture.
This commit also has the side effect of bringing up aarch64 compiling support.
2014-03-04 09:36:59 -06:00
1bdf232fed videosoftware: More coding style fixes. 2014-03-03 19:03:15 +01:00
c6c6d20014 videosoftware: Provide a more elaborate comment on the FifoPlayer support hack. 2014-03-01 18:52:19 +01:00
17231418ef videosoftware: Added hack to bypass xfb just so fifoplayer works.
Fifoplayer depends on the old behaviour of videosoftware (and the other
hardware backends in non virtual/real xfb modes) where the framebuffer
gets rendered directly to the screen.

Really fifoplayer should call BeginFrame/EndFrame when it finished
rendering a frame, but adding this hack back in is simpler.
2014-03-01 18:45:24 +01:00
7c93f2dc23 Fix the Windows build (broken in 315a8ba) 2014-03-01 01:33:19 +01:00
315a8ba1c0 Various changes suggested by cppcheck
- remove unused variables
- reduce the scope where it makes sense
- correct limits (did you know that strcat()'s last parameter does not
  include the \0 that is always added?)
- set some free()'d pointers to NULL
2014-02-28 12:43:20 +01:00
f628695d31 comment fixes 2014-02-26 12:48:52 +01:00
aaaa5af0b2 remove (ATTR|VARY)(IN|OUT) macros 2014-02-26 11:37:29 +01:00
7f539b6033 ogl: optimize real xfb a bit
Both nvidia + mesa seems not to optimize x / (2**n) to x >> n, so we do it ourself.
2014-02-26 11:37:28 +01:00
83b7bb64aa Make Common/ mostly IWYU clean (and fix errors in rest of the project detected by this change). 2014-02-22 23:37:29 +01:00
6d8df311a3 Merge pull request #88 from lioncash/relative-includes
Relative includes
2014-02-20 02:08:44 +01:00
425f9dcd51 Fix more header sorting issues in VideoBackends/ (now check-includes clean). 2014-02-20 01:01:11 +01:00
a18e8249a4 Merge pull request #79 from Tilka/nits
Silence some Windows compiler warnings
2014-02-18 14:19:38 +01:00
2afe215271 Convert all includes to relative paths. 2014-02-18 02:19:10 -05:00
3fd87a7636 Second and final pass of clearing out tabs. 2014-02-17 02:19:41 -05:00
b18a33377d Merge pull request #55 from Sonicadvance1/GLExt-InitArray
Change OpenGL extension initialization in to a big array
2014-02-17 02:16:16 +01:00
6b5f6ddaa1 Merge pull request #82 from lioncash/vertical-alignment
Fix some vertical alignments
2014-02-16 19:12:42 -06:00
6c4ee1753a Fix some vertical alignments
ie. uses spaces for alignment.
2014-02-16 20:12:05 -05:00
eae9d47c3c Change OpenGL extension initialization in to a big array
This is a reasonable chunk of changes and moves from multiple initialization functions in to an array initialization.
2014-02-16 17:40:34 -06:00
de5bfd0bce Merge pull request #37 from degasus/VideoCommonApiFixes
VideoCommon API cleanups
2014-02-16 22:08:28 +01:00