Commit Graph

16162 Commits

Author SHA1 Message Date
JosJuice 41101be545 Merge pull request #4611 from lioncash/fileutil
IOFile: Minor changes
2017-01-05 09:17:03 +01:00
Lioncash 045a8400e6 IOFile: Make the move constructor and move assignment operator noexcept
Certain parts of the standard library try to determine whether or not a
transfer operation should either be a copy or a move. The prevalent notion
of move constructors/assignment operators is that they should not throw,
they simply move an already existing resource somewhere else.

This is typically done with 'std::move_if_noexcept'. Like the name says,
if a type's move constructor is noexcept, then the functions retrieves an
r-value reference (for move semantics), or an l-value (for copy semantics)
if it is not noexcept.

As IOFile deletes the copy constructor and copy assignment operators,
using IOFile with certain parts of the standard library can fail in
unexcepted ways (especially when used with various container
implementations). This prevents that.
2017-01-04 18:37:48 -05:00
Lioncash 9b8f5bce22 IOFile: Change 'operator void*' into 'explicit operator bool'
'operator void*' is basically a pre-C++11-ism that was used, as C++03
only had the notion of implicit type-conversion operators, but not explicit type
conversion operators (allowing implicit conversion of a file handle to
bool can go downhill pretty quickly).
2017-01-04 18:10:21 -05:00
Lioncash c541e1099e IOFile: Make class variables private
Internals shouldn't be directly exposed.
2017-01-04 17:48:46 -05:00
Lioncash c21dad9e83 IOFile: Get rid of unnecessary unimplemented copy constructor/assignment operator.
IOFile already inherits NonCopyable.
2017-01-04 17:47:40 -05:00
Lioncash 5b1aae0cbf DiscScrubber: Make struct and variable names conformant to the coding style 2017-01-04 17:04:41 -05:00
Lioncash 4a9bc2340b DiscScrubber: Convert into a class
Allows potential multiple scrubbers to run at once. Also gets rid of the
need to explicitly clean up resources.
2017-01-04 16:06:21 -05:00
degasus 41b0c74e30 VideoCommon: Make dst_alpha state implicit. 2017-01-04 20:02:31 +01:00
degasus b7d8bd13a6 OGL/Vulkan: Drop dual pass alpha. 2017-01-04 19:59:41 +01:00
Lioncash 2cfc0dc8b6 DSPDisassembler: directly initialize AssemblerSettings struct members
Same thing, less code.
2017-01-04 12:53:22 -05:00
Markus Wick 9f164d7c33 Merge pull request #4593 from lioncash/enum
JitRegCache: Move FlushMode enum into RegCache
2017-01-04 16:21:21 +01:00
Lioncash 5518c6625b PatchEngine: Get rid of a global variable 2017-01-03 18:59:33 -05:00
Stenzek 18792b2328 FifoPlayer: Don't set BPMEM_PRELOAD_MODE on load
Since in this case we're setting it based on the state at record start
time, not when a register is loaded, UseMemory would not be called, so
this could potentially wipe out texture memory that was valid.
2017-01-03 21:16:05 +10:00
Stenzek 5f3c878ba2 FifoPlayer: Save/restore texture memory state for fifo logs 2017-01-03 21:16:05 +10:00
Stenzek 438989668e FifoDataFile: Add support for storing texture memory state
This bumps the file version to 4.
2017-01-03 21:16:04 +10:00
Stenzek 5b315b7bb4 FifoPlayer: Reload initial state when looping back to first frame
This should ensure that when playing with loop enabled, the first frame is
in the same state each time. There is potentially still issues when the
start frame is set to something other than zero, but I'm not sure how we
could work around this without capturing the entire state on each frame.
2017-01-03 17:32:45 +10:00
Lioncash f8c6b3b5f1 JitRegCache: Move FlushMode enum into RegCache
This also makes it a strongly-typed enum.

Considering that the flushing mode is a trait/behavior for the register
cache, it doesn't really make sense to have the enum separate from it.

This also has the benefit of removing constants from global scope.
2017-01-02 13:43:37 -05:00
Lioncash 3b4290b5b7 DSPJitRegCache: Make class variables conform to the coding style 2017-01-02 12:16:29 -05:00
Markus Wick 6aef0630f7 Merge pull request #4588 from JosJuice/isoproperties-title-encoding
ISOProperties: Fix encoding errors in window title
2017-01-02 12:33:58 +01:00
Markus Wick 96314a0ec1 Merge pull request #4574 from stenzek/vulkan-alpha-clear
Vulkan: Clear alpha channel to 0 when pixel format has no alpha channel
2017-01-02 12:29:36 +01:00
Anthony b46dcc7768 Merge pull request #4495 from slashiee/dump-textures-hotkey
Add a hotkey for toggling texture dumps
2017-01-01 17:28:56 -08:00
Mat M 3f5f7fc564 Merge pull request #4590 from hthh/macos-no-pch-fix
macOS: Add missing includes to fix no-PCH build
2017-01-01 20:27:30 -05:00
Anthony a7f7ccc9d2 Merge pull request #4523 from RisingFog/overwrite_audio_warning
Display warning when dumping audio if file exists
2017-01-01 17:20:39 -08:00
hthh 387164a999 macOS: Add missing includes to fix no-PCH build 2017-01-02 11:45:24 +11:00
Mat M b10a0de769 Merge pull request #4535 from lioncash/regcache
Jit64: Make register caches not rely on the global jit variable
2017-01-01 18:01:29 -05:00
Mat M 6c5063c76b Merge pull request #4585 from lioncash/dspnamespace
DSP: Namespace remaining un-namespaced DSP code
2017-01-01 17:54:39 -05:00
Anthony 4c90ad7514 Merge pull request #4490 from leoetlino/wii-dsy
Add common Wii SDK function signatures to the signature DB
2016-12-31 16:31:50 -08:00
Anthony e8052fbf78 Merge pull request #4587 from aldelaro5/fix-hidpi-mic
Add an empty spacer in the Mic Input config dialog
2016-12-31 16:24:46 -08:00
JosJuice 65d88776db ISOProperties: Fix encoding errors in window title
It seems to be a regression, but I haven't bisected it.
2017-01-01 00:34:29 +01:00
aldelaro5 d6674223db Fix some margin discrepancies 2016-12-31 17:58:39 -05:00
Lioncash 3eb25cea6f DSP: Namespace remaining un-namespaced DSP code 2016-12-31 17:20:14 -05:00
aldelaro5 42e4dde960 Add an empty spacer in the Mic Input config dialog
This is done to not have the device combo box be too small in width when making the main sizer fit into the window.  Not fitting the sizer would alternatively break Hidpi so it was best to just add an empty sizer to workaround this problem.
2016-12-31 16:17:47 -05:00
JosJuice 15de7d507f Merge pull request #4519 from sepalani/fix_import_save
Fixes WiiSave import
2016-12-31 12:33:45 +01:00
Jules Blok a2e191649d Merge pull request #4471 from Armada651/hybrid-depth
VideoCommon: Don't process the depth range in the vertex shader if it's not oversized.
2016-12-29 18:49:27 +01:00
Lioncash efbf261e97 DSPAnalyzer: Fix two clang warnings about sign mismatched types 2016-12-29 10:10:38 -05:00
Lioncash 2aefa29941 DSP: Add the interpreter to the DSP namespace 2016-12-29 07:05:17 -05:00
Lioncash c79cc3f470 DSP: Namespace the JIT 2016-12-28 20:38:41 -05:00
Lioncash 407f3af8c3 JitRegCache: Get rid of reliance on the jit global variable 2016-12-28 17:52:58 -05:00
Lioncash 8ece485a2f JitRegCache: Make member variables conform to our coding style 2016-12-28 17:47:26 -05:00
Lioncash e291e8f1a7 JitRegCache: Convert #define macro into a typed constant 2016-12-28 17:47:26 -05:00
Lioncash 4ae23fc45c JitRegCache: Remove unused typedefs 2016-12-28 17:47:26 -05:00
Lioncash b629eb300a JitRegCache: Remove unused Flush function
This was kind of a pointless function, considering the parameter wasn't
used at all, so the other Flush() function could have been just directly
used instead.
2016-12-28 17:47:26 -05:00
Lioncash 41d47dda93 JitRegCache: Move implementation details into the cpp file where applicable
Any future changes to these register cache functions won't require everything that includes the register cache header to also be recompiled.
2016-12-28 17:47:26 -05:00
Lioncash d1fc694c02 JitRegCache: Move protected interface below public interface 2016-12-28 17:47:26 -05:00
Lioncash 1a34376f3a JitRegCache: Separate FPURegCache and GPRRegCache into their own files
Keeps them separated from one another and makes it less annoying to find
member functions (which were previously spread out all over the place).
2016-12-28 17:47:25 -05:00
Markus Wick 10b4f6a250 Merge pull request #4568 from degasus/texcache
TextureCache: Add a dirty bit for partial updates on overlapping EFB copies.
2016-12-28 16:38:16 +01:00
Michael Maltese 905750553f ControllerEmu: Fix LoadDefaults to use ciface argument 2016-12-27 17:46:40 -08:00
Lioncash 5c938ed41f DSPTables: Move function type aliases into DSPOPCTemplate
Gets two typedefs out of global scope
2016-12-27 18:31:42 -05:00
Jules Blok ee7a2edf35 Update comments 2016-12-27 21:32:52 +01:00
Jules Blok 65b5765858 VideoBackends: Clamp the range to the maximum depth value supported in the z buffer. 2016-12-27 20:25:40 +01:00