Commit Graph

17136 Commits

Author SHA1 Message Date
Léo Lam 35995e98d7 IOS/ES: Fix GetTitles implementation
IOS determines installed titles by looking at /title, not uid.sys,
which is more like a history of installed titles. And it does not care
at all about the installed TMD (or even if it is present at all).
2017-03-04 20:33:34 +01:00
Markus Wick 7304cb0f8e Merge pull request #5011 from stenzek/d3d-texture-corruption
D3D11: Use default usage for TextureCache entries
2017-03-04 15:55:58 +01:00
Stenzek 725d5bc3a1 D3D11: Drop unused method ReplaceRGBATexture2D 2017-03-04 22:37:10 +10:00
Stenzek 526fa9bc85 D3D11: Use D3D11_USAGE_DEFAULT for all TextureCache textures 2017-03-04 22:36:33 +10:00
Markus Wick 3c511f2a94 Merge pull request #5003 from lioncash/memory
UICommon: Make GetNewDisassembler() return a unique_ptr
2017-03-04 12:14:35 +01:00
Markus Wick 01143d761e Merge pull request #5006 from lioncash/settings
ControllerEmu: Initialize settings class' values to default values on construction
2017-03-04 12:13:24 +01:00
Stenzek 4cea9a2f99 Vulkan: Fix underflow in StreamBuffer::WaitForClearSpace
This could cause the assertion on line 212 to fail when uploading large
amounts of data in between command buffer executions.
2017-03-04 18:07:04 +10:00
Stenzek 459a5ab554 Android: Move screenshot waiting logic to Renderer 2017-03-04 16:53:16 +10:00
Stenzek 811eafda57 VideoCommon: Store last window request width/height
This avoids the need to send a window resize event every frame.
2017-03-04 16:53:12 +10:00
Stenzek 00a0a91513 VideoCommon: Move last EFB scale handling to CalculateTargetSize 2017-03-04 16:53:07 +10:00
Stenzek afc25fdca0 VideoCommon: Rename Renderer s_ prefixes to m_ 2017-03-04 16:42:21 +10:00
Stenzek 238a70b006 VideoCommon: Move some common initialization logic to RenderBase 2017-03-04 16:42:16 +10:00
Stenzek 277829d842 VideoCommon: Eliminate static state in Renderer 2017-03-04 16:39:50 +10:00
Anthony de230f3ebe Merge pull request #4998 from stenzek/vulkan-aspect-changes
Vulkan: Fix issue where target rectangle changes weren't detected
2017-03-03 21:47:29 -08:00
Lioncash 552c0d8404 Common: Move byte swapping utilities into their own header
This moves all the byte swapping utilities into a header named Swap.h.

A dedicated header is much more preferable here due to the size of the
code itself. In general usage throughout the codebase, CommonFuncs.h was
generally only included for these functions anyway. These being in their
own header avoids dumping the lesser used utilities into scope. As well
as providing a localized area for more utilities related to byte
swapping in the future (should they be needed). This also makes it nicer
to identify which files depend on the byte swapping utilities in
particular.

Since this is a completely new header, moving the code uncovered a few
indirect includes, as well as making some other inclusions unnecessary.
2017-03-03 17:18:18 -05:00
Lioncash b592e4887e BooleanSetting: Initialize m_value to default_value in the constructor
Ensures all class state is initialized to valid values on construction.
2017-03-03 14:09:48 -05:00
Lioncash 25e70570b5 NumericSettings: Initialize m_value to default_value in the constructor
Ensures that all class state is initialized to valid values.
2017-03-03 14:06:16 -05:00
Lioncash 13757b7d35 UICommon: Make GetNewDisassembler() return a unique_ptr
Much better than just returning raw memory.
2017-03-02 21:26:17 -05:00
Matthew Parlane 51e932b4ec Merge pull request #4975 from ligfx/controlsetting
InputCommon: move Setting classes out of ControlGroup
2017-03-03 15:17:25 +13:00
Michael Maltese 1539ff6691 InputCommon: move Setting classes out of ControlGroup 2017-03-02 18:08:37 -08:00
Anthony 1392b88879 Merge pull request #5002 from leoetlino/es-di-ioctlvs
IOS/ES: Implement ES_DIGetTicketView
2017-03-02 17:54:54 -08:00
Matthew Parlane dffb14cfc7 Merge pull request #5000 from lioncash/fwd
JitInterface: Convert includes into forward declarations where applicable
2017-03-03 14:54:24 +13:00
Léo Lam 34adc72d1c IOS/ES: Implement ES_DIGetTicketView
One of the remaining ioctlvs that were not implemented, and which were
used by games (even though they did not really depend on the view).
2017-03-02 22:13:45 +01:00
Léo Lam d97ae1054f Remove useless ES wrappers from the main IOS file
This removes wrappers for ES_DIVerify and ES::LoadWAD. They are not
really useful as we can simply call the ES function directly, and
it is actually somewhat confusing because both functions are static
and are not tied to a particular ES instance.
2017-03-02 20:29:01 +01:00
Léo Lam 5a74343d06 IOS/ES: Add logging for title context changes 2017-03-02 20:29:01 +01:00
Léo Lam c191fe5348 IOS/ES: Update running game info on title change
This allows Dolphin to stay up-to-date about what title is currently
running, which fixes savestates, screenshots, etc. after an ES_Launch.

Same limitation as with MIOS: currently, GameINIs are not reloaded,
because it's a pain with the current config system. It'll happen
when the new config system is done, and this commit makes it much
easier to do!
2017-03-02 20:29:00 +01:00
Léo Lam 9c18eea812 IOS/ES: Mark members shared between instances as static
Some members are shared between ES instances, and they are just global
variables in IOS.

This is more efficient than getting the installed titles or setting the
current active title tons of times for no reason.
2017-03-02 20:29:00 +01:00
Léo Lam 4d776ffa8f IOS/ES: Keep track of the active title properly
This changes ES to keep track of the active title properly,
just like IOS:

* It is NOT changed on resource manager open/close.
* It is reset on IOS reload.
* It is changed by ES_DIVerify and ES_Launch.

IOS stores the active title in a structure like this:

    struct ESTitleContext
    {
      Ticket* ticket;
      TMD* tmd;
      u32 active;
    };

With this commit, we also do keep the Ticket and TMD around. This
makes some of the DI ioctlvs (which return data about the current
active title) trivial to implement in the future.

This fixes the System Menu not being able to see update partitions
and also allows us to change Dolphin's active game info in the future.
2017-03-02 20:28:01 +01:00
Mat M 78e7f4aae3 Merge pull request #4984 from leoetlino/content-fixes
IOS/ES: Title import fixes + hack removals (fix for System Menu disc updates)
2017-03-02 14:17:29 -05:00
Lioncash c6200a5b07 JitInterface: Convert includes into forward declarations where applicable 2017-03-02 13:20:29 -05:00
Stenzek 2fd77895a2 Vulkan: Fix issue where target rectangle changes weren't detected
This was causing issues when toggling the crop setting, as well as some
widescreen hacks.
2017-03-02 21:53:42 +10:00
Stenzek 3390e6f258 Merge pull request #4993 from ligfx/fixsonicadventure2
OGL SetBlendMode: always set blend equation and func
2017-03-02 21:30:10 +10:00
Markus Wick 7982ba120f Merge pull request #4995 from lioncash/normalize
CMakeLists: Normalize whitespace
2017-03-02 11:51:06 +01:00
Markus Wick 521a777ade Merge pull request #4961 from aldelaro5/fast-memchecks
Make memory breakpoint faster
2017-03-02 11:13:18 +01:00
aldelaro5 9ad6c8f334 Make memory breakpoint faster
Currently, slowmem is used at any time that memory breakpoints are in use.  This commit makes it so that whenever the DBAT gets updated, if the address is overllaping any memchecks, it forces the use of slowmem.  This allows to keep fastmem for any other cases and noticably increases performance when using memory breakpoints.
2017-03-02 04:46:27 -05:00
Lioncash ee61bd6f2e CMakeLists: Normalize whitespace
Normalizes tabs to spaces to follow our codebase's indentation style.
2017-03-01 14:53:23 -05:00
Léo Lam ac27aff9c8 Add ES::Content::IsShared to avoid hardcoding 0x8000 2017-03-01 17:36:07 +01:00
Léo Lam 3bd34008c9 IOS/ES: Fix GetTMDView when title doesn't exist
This fixes ES_GetTMDView and ES_GetTMDViewSize to return -106
(FS_ENOENT) if the title does not exist (and more specifically when no
TMD exists in the NAND). This allows installed (or not installed) IOSes
to be detected properly.
2017-03-01 17:36:07 +01:00
Léo Lam 90aaefaef7 IOS/ES: Drop 'fake IOS titles' hack
It prevents system updates from working properly, because we always
returned that the latest version of every single IOS was installed.
2017-03-01 17:36:07 +01:00
Léo Lam e5d9bcaf43 IOS/ES: Edit uid.sys on AddTitleStart
This allows channels to be registered and installed properly.
(And it is what IOS does.)
2017-03-01 17:36:07 +01:00
Léo Lam 1e3f8c1a1d IOS/ES: Add sanity checks to AddTitleFinish 2017-03-01 17:36:06 +01:00
Léo Lam 9263cb1996 IOS/ES: Handle adding shared contents properly 2017-03-01 17:34:59 +01:00
Mat M 8364a0002f Merge pull request #4956 from leoetlino/es-checks
ES: Replace useless asserts with proper checks
2017-03-01 11:30:25 -05:00
Anthony 8dc96fce4d Merge pull request #4776 from lioncash/dspemitter
DSPEmitter: Convert a C array to a std::array
2017-03-01 08:11:26 -08:00
Léo Lam 24e35f96fa ES: Replace useless asserts with proper checks
It makes absolutely no sense to have asserts for what is obviously an
error condition. And they should definitely not cause Dolphin to crash
because it assumes that everything is valid, and Dolphin should not
report those to the user either, as it is very obviously a bug in the
emulated software and there is nothing the user (or we) can do.

This commit replaces all of the request asserts with proper checks
and adds missing checks for some ioctlvs. We still do not check sizes
yet; this will be done later.
2017-03-01 16:05:33 +01:00
Michael Maltese db1d826ac3 OGL SetBlendMode: always set blend equation and func
Before #4581, an invocation of `SetBlendMode` could invoke
`glBlendEquationSeparate` and `glBlendFuncSeparate` even when it was
setting `glDisable(GL_BLEND)`. I couldn't figure out how to map the old
behavior over to the new BlendingState code, so I changed it to always
call the two blend functions.

Fixes https://bugs.dolphin-emu.org/issues/10120 : "Sonic Adventure 2
Battle: graphics crash when loading first Dark level".
2017-03-01 00:49:14 -08:00
Jules Blok 83bd74aef0 Merge pull request #4974 from gamemasterplc/master
Widescreen Hack improvement
2017-03-01 02:17:33 +01:00
aldelaro5 52fe05af6b Make memory breakpoint faster
Currently, slowmem is used at any time that memory breakpoints are in use.  This commit makes it so that whenever the DBAT gets updated, if the address is overllaping any memchecks, it forces the use of slowmem.  This allows to keep fastmem for any other cases and noticably increases performance when using memory breakpoints.
2017-02-28 13:02:04 -05:00
Anthony f4ccc11b73 Merge pull request #4988 from leoetlino/tikview
ESFormats: Fix calculation of the ticket start offset
2017-02-28 09:57:04 -08:00
Markus Wick 0a8b5b79ef Merge pull request #4985 from lioncash/enum-class
ExpressionParser: Convert parse state enum into an enum class
2017-02-28 18:48:45 +01:00
Markus Wick bd89c7b2c4 Merge pull request #4986 from lioncash/namespace
PixelEngine: Move enum constants into the PixelEngine namespace
2017-02-28 18:46:45 +01:00
Léo Lam e9f23fbc92 ESFormats: Fix calculation of the ticket start offset
The signature part doesn't seem to appear more than once in a signed
ticket, so we should always add that offset regardless of the
ticket number.
2017-02-28 18:42:06 +01:00
Anthony fcc05c0b0e Merge pull request #4983 from degasus/jitcache
JitCache: Fix two block invalidation issues.
2017-02-28 09:20:24 -08:00
Lioncash 5ed55ffb34 PixelEngine: Move enum constants into the PixelEngine namespace
Gets some identifier names out of the global namespace.
2017-02-28 07:01:50 -05:00
Lioncash d104e5e916 ExpressionParser: Convert parse state enum into an enum class 2017-02-28 05:07:21 -05:00
Vlad Firoiu a3af5b09d3 error logs 2017-02-27 23:45:35 -08:00
Vlad Firoiu 6b1910a078 Appease global header warning. 2017-02-27 23:45:35 -08:00
Vlad Firoiu f82e3de763 Dump to arbitrary URLs. 2017-02-27 23:45:34 -08:00
Vlad Firoiu 21e66e60e3 Configable dump codec. 2017-02-27 23:45:12 -08:00
Vlad Firoiu a1a9e488a5 XVID FourCC for MPEG-4 codecs. 2017-02-27 23:44:33 -08:00
Vlad Firoiu d4686aa1a7 More warnings for AVIDump. 2017-02-27 23:44:33 -08:00
Vlad Firoiu 86a8382376 Arbitrary dump formats. 2017-02-27 23:44:29 -08:00
Vlad Firoiu 1723645c99 guess format before allocating context 2017-02-27 23:43:15 -08:00
Vlad Firoiu 8fb2eb889d Handle delayed frames at the end of the movie. 2017-02-27 23:43:15 -08:00
Anthony e375c96693 Merge pull request #4982 from leoetlino/copy
ESFormats: Fix GetRawTicketView
2017-02-27 17:08:27 -08:00
Markus Wick deb228f134 Merge pull request #4774 from degasus/speedhack
PatchEngine: Apply speedhack per PC, not only per block entry.
2017-02-27 23:51:12 +01:00
degasus ffa61fcf57 JitCache: Also unlink exits of the current block.
We might still be in the current block. This is fine, but the next one might also be invalidated later on. But we may never also call the next one.
2017-02-27 23:50:16 +01:00
degasus c1ddc2678e JitCache: Fix removing of blocks. 2017-02-27 23:50:16 +01:00
Léo Lam 6edcba4af8 Bump the savestate version (for ES changes) 2017-02-27 21:26:30 +01:00
Léo Lam 6f79f741d5 IOS/ES: Check that m_addtitle_tmd is valid before use 2017-02-27 21:26:29 +01:00
Léo Lam 95aa48d086 IOS/ES: Implement AddTMD 2017-02-27 21:26:29 +01:00
Léo Lam 6327a29847 IOS/ES: Implement ES_Export* ioctlvs
This should allow channels to be copied to the SD properly.
2017-02-27 21:26:28 +01:00
Léo Lam 345d252ef3 IOS/ES: Deduplicate fields for opened content entries
Now that we have a proper Content structure for contents,
let's just use it instead of duplicating the fields.
2017-02-27 21:25:47 +01:00
Léo Lam 4e462d44f9 ESFormats: Fix GetRawTicketView
The vector was not constructed with the proper size, which results in a
buffer overflow as we were using memcpy.

This commit fixes that mistake and also uses a safer way of copying the
ticket view data (std::vector::insert instead of memcpy).
2017-02-27 21:19:05 +01:00
Anthony c4137c2880 Merge pull request #4965 from leoetlino/delete-everything
IOS/ES: Implement DeleteTitle
2017-02-27 12:18:47 -08:00
Anthony 7ac95c2673 Merge pull request #4906 from leoetlino/es-launch
IOS: Handle ES_Launch more accurately
2017-02-27 11:51:43 -08:00
Léo Lam fff4634a1c IOS: Handle ES_Launch more accurately
This commit fixes ES_Launch to work mostly the same as the real IOS
(except temporary, internal files such as /sys/launch.sys and title
handling; the latter will be handled in a future PR).

First of all, this adds two IOS functions, which correspond to two
IOS syscalls: 0x41 (boot_ppc) and 0x42 (boot_ios).

boot_ios() writes the new version to 0x3140, loads the new kernel,
which then proceeds to reinit IPC and load modules as part of its
boot process. Note that this doesn't include writing to any of the
other constants in the 0x3100 region.
In Dolphin, this is implemented by changing the active IOS
version variable, writing to 0x3140 and resetting all devices. This
has exactly the same effect as the real syscall.

The other syscall, boot_ppc(), writes code to the EXI boot buffer,
pokes all constants to memory before bootstrapping the PPC with a
binary from the NAND.
We skip the low level stuff and just load the DOL to memory (and set
the PPC's PC to 0x3400), which is essentially what IOS does.

The other change is mostly related to how ES_Launch is handled.

With a real IOS, if the launched title type is 00000001 (system) and
the title is not 1-2 (System Menu), ES calls boot_ios().

Otherwise, ES handles the launch as a PPC title. It reads the TMD
to determine the required IOS version. If it is the same, boot_ppc()
is called directly. If not, ES saves the title to launch to the NAND
before launching the new IOS. After the new IOS has finished booting,
it will notice the flag and then launch the requested title.

What this commit does is really just implement this logic into IOS HLE.
The result is a fix for a regression introduced by SetupMemory,
where reloading an IOS would have overwritten some OS constants.
This fixes booting games from the disc channel.
2017-02-27 20:44:30 +01:00
Anthony ed6a46a193 Merge pull request #4958 from RisingFog/avidump_bitrate
Add configurable video dump bitrate to INI
2017-02-27 10:15:19 -08:00
Anthony 63c5230d9b Merge pull request #4959 from lioncash/ini
IniFile: Handle s64/u64 values
2017-02-27 10:02:53 -08:00
Anthony 0cac00a39c Merge pull request #4977 from ligfx/fixwxmainmenubar
DolphinWX: don't refresh MainMenuBar on construction
2017-02-27 09:42:01 -08:00
Anthony b16cebc297 Merge pull request #4978 from ligfx/avidumpclosefiles
AVIDump[regression]: close avio handles
2017-02-27 09:39:40 -08:00
Jules Blok f5d14e3691 Merge pull request #4933 from Armada651/disable-cache
VideoBackends: Add a developer option to disable the shader cache.
2017-02-27 17:35:01 +01:00
Léo Lam ac43836714 IOS/ES: Implement DeleteTitle
No idea why this wasn't implemented whereas ES_DeleteTicket and
ES_DeleteTitleContent were.

This probably fixes title deletion in old System Menus, and maybe
the new ones as well in some cases; I've seen 4.3 use this ioctlv.
2017-02-27 15:32:31 +01:00
Michael Maltese 621472336c AVIDump[regression]: close avio handles 2017-02-26 23:26:31 -08:00
Matthew Parlane d666363ac4 Merge pull request #4966 from RisingFog/remove_traversal_server_debug_mode
Turn Off Debug Mode for Traversal Server
2017-02-27 16:18:13 +13:00
Matthew Parlane ca9504d0fa Merge pull request #4969 from leoetlino/clear-tmp
IOS: Clear the /tmp directory on IOS boot
2017-02-27 16:17:49 +13:00
Matthew Parlane 48aeb5bf4b Merge pull request #4896 from leoetlino/esformats
Use ESFormats for tickets, TMDs and views
2017-02-27 16:15:05 +13:00
Michael Maltese 720f0ab93f DolphinWX: don't refresh MainMenuBar on construction
On startup, wxWidgets pops up an assertion error:

> ./src/osx/menu_osx.cpp(648): assert ""IsAttached()"" failed in
> Refresh(): can't refresh unatteched menubar
2017-02-26 17:50:36 -08:00
Michael Maltese a3e3986906 DolphinWX: provide empty OnCmdLineParsed
Starting in #4916, upon startup wxWidgets pops up an assertion error:

> ./src/common/cmdline.cpp(527): assert ""Assert failure"" failed in
> FindOptionByAnyName(): Unknown option verbose

Fix this by overriding wxApp::OnCmdLineParsed to disable the default
handling (since we also disable the default options in
DolphinApp::OnInitCmdLine).
2017-02-26 17:38:18 -08:00
Anthony 7bcff99d89 Merge pull request #4963 from leoetlino/sysconf
SysConf: Use vectors instead of raw pointers
2017-02-26 16:09:17 -08:00
Anthony 832e0501db Merge pull request #4960 from lioncash/type
ControlGroup: Convert group type enum into an enum class
2017-02-26 15:56:34 -08:00
Anthony 0dde642b7d Merge pull request #4917 from leoetlino/config
New configuration namespace
2017-02-26 15:54:25 -08:00
Anthony 06428c3f14 Merge pull request #4916 from leoetlino/cpp-optparse
Use cpp-optparse for command line parsing
2017-02-26 15:51:35 -08:00
Anthony 722ff4c020 Merge pull request #4915 from leoetlino/ini-changes
Expose some ways to manage an INI file
2017-02-26 15:48:53 -08:00
gamemasterplc 4c4a96bfc5 Widescreen Hack improvement
Fixes Projection alignment in some N64 VC games. The original code forgot to multiply rawProjection[1] and rawProjection[3].
2017-02-26 12:55:57 -06:00
Léo Lam 44a3db21e4 ES: Make sure the TMD and ticket are valid before use 2017-02-26 19:46:30 +01:00
Léo Lam 5104caf6a6 Move AES code to Common/Crypto 2017-02-26 19:46:30 +01:00
Léo Lam c1a139e8ac Use ESFormats for TMDs
We already have a TMDReader, so let's actually use it.

And move ESFormats to IOS::ES, since it's definitely part of IOS.
This adds a DiscIO dependency on Core which will be fixed in a
follow-up PR.
2017-02-26 19:46:29 +01:00
Léo Lam bf1f70db0a Move the ticket code to ESFormats
This moves some parsing code for tickets and ticket views to ESFormats
instead of duplicating it over DiscIO and Core.
2017-02-26 19:46:28 +01:00
JosJuice a62711de55 Merge pull request #4968 from lioncash/const-parser
ExpressionParser: Const-correctness changes
2017-02-26 19:24:21 +01:00
JosJuice 6c869f7891 Merge pull request #4955 from leoetlino/wat
Fix the build on non-Windows platforms when not using WX from Externals
2017-02-26 19:19:06 +01:00
Léo Lam 31ebe9b080 IOS: Clear the /tmp directory on IOS boot
The /tmp directory is cleared every time IOS boots up (when the FS
driver is initialized), *not* when /dev/fs is opened.

Although this should have no effect, it fixes the case where files
could be left in /tmp and seen before opening /dev/fs.
2017-02-26 12:19:57 +01:00
Jules Blok a15555fe03 VideoBackends: Use vertex shader depth range if ztexture is used. 2017-02-26 11:34:48 +01:00
Lioncash f0203157d4 ExpressionParser: Const-correctness changes 2017-02-26 02:09:34 -05:00
Chris Burgener bfb17d5a9e Add configurable video dump bitrate to INI 2017-02-25 23:58:21 -05:00
Chris Burgener 4669b50e0b Turn Off Debug Mode for Traversal Server 2017-02-25 23:41:12 -05:00
Léo Lam a1e16c47db SysConf: Use vectors instead of raw pointers 2017-02-26 00:39:50 +01:00
Lioncash 26f17a1723 ControlGroup: Convert group type enum into an enum class
Gets some constants out of the ControllerEmu namespace, and modifies
ControlGroup so that it uses the enum type itself to represent the
underlying type, rather than a u32 value.
2017-02-25 01:15:04 -05:00
Lioncash beec40f178 IniFile: Handle s64/u64 values 2017-02-25 00:03:20 -05:00
Markus Wick 51136681df Merge pull request #4953 from lioncash/fwd
CachedInterpreter: Forward declare instruction struct
2017-02-24 23:36:11 +01:00
Léo Lam 6702e547cb Fix the build on Linux when not using WX from Externals
No idea why we were including a Windows specific header *without* a
ifdef.
2017-02-24 18:48:26 +01:00
Jules Blok bde8126913 VideoBackends: Remove depth range clamping hacks.
Oversized depth ranges are handled correctly now, we don't need to hack around them with clamps anymore.
2017-02-24 14:54:20 +01:00
Jules Blok 94522d4cf3 OGL: Add support for glDepthRangedNV to handle oversized depth ranges. 2017-02-24 14:54:16 +01:00
Markus Wick 1f04bab967 Merge pull request #4952 from ligfx/fix_10110
PatchEngine: check instruction at link addr is non-zero
2017-02-24 11:08:15 +01:00
Markus Wick 25fc7ed8c1 Merge pull request #4954 from lioncash/jitbase
JitBase: Put constructor and destructor in the cpp file
2017-02-24 11:05:57 +01:00
Lioncash 0783476464 CachedInterpreter: Forward declare instruction struct
Allows changes to be made to the instruction struct without recompiling
other source files.
2017-02-23 18:08:20 -05:00
Anthony 4e93002adb Merge pull request #4800 from JosJuice/movie-dual-core-determinism
Remove special condition for auto dual core determinism
2017-02-23 13:19:39 -08:00
Anthony ba5f1c6f59 Merge pull request #4864 from JosJuice/idws-on-temp-nand-only
WiiRoot: Only call InitializeDeterministicWiiSaves on temporary NAND
2017-02-23 13:18:23 -08:00
Anthony 27a5e33b92 Merge pull request #4877 from ligfx/forward_declare_xlib
Remove include X11/Xlib.h from X11Utils.h
2017-02-23 13:17:37 -08:00
Anthony ecb7d01347 Merge pull request #4889 from ligfx/netwindow
NetWindow: explicitly tell wxWidgets to clean up Windows macros
2017-02-23 13:16:59 -08:00
Anthony e9850382e3 Merge pull request #4930 from JosJuice/sideways-wiimote-name
Change INI keys containing "Wii Remote" back to "Wiimote"
2017-02-23 13:13:43 -08:00
Anthony fb8369d0e0 Merge pull request #4950 from leoetlino/set-remotes-before-booting
Netplay: Change Wiimote sources before booting
2017-02-23 13:13:13 -08:00
Lioncash 359528b805 JitBase: Put constructor and destructor in the cpp file
As this is a base class with virtuals, there needs to be an out-of-line
function definition to prevent the vtable of the class being placed within
every translation unit it's used in (i.e. every JIT implementation).
2017-02-23 13:50:47 -05:00
Léo Lam 88a21dd2b9 Fix things mentioned during code review
Ref: https://github.com/dolphin-emu/dolphin/pull/4917
2017-02-23 18:15:12 +01:00
Léo Lam abe6f8766a Config: Add a few helper functions for repetitive tasks
Getting and setting configuration from the base config layer are common
and repetitive tasks. This commit adds some simpler to use functions to
make the new system easier to work with.

Config::Get and Config::Set are intended to make switching from
SConfig a bit less painful. They always operate on the main system.

Example usage:

    // before
    auto base_layer = Config::GetLayer(Config::LayerType::Base);
    auto core = base_layer->GetOrCreateSection(Config::System::Main, "Core");
    u8 language;
    core->Get("Language", &language, 0);
    SetData("IPL.LNG", language);

    // now
    auto base_layer = Config::GetLayer(Config::LayerType::Base);
    auto core = base_layer->GetOrCreateSection(Config::System::Main, "Core");
    SetData("IPL.LNG", core->Get<u8>("Language", 0));

    // or simply
    SetData("IPL.LNG", Config::Get<u8>("Core", "Language", 0));
2017-02-23 18:15:12 +01:00
Léo Lam 7bd34ac0b5 Config: Trigger callbacks on layer save
And remove an extraneous callback trigger in Config::Load.
2017-02-23 18:15:12 +01:00
Léo Lam 9c3265f1ef Config: Keep track of deleted keys
This allows deleted keys to be deleted from INIs properly.
2017-02-23 18:15:12 +01:00
Léo Lam b51c6023ba Config: Only save settings if they have been changed 2017-02-23 18:15:12 +01:00
Ryan Houdek 8360e358ee New configuration namespace 2017-02-23 18:15:11 +01:00
Anthony f7a09c41a1 Merge pull request #4941 from JosJuice/no-compressed-color
DolphinWX: Don't use a special color for compressed games
2017-02-23 07:17:48 -08:00
Markus Wick 0a3a2fe155 Merge pull request #4922 from sepalani/more_format
HLE: More printf floating point types handled
2017-02-23 11:03:32 +01:00
Markus Wick 1fc2edae51 Merge pull request #4928 from lioncash/const
PPCAnalyst: Make SetInstructionStats' opinfo parameter a const pointer
2017-02-23 10:55:58 +01:00
Markus Wick 25a569e6e9 Merge pull request #4929 from lioncash/symboldb
SymbolDB: Simplify GetSymbolsFromHash
2017-02-23 10:55:28 +01:00
Markus Wick ae8010caff Merge pull request #4943 from lioncash/const-table
JIT: Make initialization instruction tables const
2017-02-23 10:27:21 +01:00
Markus Wick 51b654ed00 Merge pull request #4945 from lioncash/jit-global
DolphinWX: Eliminate direct usage of the JIT global
2017-02-23 10:24:55 +01:00
Markus Wick d4453db2ea Merge pull request #4946 from lioncash/naming
JitInterface: Amend ExceptionType enum value names
2017-02-23 10:23:37 +01:00
Michael Maltese da35abbbe2 PatchEngine: check instruction at link addr is non-zero
Regression introduced in #4738. Fixes
https://bugs.dolphin-emu.org/issues/10110.
2017-02-22 21:14:57 -08:00
Léo Lam fb46520c74 Netplay: Change Wiimote sources before booting
It is kind of silly to connect all of the configured Wii remotes (from
the user config; NOT netplay assigned remotes), then connect/disconnect
additional Wii remotes *after* the core has booted.

(The bWii check has been removed, because it's actually unneeded;
m_wiimote_map is always usable regardless of bWii. And we can't get
info about the currently running game without booting the core with our
current config system…)

This should fix Netplay trying to connect all configured Wii remotes.
2017-02-22 22:52:13 +01:00
JosJuice 9b0ce31906 Merge pull request #4948 from leoetlino/file
IOS/FFSP: Fix the "past EOF" check
2017-02-22 22:43:40 +01:00
Markus Wick fa9b89fdf9 Merge pull request #4911 from degasus/ABI
JitArm64: Extract block exit link area generation.
2017-02-22 22:26:08 +01:00
Mat M c81cf111ef Merge pull request #4921 from waddlesplash/netmap
IOS/Network/Net: Use a conversion function instead of a static array for SOCKOPT mapping
2017-02-22 16:11:53 -05:00
Léo Lam b0a132875a IOS/FFSP: Fix the "past EOF" check
Fixes a logic bug I introduced as part of #4942. We were not
handling the "read past EOF" case correctly, which caused
requested_read_length to underflow in some cases.

Also fixes a comparison (though this is unlikely to change anything).
2017-02-22 20:54:02 +01:00
Augustin Cavalier 806bb2a4d0 IOS/Network/Net: Use a mapper function instead of a static array for SOCKOPT mapping.
Some platforms (e.g. Haiku) define SOL_SOCKET to be -1, which obviously
does not work with static arrays. Plus, this is cleaner.
2017-02-22 10:55:38 -05:00
Lioncash 70d336d2a9 DolphinWX: Eliminate direct usage of the JIT global
Instead, the JitInterface namespace functions should be used instead. This
gets rid of all usages of the JIT global from the wxWidgets UI code.

The null check isn't needed as the JIT core would already need to be
initialized in order to be within a paused state. The null check is just a
remnant from 2011 that existed before the check for a paused state was
added.
2017-02-21 16:15:47 -05:00
JMC47 d320a2a067 Force Wallace and Gromit to use smaller memcard. 2017-02-21 16:09:49 -05:00
Lioncash ff0f60c9f9 JitInterface: Amend ExceptionType enum value names
Since ExceptionType is an enum class, its name already acts like the
common prefix.
2017-02-21 15:40:00 -05:00
Mat M 95b2b033b0 Merge pull request #4925 from RisingFog/remove_readonly_check
Remove IsReadOnly check when stop recording
2017-02-21 10:53:24 -05:00
Lioncash f65c34d63d JitArm64_Tables: Make initialization instruction tables constexpr 2017-02-21 10:23:39 -05:00
Lioncash 4b342fbbfc JitIL_Tables: Make initialization instruction tables const 2017-02-21 09:55:08 -05:00
Lioncash 092d21253d Jit64_Tables: Make initialization instruction tables const 2017-02-21 09:54:51 -05:00