Commit Graph

17136 Commits

Author SHA1 Message Date
Markus Wick f63d40270d Merge pull request #5056 from JosJuice/use-readswapped
Volume: Use ReadSwapped more
2017-03-13 10:30:55 +01:00
Matthew Parlane 1eba936749 Merge pull request #5072 from lioncash/const
DSPEmitter/DSPInterpreter: Remove unnecessary const specifiers from function declaration parameters
2017-03-13 14:13:53 +13:00
Lioncash ade7718636 DSPInterpreter: Remove unnecessary const specifiers from function declaration parameters 2017-03-12 17:38:04 -04:00
Lioncash a33cd805f9 DSPEmitter: Remove unnecessary const specifiers from function declaration parameters
These only matter for types being passed by value within the definition,
not the declaration.
2017-03-12 17:37:07 -04:00
Léo Lam 2111e4dd92 IOS/ES: Fix GetStoredContentsFromTMD
We were checking for the wrong files (title content directory instead
of checking whether the content files themselves exist)... Whoops!
2017-03-12 14:32:01 +01:00
Starsam80 0f44d22db5
Fix `ReadCertFile` by opening as binary file 2017-03-11 23:44:30 -07:00
Matthew Parlane b1bd231421 Merge pull request #5020 from leoetlino/es-safer-import
IOS/ES: Implement ES_AddTitleCancel (and slightly safer import process)
2017-03-12 16:14:17 +13:00
Matthew Parlane c62fc192ef Merge pull request #5027 from leoetlino/ssl-check
IOS/SSL: Make sure we are using a correct cert/key
2017-03-12 16:13:37 +13:00
Matthew Parlane d042121ebd Merge pull request #5043 from lioncash/net
IOS/Network/IP/Top: Separate behaviors into their own functions
2017-03-12 16:12:43 +13:00
Matthew Parlane 29cf19f3d0 Merge pull request #5066 from leoetlino/personalised-tickets
IOS/ES: Handle personalised tickets properly
2017-03-12 16:12:21 +13:00
Lioncash 26e9c54886 DSPEmitter: Make helper functions private
Given none of these are used outside of the DSPEmitter class (nor does
it really make sense to allow them to be used outside of the class),
these should all be made private.
2017-03-11 20:33:07 -05:00
MerryMage dc1a8c46e9 DSP/Jit: Load address of m_cycles_left into register
On some platforms, the address of m_cycles_left exceeds the maximal 32-bit
offset from RIP.
2017-03-11 22:51:41 +00:00
Léo Lam 9c31d6f5c5 IOS/ES: Handle personalised tickets properly
IOS unpersonalises device-specific ("personalised") tickets prior to
storing them on the NAND.
2017-03-11 21:14:26 +01:00
Mat M 71273c05a9 Merge pull request #5054 from leoetlino/es-get-contents
IOS/ES: Implement ES_GetStoredContents ioctlvs properly
2017-03-11 10:52:53 -05:00
Mat M 3d041fa4ea Merge pull request #5055 from leoetlino/es-ticket-view-fix
IOS/ES: Fix GetViews to not check for the TMD
2017-03-11 10:50:50 -05:00
Stenzek 27d7a1646c Merge pull request #5065 from JosJuice/character
Fix issue 10146 (compilation issue because of colliding defines)
2017-03-11 18:26:26 +10:00
JosJuice 40e707348c Fix issue 10146 (compilation issue because of colliding defines) 2017-03-11 08:59:14 +01:00
Léo Lam 3cbf47d51d IOS/ES: Fix GetViews to not check for the TMD
Using DiscIO's NAND content loader is the wrong way to get the ticket
for a title, because it checks whether the TMD is present and the
validity check fails if it isn't. This is not the correct behaviour:
we should just read the ticket from /ticket without caring about TMDs.
2017-03-10 22:59:34 +01:00
Léo Lam 28519328d2 IOS/ES: Implement ES_GetStoredContents ioctlvs properly
* IOS doesn't rely on the number of contents indicated in the TMD.
  Instead, it checks whether the contents *do* exist on the NAND.

* Implement ES_GetTMDStoredContents (and the count ioctlv).

* Drop a hack in ES_GetStoredContents, which is unnecessary now that
  we do it properly.
2017-03-10 22:45:08 +01:00
Léo Lam 62ea76e04c IOS/ES: Clear /import on ES initialization
Something IOS does and we didn't do.
2017-03-10 22:44:26 +01:00
Léo Lam d6499aba50 IOS/ES: Implement ES_AddTitleCancel 2017-03-10 22:44:26 +01:00
Léo Lam e656258949 IOS/ES: Write import files to /import first
This is slightly safer than writing contents to /title directly.
We still cannot rename everything in one go atomically, but this allows
implementing AddTitleCancel very easily.

Also, this ensures that when a title import fails, no incomplete files
will be left in the title directory, which can mess up the system menu.
2017-03-10 22:44:26 +01:00
Michael Maltese 418a7723c8 GLExtensions: remove NV_depth_buffer_float from OpenGL 3.0
Regression introduced in e99cd57 / 4935: VideoBackends: Set the maximum
range when the depth range is oversized[1]. The NV_depth_buffer_float
extension is not part of OpenGL 3.0, and requiring it causes a hard
crash when it's not supported (e.g. macOS).

[1]: https://github.com/dolphin-emu/dolphin/pull/4935
2017-03-10 12:54:46 -08:00
Markus Wick e99cd57eb3 Merge pull request #4935 from Armada651/depth-range-fix
VideoBackends: Set the maximum range when the depth range is oversized.
2017-03-10 18:05:52 +01:00
Jules Blok 3f41e6d4cf RenderBase: Check if early ztest is enabled before falling back to vertex depth range. 2017-03-10 15:43:32 +01:00
Stenzek 42993eeabc D3D11: Fix error on startup with >2.5xIR selected 2017-03-10 23:41:20 +10:00
Markus Wick ae0f9c200d Merge pull request #5038 from vladfi1/separate-nogui
Separate nogui
2017-03-10 10:50:08 +01:00
Lioncash b61ce51d3b IOS/Network/IP/Top: Separate behaviors into their own functions
Localizes behavior and separates the code out from the IOCtl/IOCtlV
switch blocks.
2017-03-09 20:58:45 -05:00
Markus Wick ef74c5eabd Merge pull request #5051 from stenzek/renderer-fixes
VideoBackends: Fix crashes introduced by #4999
2017-03-09 21:06:50 +01:00
JosJuice 135733e285 Volume: Use ReadSwapped more
Most of the Volume code was written before this
convenience function was added. Let's use it more.

Also deleting m_pReader nullptr checks that are
unnecessary because of Read (which ReadSwapped calls)
already having a nullptr check.
2017-03-09 21:03:28 +01:00
Anthony cf848b7c42 Merge pull request #5045 from JosJuice/unify-setting-game-metadata
Unify the way of setting game ID, title ID, revision
2017-03-09 18:13:02 +00:00
JosJuice ab616145c2 Get the right game ID for SSBB's Masterpiece partitions 2017-03-09 18:47:40 +01:00
JosJuice e04245a10e ConfigManager: Hack for getting the right revision on ES_Launch 2017-03-09 18:07:20 +01:00
Anthony dc42f7fb28 Merge pull request #4991 from leoetlino/config-loaders
New config loaders
2017-03-09 16:56:14 +00:00
JosJuice ced1614cac Unify the way of setting game ID, title ID, revision
The existing code from ConfigManager, ES and MIOS is merged
into a new set of functions called SetRunningGameMetadata.
2017-03-09 15:34:14 +01:00
Stenzek 2cd240af0d VideoBackends: Move max texture size to VideoConfig
This stops the virtual method call from within the Renderer constructor.

The initialization here for GL had to be moved to VideoBackend, as the
Renderer constructor will not have been executed before the value is
required.
2017-03-10 00:04:13 +10:00
Stenzek 4012166085 VideoCommon: Fix crash at startup with virtual XFB enabled 2017-03-09 23:39:48 +10:00
Léo Lam 2f02cc2996 IOS/SSL: Make sure we are using a correct cert/key
This adds a check to the SSL code to make sure we are using the correct
client certificate and key (and root CA).

Now, instead of silently failing, the user will be notified whenever a
file is missing or when it is invalid, i.e. when the hash does not
match; this is likely to happen for existing users as the program
linked in the network guide extracted the wrong certs :(
2017-03-09 13:57:23 +01:00
Lioncash 40cdd32760 GCMemcard: Mark class constructors explicit where applicable
Prevents potential implicit instantation.
2017-03-08 19:11:16 -05:00
Anthony 883bec873f Merge pull request #4939 from sjnewbury/gamelist-text
Always use visible text in GameList
2017-03-08 22:38:23 +00:00
Léo Lam dc224cba3c IOS/ES: Partially restore hack to fake IOS titles
This partially restores a hack which causes ES to fake ticket views for
IOS titles.

This is necessary because we still allow users to boot games from the
game list, so, with no way of making sure the required IOSes are
installed beforehand, games may OSPanic() when they try to reload to
some IOS version and just find out that the IOS is not installed
(something which *never* happens on the real console, of course).

A warning is printed in the logs to make sure technical users know the
IOS titles are being faked. To try and keep things accurate in all
other cases, this hack is only active when it is needed (when the
current title is a disc title which was launched from the game list).
2017-03-08 23:09:10 +01:00
Matthew Parlane cd826cee34 Merge pull request #5039 from leoetlino/es-import-hash-check
IOS/ES: Check the content hash during imports
2017-03-09 10:58:06 +13:00
Vlad Firoiu 68adcbd209 Don't special-case nogui exe name on Apple. 2017-03-08 13:17:49 -08:00
Markus Wick be8de62b88 Merge pull request #5041 from JosJuice/hi-2007
PatchEngine: Remove an unneeded comment
2017-03-08 21:23:40 +01:00
JosJuice 08954e99f5 PatchEngine: Remove an unneeded comment 2017-03-08 21:03:10 +01:00
JosJuice a1f874a66b ConfigManager: Remove m_strName
m_strName has limited usefulness, because GetInternalName()
can be inaccurate or even completely wrong. It was almost
completely unused anyway.
2017-03-08 21:01:57 +01:00
Steven Newbury 28f4793785 Always use visible text in GameList
Depending upon the desktop colour scheme, the light/dark
GameList backgrounds can cause the always white text
to become unreadble.

Use the common luminance approximation algorithm to
determine whether black text should be used instead.
2017-03-08 18:03:51 +00:00
Léo Lam daa5ff9a81 IOS/ES: Check the content hash during imports
This adds a hash check for imported contents. IOS does it for security;
we do it for a somewhat different reason, to catch content decryption
bugs before incorrectly decrypted contents get written to the NAND,
which can cause titles to be corrupted.

Either way, we should have been doing this check in all cases.
2017-03-08 16:32:38 +01:00
Markus Wick 489d90b6f3 Merge pull request #4999 from stenzek/renderer-statics
VideoCommon: Eliminate static state in Renderer
2017-03-08 11:02:20 +01:00
Markus Wick 9c1eac1f4f Merge pull request #4944 from vladfi1/framedump
Framedump extensions
2017-03-08 11:01:53 +01:00