Commit graph

10923 commits

Author SHA1 Message Date
Tony Wasserka
d946e4e238 OpenGL: Implement color and z pokes. 2014-03-14 23:39:52 +01:00
Tony Wasserka
0f81cbd6be PixelShaderGen: More code alignment fixes. 2014-03-14 22:33:26 +01:00
Tony Wasserka
c1016205d3 Pixel/LightingShaderGen: Fix code alignment issues.
Most of these weren't even introduced by me, but hey - I'm nice and love wasting my time :p
2014-03-14 22:33:26 +01:00
Tony Wasserka
2067f88e0f PixelShaderGen: Don't make local lookup tables "static". 2014-03-14 22:33:26 +01:00
Tony Wasserka
0ce92e0162 PixelShaderGen: Remove the "i" prefix for integer variables.
The prefix was just required in the development stage to reduce the risk of regressions.
2014-03-14 22:33:26 +01:00
Tony Wasserka
bdd629c598 PixelShaderGen: Use spaces for alignment where appropriate. 2014-03-14 22:33:26 +01:00
Tony Wasserka
6e65e02c9e ConstantManager: Do not use single-element arrays. 2014-03-14 22:33:25 +01:00
Tony Wasserka
6c2971eaf6 PixelShaderGen: Write 16777215 in hex (0xFFFFFF) so that it's easier to understand. 2014-03-14 22:33:25 +01:00
Tony Wasserka
8ebb65ebf2 PixelShaderGen: Prettify generated shader source. 2014-03-14 22:33:24 +01:00
Tony Wasserka
e2e1c5c905 PixelShaderGen: Add a note about a random idea which should be checked with hardware tests. 2014-03-14 22:33:12 +01:00
Tony Wasserka
6fcbda6752 PixelShaderGen: Cleanup and clarify bump alpha combiner inputs. 2014-03-14 22:33:12 +01:00
Tony Wasserka
9a96a1d525 PixelShaderGen: Remove old, mostly useless comments.
A few vague lines of comments cannot replace an afternoon reading of how TEV works.
2014-03-14 22:33:12 +01:00
Tony Wasserka
8b8bb04fd3 PixelShaderGen: Use bit shifts instead of multiplications as a small optimization. 2014-03-14 22:33:12 +01:00
Tony Wasserka
036a8c6951 PixelShaderGen: Clean up tev compare functionality. 2014-03-14 22:33:10 +01:00
Tony Wasserka
fa7173d099 PixelShaderGen: Store tex scale as an integer. 2014-03-14 22:32:30 +01:00
Tony Wasserka
16109fb453 PixelShaderGen: Treat UV coordinates as actual integers. 2014-03-14 22:32:29 +01:00
Tony Wasserka
50526ae50a PixelShaderGen: Remove some dead code. 2014-03-14 22:32:18 +01:00
Tony Wasserka
065919f599 PixelShaderGen: Perform some of the fog calculations with integers. 2014-03-14 22:31:32 +01:00
Tony Wasserka
605b687af8 PixelShaderGen: Use integer math for z textures. 2014-03-14 22:31:31 +01:00
Tony Wasserka
3a6389992e PixelShaderGen: Treat UV coordinates like S17.7 integers (they're still stored as float, though). 2014-03-14 22:31:30 +01:00
Tony Wasserka
3e6efdb53e LightingShaderGen: Perform more lighting calculations with integers. 2014-03-14 22:31:19 +01:00
Tony Wasserka
387b9bf3c2 LightingShaderGen: Perform some lighting calculations with integers. 2014-03-14 22:31:19 +01:00
Tony Wasserka
78623871f9 ShaderGen: Store material uniforms as integers. 2014-03-14 22:31:19 +01:00
Tony Wasserka
4bf57565e8 ShaderGen: Store light color uniforms as integers. 2014-03-14 22:31:18 +01:00
Tony Wasserka
68e91f0d55 PixelShader: Store fog color as an integer. 2014-03-14 22:31:18 +01:00
Tony Wasserka
0238a56816 PixelShaderGen: Change indirect texture matrix uniforms to use integers. 2014-03-14 22:31:18 +01:00
Tony Wasserka
c13a5c38e9 PixelShaderGen: Change the "alpha" uniform to use integers. 2014-03-14 22:31:18 +01:00
Tony Wasserka
ec60acac3a PixelShaderGen: Change the "colors" and "kcolors" uniforms to be integers. 2014-03-14 22:31:18 +01:00
Tony Wasserka
df94e62350 PixelShaderGen: Process fog calculations with integer math. 2014-03-14 22:31:18 +01:00
Tony Wasserka
21eb482a6e PixelShaderGen: Write constants in decimal instead of hexadecimal where appropriate. 2014-03-14 22:31:11 +01:00
Tony Wasserka
cff952c397 PixelShaderGen: Use integer math for indirect tev stage texcoord calculation. 2014-03-14 22:30:27 +01:00
Tony Wasserka
e7a42d884f PixelShaderGen: prev should be initialized to the proper value; tev output needs to be clamped between -1024 and 1023. 2014-03-14 22:30:16 +01:00
Tony Wasserka
cb1514e082 PixelShaderGen: Remove superfluous registerstate stuff. Also, made alphabump an integer. 2014-03-14 22:30:15 +01:00
Tony Wasserka
a11ae69cb0 PixelShaderGen: Use integer math for TEV combiners. 2014-03-14 22:28:32 +01:00
Tony Wasserka
aaa8e74a68 PixelShaderGen: Use integer math for tev outputs. 2014-03-14 22:28:14 +01:00
Tony Wasserka
654442feb7 PixelShaderGen: Use integer math for tev konst value. 2014-03-14 22:28:12 +01:00
Tony Wasserka
e69ee6ae0a PixelShaderGen: Remove remaining floating point bits for texture color. 2014-03-14 22:26:50 +01:00
Tony Wasserka
ac1c77c392 PixelShaderGen: Use integer math for rasterizer color. 2014-03-14 22:26:50 +01:00
Tony Wasserka
3ea97f7730 PixelShaderGen: Use integer math for indirect texture coords. 2014-03-14 22:26:50 +01:00
Tony Wasserka
0e711bf520 PixelShaderGen: Use integer math for sampling textures. 2014-03-14 22:26:50 +01:00
Tony Wasserka
1b3b12caa0 PixelShaderGen: Fix an issue where small negative z coordinates would underflow when they shouldn't. 2014-03-14 22:26:50 +01:00
Tony Wasserka
fa77e1d2b6 PixelShaderGen: Use integer math for alpha testing. 2014-03-14 22:26:48 +01:00
Ryan Houdek
22c989de9a Provide our own dot functions in GLSL since GLSL doesn't provide integer versions of this function, even though AMD and Nvidia provide their own. 2014-03-14 22:26:27 +01:00
Tony Wasserka
bed442198f PixelShaderGen: Make SampleTexture static inline. 2014-03-14 22:26:26 +01:00
Tony Wasserka
2af50f04c2 OGL: Force highp for integers. 2014-03-14 22:26:26 +01:00
Tony Wasserka
032c920247 OGL: Remove some dead code. 2014-03-14 22:26:26 +01:00
Pierre Bourdon
974123000d MemoryInterface: properly register region MMIOs. 2014-03-14 21:52:45 +01:00
Lioncash
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
Pierre Bourdon
450bde27bb Merge pull request #162 from lioncash/tas-dlg
Simplify boolean toggling in the TASInputDlg.
2014-03-13 02:09:32 +01:00
Lioncash
0edda2bd7f Fix a typo in DSPSymbols. (DisasssembleRange -> DisassembleRange)
Also remove IsHexDigit and IsAlpha and replace them with their cctype equivalents.
2014-03-12 20:51:06 -04:00
Lioncash
dccc6d8b47 Simplify boolean toggling in the TASInputDlg.
Also fixed the indentation for some code in a switch statement.
2014-03-12 10:12:29 -04:00
Matthew Parlane
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
Lioncash
932e3c1db2 [Android] Tidy up the dialog buttons that don't do anything.
All we want to do with these is dismiss the dialog. The same can be done by simply passing null.
2014-03-09 23:02:08 -04:00
Pierre Bourdon
8863eb0671 Merge pull request #145 from lioncash/split-about-activity
[Android] Split the AboutFragmentItem and InfoFragmentAdapter into their own class files.
2014-03-10 02:20:25 +01:00
Matthew Parlane
e05eca71ea Merge pull request #149 from lioncash/filemonitor-song-types
Add more sound file extensions to FileMonitor's IsSoundFile.
2014-03-10 13:45:23 +13:00
Tillmann Karras
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
Tillmann Karras
f28116b7da clang-modernize -add-override 2014-03-09 21:12:01 +01:00
Tillmann Karras
c89f04a7c5 clang-modernize -loop-convert
and some manual adjustments
2014-03-09 21:11:59 +01:00
Pierre Bourdon
f401263867 Merge pull request #152 from Tilka/float_stuff
Fix IsQNAN() and reduce code duplication
2014-03-09 21:06:19 +01:00
Pierre Bourdon
2632db8075 Merge pull request #153 from lioncash/dsptool-string
Fix DSPTool string output for disassembly.
2014-03-09 20:04:18 +01:00
Lioncash
76b2dde3d7 Fix DSPTool string output for disassembly.
Would previously print that assembly had succeeded.
2014-03-09 15:01:56 -04:00
Tillmann Karras
16885d0f74 Interpreter: less duplicate code in float compares 2014-03-09 19:35:13 +01:00
Tillmann Karras
9ef64245fa MathUtil: fix IsQNAN()
The constants were one nibble too short and the lower 51 bits don't
actually have to be zero.
2014-03-09 19:34:58 +01:00
Lioncash
e9d1796c24 Rename assemble.cpp/.h and disassemble.cpp./.h to DSPAssembler.cpp/.h and DSPDisassembler.cpp/.h 2014-03-09 13:25:50 -04:00
Lioncash
440efaa5f5 Fix DSPTool.
Forgot to adjust the stubs.
2014-03-09 13:00:51 -04:00
Lioncash
b027c4d64e Add more sound file extensions to FileMonitor's IsSoundFile. 2014-03-09 12:46:01 -04:00
Lioncash
db0596e088 Add a namespace to DSPHost.
Gets rid of the "DSPHost_" prefix in function names.
2014-03-09 12:30:13 -04:00
Tillmann Karras
d05e205a24 FPURoundMode: revert use of enums in bit-fields
The workaround of using fixed underlying types produces lots of warnings
in GCC because now the bit-fields are too small for the value range used
for conversion semantics.
2014-03-09 15:24:35 +01:00
Tillmann Karras
161b67076a Update android.toolchain.cmake
from https://raw.github.com/taka-no-me/android-cmake/master/android.toolchain.cmake
2014-03-09 15:24:33 +01:00
Tillmann Karras
aa7a2fc4bf Jit64::twx(): add assert message
The implemented and the real control flow differ a bit.
2014-03-09 15:24:33 +01:00
Tillmann Karras
17adcbb14e MMIOTest: fix sign warning 2014-03-09 15:24:32 +01:00
Pierre Bourdon
b003fd79d7 Merge pull request #146 from delroth/tests
Add more tests for Common and Core/MMIO
2014-03-09 14:51:53 +01:00
Pierre Bourdon
aabd524142 Add more tests for Common and Core/MMIO 2014-03-09 14:27:04 +01:00
Lioncash
53ed0051c8 [Android] Split the AboutFragmentItem and InfoFragmentAdapter into their own class files.
It doesn't make sense conceptually to keep them within the AboutActivity, as they are entirely self-contained classes.
2014-03-08 19:37:32 -05:00
Pierre Bourdon
0ea58cddf9 Merge pull request #144 from Parlane/fix_include_order
Fixes include order of TextureConversionShader.cpp
2014-03-09 01:34:50 +01:00
Lioncash
c5fb4ac96f [Android] Remove unnecessary comment from VideoSettingsFragment.
Misleading comment. We won't need to access index four for anything.
2014-03-08 19:08:26 -05:00
Matthew Parlane
25341f88ef Fixes include order of TextureConversionShader.cpp 2014-03-09 12:38:29 +13:00
Matthew Parlane
2e70ff2441 Add missing functional include caused by PR111 2014-03-09 12:28:58 +13:00
Matthew Parlane
d9ca5c83c9 Fix bug in PrintCallstack caused by trying to use MMIO
Also tidy up methods in Debugger_SymbolMap.cpp
2014-03-09 12:23:30 +13:00
Pierre Bourdon
8802770a85 JitUtil: Optimize MMIO loads by generating code to directly access a given MMIO. 2014-03-08 23:32:43 +01:00
Pierre Bourdon
edba8096bf x64Emitter: Add functions to call a C++ std::function from JITed code 2014-03-08 23:32:43 +01:00
Pierre Bourdon
9869c53859 x64ABI: Add two more CallFunction functions (for additional parameter types). 2014-03-08 23:32:43 +01:00
Pierre Bourdon
6d6abfa61f x64Emitter: Allow const pointers where it makes sense to do so. 2014-03-08 23:32:43 +01:00
Pierre Bourdon
71962ee0eb MMIO: Pass pointers to the complex method lambdas when visiting. 2014-03-08 23:32:43 +01:00
Pierre Bourdon
6b645f5cac MMIO: Add a function to check if a given address refers to MMIO registers. 2014-03-08 23:32:43 +01:00
Matthew Parlane
886060aaf7 Merge pull request #96 from lioncash/remove-console-correctly
Remove console correctly
2014-03-08 15:54:06 +13:00
Matthew Parlane
6704832f3d Merge pull request #139 from lioncash/wx-clean
Remove some superfluous arguments from some wx control creations
2014-03-08 15:50:34 +13:00
Matthew Parlane
ca6946bcbf Merge pull request #138 from Tilka/sw_fix
SW renderer: add missing ClearCurrent()
2014-03-08 15:50:05 +13:00
Pierre Bourdon
248f5d7f22 Merge pull request #130 from lioncash/breakpoint-clear
Actually make PPCDebugInterface::ClearAllBreakpoints have functionality.
2014-03-07 20:42:52 +01:00
Matthew Parlane
57f2eda130 Fix MAC address reading on Windows. 2014-03-07 21:40:59 +13:00
Shawn Hoffman
932945d480 Implement workaround for Windows versions which do not support XSAVE.
Fixes CRT math routines using FMA instructions from causing illegal instructions.
2014-03-06 14:38:10 -08:00
Shawn Hoffman
8995d299f2 windows: move arch defines to base.props 2014-03-06 14:37:40 -08:00
Lioncash
b2d47401b2 Remove some superfluous arguments from some wx control creations
wx has these as default parameters.
2014-03-05 23:02:34 -05:00
Lioncash
aa82680be7 Mark functions in the PPCDebugInterface and DSPDebugInterface as final.
The way they currently were, they would allow for a class to inherit and override these interfaces functions. However, this doesn't make sense conceptually.
2014-03-05 21:54:34 -05:00
Lioncash
610a6f9b23 Add ClearAllMemChecks to DebugInterface
Breakpoints have one, but memchecks don't, despite being cleared directly in the breakpoint window.

Now DolphinWX should call the interface functions and not the direct functions of the breakpoints or memchecks for clearing.
2014-03-05 21:50:23 -05:00
lioncash
96328902a5 Actually make PPCDebugInterface::ClearAllBreakpoints have functionality.
Fairly simple - just clear the breakpoints.
2014-03-05 20:27:27 -05:00
Tillmann Karras
d461b3f33c SW renderer: add missing ClearCurrent()
courtesy of degasus
2014-03-06 01:53:29 +01:00
Matthew Parlane
e5b250fa79 Merge pull request #122 from lioncash/rename-default
Rename the JIT function Default() to FallBackToInterpreter(). Communicates intent way better in terms of telling the reader what's going on.
2014-03-06 12:13:54 +13:00
Rachel Bryk
d06eb0f668 Fix reading revision specific default game inis in ISOProperties. 2014-03-05 17:05:36 -05:00
Shawn Hoffman
3647dfa711 Allow VS builds to be speedy again. 2014-03-05 11:17:14 -08:00
Shawn Hoffman
7733463e65 commit 1a428de189 introduced a bug by using a signed enum in a bitfield, the value of which is then used in a ldmxcsr instruction. The sign-extension corrupts the value, causing an exception by attempting to load mxcsr with an invalid value. 2014-03-05 10:19:29 -08:00
Ryan Houdek
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
lioncash
2c8b9735ae Add two other formats to the list of extensions in IsSoundFile
.adx is used in various games, so this should definitely be here.
2014-03-04 08:57:07 -05:00
lioncash
f39c757edf Simplify ShowSound() in FileMonitor.cpp.
Now if more sound types are found, they just need to simply be added to
the unordered set.

- Also changed ShowSound() to IsSoundFile()
- Fixed IsSoundFile’s definition in FileMonitor.h. This whole time it
has been defined as a void method, when in reality it was a bool
function.

- Changed the FileMonitor’s string parameters to be constant references.
2014-03-04 08:39:25 -05:00
Pierre Bourdon
6fa39c28fe Merge pull request #118 from neobrain/videosoftware-bypass-xfb-hack
Software renderer: Restore FifoPlayer support by emulating hardware backend behavior.
2014-03-03 19:05:35 +01:00
Tony Wasserka
1bdf232fed videosoftware: More coding style fixes. 2014-03-03 19:03:15 +01:00
Pierre Bourdon
91676ad930 Merge pull request #128 from lioncash/normalize-debug-interface-func-names
Change the DebugInterface, PPCDebugInterface, and DSPDebugInterface to use CamelCase function names.
2014-03-03 18:58:36 +01:00
Tillmann Karras
891b334f52 Fix 32 bit non-Windows build 2014-03-03 10:46:08 +01:00
Lioncash
279a8c0148 Change the DebugInterface, PPCDebugInterface, and DSPDebugInterface to use CamelCase names.
This is the standard coding convention in the codebase, so our interfaces should use it too.
2014-03-03 00:39:08 -05:00
Pierre Bourdon
32e0544088 Merge pull request #127 from lioncash/cheat-dlg-simplification
Make the base calculation in CheatsWindow simpler.
2014-03-03 04:16:43 +01:00
Lioncash
10f3d90f83 Make the base calculation in CheatsWindow simpler.
First and foremost this should test the checked state, not its direct value.
This should never have used multiplication at all. Seriously, what the hell?

The only values it would have given is true or false, so the only cases are 0*6 and 1*6.
2014-03-02 22:15:01 -05:00
Pierre Bourdon
177ef615d7 UnitTests: ensure the Binaries/Tests directory exists before linking. 2014-03-03 04:03:53 +01:00
Pierre Bourdon
9ea845310d Unittests: Always use GTest from Externals (recommended way from GTest FAQ). 2014-03-03 03:38:46 +01:00
Pierre Bourdon
2d71571be5 Do not hard fail when running 'make unittests' without GTest. 2014-03-03 03:12:58 +01:00
Matthew Parlane
6176424ac4 Merge pull request #119 from delroth/unittests
Add support for GTest based UnitTests
2014-03-03 14:53:24 +13:00
Lioncash
34b5a7871f Rename the JIT function Default() to FallBackToInterpreter(). Communicates intent way better in terms of telling the reader what's going on.
Also did some minor cleanup in functions that used Default.
2014-03-02 19:59:20 -05:00
Lioncash
445d257641 Fix a case where the wrong placeholders were being assigned for the up and down D-Pad buttons in the TAS dialog. 2014-03-02 18:58:54 -05:00
Pierre Bourdon
a4ee187711 Tests: Add more MMIO tests as an example. 2014-03-03 00:25:41 +01:00
Pierre Bourdon
d4ed4adace Add the infrastructure required to easily add unit tests and test it with a very simple test file. 2014-03-03 00:25:41 +01:00
Lioncash
13a007abed Remove another clamp function laying in the codebase and replace it with the one in MathUtil.h. 2014-03-02 13:57:27 -05:00
Matthew Parlane
70b3749d4b Merge pull request #109 from lioncash/file-io-clarifications
Eliminate the magic constants in the switch statement in WII_IPC_HLE_Device_FileIO.cpp's Seek function.
2014-03-02 18:29:48 +13:00
Tony Wasserka
c6c6d20014 videosoftware: Provide a more elaborate comment on the FifoPlayer support hack. 2014-03-01 18:52:19 +01:00
Scott Mansell
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
Lioncash
3bc082be52 Fix WII_SEEK_END seeking. 2014-02-28 19:56:42 -05:00
Tillmann Karras
7c93f2dc23 Fix the Windows build (broken in 315a8ba) 2014-03-01 01:33:19 +01:00
Pierre Bourdon
bc844a168f Merge pull request #100 from Tilka/misc_fixes
Misc fixes
2014-02-28 23:08:56 +01:00
Pierre Bourdon
1a7e3b3227 Merge pull request #80 from Tilka/dsp
DSP: add inline opcode documentation
2014-02-28 22:50:37 +01:00
Tillmann Karras
892012dc02 Remove own round() implementation
1. It's not correct, it rounds x.5 down to x.
2. It is visible across the whole project (!).
3. VS2013 finally supports this:
   http://msdn.microsoft.com/en-us/library/dn353646.aspx
   http://msdn.microsoft.com/en-us/library/dn329049.aspx
2014-02-28 12:43:23 +01:00
Tillmann Karras
7a66a3ded1 ArmEmitter: make it more readable 2014-02-28 12:43:22 +01:00
Tillmann Karras
46e7c0657f Crypto: small cleanup 2014-02-28 12:43:22 +01:00
Tillmann Karras
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
Tillmann Karras
5f0a8008f4 Convert MemoryUtil.cpp to Unix-style line endings 2014-02-28 12:28:21 +01:00
Tillmann Karras
1a428de189 x64FPURoundMode: move things around a bit 2014-02-28 12:28:21 +01:00
Tillmann Karras
6914eca167 Fix various warnings reported by clang
- mostly remove unused variables
- rename some generic JIT identifiers
2014-02-28 12:28:19 +01:00
Pierre Bourdon
ea34ae0a70 Merge pull request #113 from Parlane/fix_wifi
Randomise the mac address and store it in the config.
2014-02-28 11:25:29 +01:00
Matthew Parlane
c68cd3a8ea Randomise the mac address and store it in the config.
This stops error 20115 when trying to go online.
2014-02-28 22:53:00 +13:00
Pierre Bourdon
a3508823de Merge pull request #112 from Parlane/fix_ssl_init
Initialise entropy correctly for ssl.
2014-02-28 00:51:09 +01:00
Tony Wasserka
1f5b3c928f Merge pull request #108 from degasus/GLSLUtilShader
GLSL utility shader optimization
2014-02-27 22:38:37 +01:00
Matthew Parlane
e1ec4729b4 Initialise entropy correctly for ssl. 2014-02-27 21:46:14 +13:00
degasus
f628695d31 comment fixes 2014-02-26 12:48:52 +01:00
Tony Wasserka
66d1f16f98 Merge pull request #107 from lioncash/tiny-cleanup
Tiny cleanup of WII_IPC_HLE.cpp.
2014-02-26 12:46:49 +01:00
degasus
aaaa5af0b2 remove (ATTR|VARY)(IN|OUT) macros 2014-02-26 11:37:29 +01:00
degasus
1d0b6a1156 Merge duplicate parts of sampler into header 2014-02-26 11:37:29 +01:00
degasus
11efa88157 calculate constant values on shader compilation 2014-02-26 11:37:29 +01:00
degasus
8a4aa8c1f5 Rewrite texture tiling implementation
inline halfxb

So we know which is the first pixel by masking.

inline xl

inline xb a bit

inline yl

inline uv1.x shift

remove likely wrong guessed ternary operator

add pixel layout comment

inline xel

optimize the shifts a bit

inline xb

optimize shifts in a second step

extract xb

rename all variables

calculate cache line by position.x

Revert 5115b459f40d53044cd7a858f52e6e876e1211b4 "optimize the shifts a bit"

It seems I was wrong, the other way is the more natural.

use x_virtual_position instead of uv1.x for x_offset_in_block

This looks more natural and the offset should be masked anyway.

substitude factor with cache_lines

move 32bit logic in a conditional block
2014-02-26 11:37:29 +01:00
degasus
bd3beeb184 TextureConverter: Use Log2() and shifts instead of multiplications/divisions 2014-02-26 11:37:29 +01:00
degasus
94da4e1aa2 MathUtil: Change Log2 return value to int
Log2(u64) can't be bigger than 63, so there is no need in forcing a 64 bit value.
So just using a common int seems more natural.
2014-02-26 11:37:28 +01:00
degasus
f99c8a0b70 merge common parts of encoding shaders 2014-02-26 11:37:28 +01:00
degasus
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
Lioncash
d5fd68e4a4 Eliminate the magic constants in the switch statement in WII_IPC_HLE_Device_FileIO.cpp's Seek function. 2014-02-24 15:01:08 -05:00
Lioncash
4094c35203 Tiny cleanup to WII_IPC_HLE.cpp.
- Inlined loop vars in statements where possible.
- Eliminate some explicit iterators with foreach loops.
- Kill off some newlines that weren't necessary.
2014-02-24 14:09:42 -05:00
Tillmann Karras
33beaf20f3 PolarSSL: adapt Dolphin to new version
- strip down PolarSSL's CMakeLists.txt
- switch to the PolarSSL 1.3 API
- use entropy interface instead of havege (PolarSSL 1.3 has disabled
  havege by default because it is "considered unsafe for primary usage")
- add VS2013 .vcxproj file
2014-02-24 16:20:50 +01:00
Pierre Bourdon
7be3dae988 Merge pull request #106 from lioncash/unnecessary-cstr
Unnecessary c_str() call in WII_IPC_HLE_Device_es.cpp's OpenTitleContent function.
2014-02-24 15:56:34 +01:00
Lioncash
98d2e76fcc Unnecessary c_str call in WII_IPC_HLE_Device_es.cpp's OpenTitleContent function.
m_ContentFile is a string, so it's kind of pointless to pass a c_str of a string to constructor of a new string.
2014-02-24 08:32:45 -05:00
degasus
8af3f751db Fetch swapInterval function pointer after binding a context
This fixes vsync on windows
2014-02-24 12:45:02 +01:00
Ryan Houdek
21bb722c93 Merge pull request #101 from delroth/remove-tests
Remove Source/{Unittests,TestSuite}.
2014-02-24 02:43:32 -06:00
Ryan Houdek
2bd1f99125 Fix the nogui build when building with EGL 2014-02-24 06:34:09 +00:00
Lioncash
e71db8fe04 In UCode_AX.cpp in function HandleCommandList() - case CMD_MIX_AUXB_NOWRITE should have 1 being passed, not false, as the aux ID in MixAUXSamples. 2014-02-23 17:22:20 -05:00
Pierre Bourdon
0f89060cf3 Remove Source/{Unittests,TestSuite}.
These directories have been unused for several years and without any automated
way of running the tests, they are pretty much useless.

While they might be useful as a reference, in their present state they should
not be kept in the repository.
2014-02-23 22:36:32 +01:00
Pierre Bourdon
99db9f0fb1 Merge pull request #94 from Tilka/uninitialized
Fix struct initialization
2014-02-23 17:07:24 +01:00
Pierre Bourdon
4a569c4449 Merge pull request #97 from delroth/mmio-gpfifo
WriteToHardware: Pass through the whole 0xCC008xxx area to GPFifo instead of only 0xCC008000.
2014-02-23 10:20:56 +01:00
Lioncash
e3e78128a2 isSameValue in IR.cpp/.h should be returning a boolean value. 2014-02-23 04:14:57 -05:00
Lioncash
679a1bb2eb WII_IPC_HLE_Device_usb_kbd.cpp's Update method should return 0, not false, it communicates the wrong intent otherwise. 2014-02-23 04:08:52 -05:00
Pierre Bourdon
86326de6f6 WriteToHardware: Pass through the whole 0xCC008xxx area to GPFifo instead of only 0xCC008000. 2014-02-23 10:01:47 +01:00
Lioncash
8d57f38be7 Purge wx elements of the console. 2014-02-23 03:12:24 -05:00
Pierre Bourdon
c06c8f0ec8 MMIO: Fix a megaderp in the UniqueID function causing handlers to be overwritten by other handlers. 2014-02-23 08:34:05 +01:00
Pierre Bourdon
b8582b00a9 MMIO: Pass the provided high part/low part addrs to handlers in {Read,Write}ToSmaller. 2014-02-23 08:33:27 +01:00
Pierre Bourdon
803c110e30 MMIO: Show the read/write size in invalid handlers. 2014-02-23 08:32:52 +01:00
Lioncash
d45351a43f Initial removal of the actual console functionality on windows. 2014-02-23 02:01:35 -05:00
Pierre Bourdon
70f3a069f2 Revert "Merge pull request #83 from lioncash/remove-console"
This breaks Linux stdout logging.

This reverts commit 7ac5b1f2f8, reversing
changes made to 9bc14012fc.

Revert "Merge pull request #77 from lioncash/remove-console"

This reverts commit 9bc14012fc, reversing
changes made to b18a33377d.

Conflicts:
	Source/Core/Common/LogManager.cpp
	Source/Core/DolphinWX/Frame.cpp
	Source/Core/DolphinWX/FrameAui.cpp
	Source/Core/DolphinWX/LogConfigWindow.cpp
	Source/Core/DolphinWX/LogWindow.cpp
2014-02-23 07:48:06 +01:00
Ryan Houdek
60a5d8900b Merge pull request #60 from Sonicadvance1/Android-GLDetect
Fix the Android OpenGL About tab.
2014-02-22 22:29:57 -06:00
Tillmann Karras
3038bca0a4 JitBackpatch: initialize InstructionInfo to 0
DisassembleMov() doesn't always initialize all fields of 'info'.
2014-02-23 04:36:26 +01:00
Pierre Bourdon
311caef094 Merge pull request #25 from Tilka/ppc_fp
Fix non-IEEE mode
2014-02-23 04:15:37 +01:00
Tillmann Karras
ee21cbe2d1 Add phire's more accurate DoubleToSingle version
This method doesn't involve messing around with the quirks of the x87
FPU and should be reasonably fast. As a bonus, it does the correct thing
for out-of-range doubles.

However, it is also a little slower and only benefits programs that rely
on undefined behavior so it is disabled for now.
2014-02-23 04:13:47 +01:00
Ryan Houdek
1f750904af Fix the OpenGL About tab.
Move EGLHelper to be local to the creation of the about GL/GLES tabs so we don't have 3 EGL contexts running at a time.
Fix issues with OpenGL context creation here so we show the correct information.
This requires adding an EGL function to the NativeLibrary since Android's JAVA bindings don't expose eglBindAPI.
2014-02-22 21:08:27 -06:00
Pierre Bourdon
f9ed70b2f9 Merge pull request #85 from Sonicadvance1/Android-OSXpain
Make it possible to build Dolphin for Android in OS X and also less of a pain with gradle.
2014-02-23 04:05:42 +01:00
Ryan Houdek
cf6e0b6015 Make it possible to build Dolphin for Android in OS X and also less of a pain with gradle. 2014-02-22 21:01:58 -06:00
Pierre Bourdon
4ba9cb217f Fix a compilation error introduced in PR #91.
For some reason it passed builbot-try but didn't build after being merged to
msater. Did not expect that, sorry :(
2014-02-23 03:45:46 +01:00
Pierre Bourdon
7cabe1772e Merge pull request #91 from delroth/iwyu
Include-what-you-use suggested fixes.
2014-02-23 03:34:10 +01:00
Pierre Bourdon
f344a43657 Make DolphinWX/ mostly IWYU clean. 2014-02-23 00:27:27 +01:00
Pierre Bourdon
c698c07755 Make DiscIO/ mostly IWYU clean (and fix errors in rest of the project detected by this change). 2014-02-22 23:37:29 +01:00
Pierre Bourdon
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
Tillmann Karras
79336c88f8 Remove X11InputBase (dead code) 2014-02-22 22:42:42 +01:00
Pierre Bourdon
6d8df311a3 Merge pull request #88 from lioncash/relative-includes
Relative includes
2014-02-20 02:08:44 +01:00
Lioncash
24ba058404 Fix the Windows build for the final time. 2014-02-19 19:38:23 -05:00
Lioncash
c1a934f7ed Fix the Android build.
Required the removal of EGL.h from EGL.cpp.

Removed the similar includes from AGL.cpp, GLX.cpp, and WGL.cpp to retain consistency.
All GL interfaces are now centralized on GLInterface.h
2014-02-20 01:01:11 +01:00
Lioncash
ed9eea72a1 Forgot to move DSPTool over. Fixed now. 2014-02-20 01:01:11 +01:00
Lioncash
91286f5021 Fix the Windows build in relation to the recent changes. 2014-02-20 01:01:11 +01:00
Lioncash
146b301a91 Fix more header sorting issues in Core/ (now check-includes clean). 2014-02-20 01:01:11 +01:00
Pierre Bourdon
9a8ea53195 Fix LinearDiskCache.h relying on a file not directly included. 2014-02-20 01:01:11 +01:00
Pierre Bourdon
425f9dcd51 Fix more header sorting issues in VideoBackends/ (now check-includes clean). 2014-02-20 01:01:11 +01:00
Pierre Bourdon
592ebc5262 Fix more header sorting issues in DolphinWX/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Pierre Bourdon
ffe588cc24 Fix more header sorting issues in VideoCommon/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Pierre Bourdon
6847a0fc0c Fix more header sorting issues in InputCommon/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Pierre Bourdon
fca12c4c4e Fix more header sorting issues in AudioCommon/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Pierre Bourdon
8ea8da6ebc Fix more header sorting issues in DiscIO/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Pierre Bourdon
3f9c38d231 Fix more header sorting issues in Common/ (now check-includes clean). 2014-02-20 01:01:10 +01:00
Lioncash
edb43cfe61 Fix the OSX build.
Turns out Dolphin uses some macros that clash on OSX. However thankfully, this include is only used in Frame.cpp.
2014-02-18 19:08:17 -05:00
Lioncash
eee549f92b Scope the Windows include directory to only point to Source/Core/.
Also fix the Windows build with this change.
2014-02-18 13:21:12 -05:00
Rachel Bryk
b1f77d0191 Save frame skipping option, and allow loading it from game ini too. 2014-02-18 12:25:11 -05:00