Commit Graph

53 Commits

Author SHA1 Message Date
JosJuice 1878605d77 Undo some comment formatting changes from b5104a7 2016-06-25 18:07:10 +02:00
Rukai b5104a79f1 GCVolume: supports reading all opening.bnr information
DQT2: Game properties dialog contains info tab giving information about the selected iso.
2016-06-26 00:03:59 +10:00
Pierre Bourdon 3570c7f03a Reformat all the things. Have fun with merge conflicts. 2016-06-24 10:43:46 +02:00
Markus Wick c310b3f0e6 Merge pull request #3309 from JosJuice/reload-banner-without-volume
Don't read from volume when reloading Wii banners
2015-12-15 18:48:49 +01:00
Markus Wick 2990df3f59 Merge pull request #3265 from JosJuice/volumedirectory-simplifications
DiscIO: Small VolumeDirectory simplifications
2015-12-15 18:36:49 +01:00
Lioncash 6295297ab3 DiscIO: Get rid of a few explicit deletes 2015-12-08 04:35:56 -05:00
JosJuice a0cd753060 Don't read from volume when reloading Wii banners
Should make loading cached Wii games that lack banners slightly faster.
2015-12-03 17:29:59 +01:00
JosJuice f9af58a388 DiscIO: Don't use PlainFileReader in VolumeDirectory
Blobs are not for regular file reading.
2015-11-28 09:18:22 +01:00
JosJuice 3a9e382661 DiscIO: Small VolumeDirectory simplifications 2015-11-17 10:09:54 +01:00
flacs aaa48e19fe Merge pull request #3097 from JosJuice/blob-type
Fix blob type detection for game right-click menu
2015-09-29 03:46:29 +02:00
JosJuice be7e0554d2 DiscIO: Add a way to get blob type 2015-09-27 20:54:31 +02:00
Scott Mansell ce493b897d Merge pull request #2271 from revel8n/fixes
Fix for alignment of zero-length files within directory based virtual disk
2015-09-28 05:28:38 +13:00
flacs 34c020352f Merge pull request #3092 from JosJuice/compressed-blobs
Display all compressed formats in blue in GUI
2015-09-27 12:57:19 +02:00
revel8n d4c2ca46a4 - Fix for alignment of 0-length files when volume directory is created from directory on disk
Updating constant value representation

Explicitly state data type in std:max usage
2015-09-26 18:29:29 -05:00
Lioncash 19ac565e0d Common: Move asserts to their own header 2015-09-26 18:51:27 -04:00
JosJuice 6935d28112 Display all compressed formats in blue in GUI
In the past, only GCZ was shown as compressed, not CISO and WBFS.
2015-09-26 15:24:29 +02:00
JosJuice e0a47c11f5 Fix reading Wii FST size (for real this time)
04fcb72 fixed an issue with reading the Wii FST size, but I found a second
issue when working on PR #2820 - the size must be shifted left by 2.
DiscScrubber and Boot already do this correctly using separate code.
2015-08-10 16:35:23 +02:00
Lioncash daa205990f Use emplace() instead of insert() where applicable for maps. 2015-06-28 19:52:40 -04:00
JosJuice ec0370d2d1 Volume: Add prefer_long parameter to GetNames
GC games with long names store two variations of the name in
opening.bnr. This makes the shorter of those names available.
For volumes other than GC discs, prefer_long is ignored.
2015-06-08 12:00:34 +02:00
JosJuice 0ed3118141 Volume: Return volume type as an enum
ISOFile and GameFile were using IsWiiDisc() and IsWadFile() to set
an enum value. The volume might as well return an enum directly.

I increased the Qt CACHE_REVISION because m_platform now is saved as u32
instead of int, but increasing the wx CACHE_REVISION is not necessary.
2015-06-04 16:26:36 +02:00
comex a225426510 Rewrite FileSearch and improve ScanDirectoryTree.
- FileSearch is now just one function, and it converts the original glob
  into a regex on all platforms rather than relying on native Windows
  pattern matching on there and a complete hack elsewhere.  It now
  supports recursion out of the box rather than manually expanding
  into a full list of directories in multiple call sites.

  - This adds a GCC >= 4.9 dependency due to older versions having
  outright broken <regex>.  MSVC is fine with it.

- ScanDirectoryTree returns the parent entry rather than filling parts
  of it in via reference.  The count is now stored in the entry like it
  was for subdirectories.

- .glsl file search is now done with DoFileSearch.

- IOCTLV_READ_DIR now uses ScanDirectoryTree directly and sorts the
  results after replacements for better determinism.
2015-05-28 19:14:42 -04:00
Tillmann Karras 30ebb2459e Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
Tillmann Karras cefcb0ace9 Update license headers to GPLv2+ 2015-05-25 13:22:31 +02:00
JosJuice bad09fc358 Volume: Rename GetName to GetInternalName
This is intended to better separate it from GetNames and to clarify
that this name originally wasn't meant to be shown to users.
The ISOProperties GUI is also updated, mainly because labeling
the long banner name "short name" was confusing.
2015-05-11 11:19:30 +02:00
JosJuice ee694e327a Get rid of banner loaders and move their functionality to volumes
Having some data available in banner loaders and some other data
data available in volumes gets messy, especially with GetNames(),
which is available in both but returns different results
depending on which one is used. This change drops support
for reading names and descriptions from Wii save data.
2015-04-28 23:44:29 +02:00
JosJuice 235ecfbed7 Return GetNames languages, to avoid hardcoded language lists in callers
This makes the code cleaner and also leads to some user-visible changes:

The wx game properties will no longer let the user
select WAD languages that don't have any names.

The Qt game list will now display names using the languages
set in the configuration instead of always using
English for PAL GC games and Japanese for WADs.

If a WAD doesn't have a name in the user's preferred language,
English is now selected as a fallback before Japanese.
2015-04-23 08:14:39 +02:00
JosJuice 4cd00e366c Get rid of VolumeHandler
VolumeHandler is basically just a wrapper around a single IVolume object.
This change moves that object to DVDInterface, moves the Read32
function to IVolume, and gets rid of the rest of VolumeHandler.
2015-04-05 10:09:48 +02:00
Stevoisiak eff924e9e2 General Formatting 2015-02-28 19:33:27 -05:00
Stevoisiak 06cb85991e De-capitalized CountryCode 2015-02-26 16:57:31 -05:00
Ryan Houdek f9fc9d47c0 Merge pull request #1895 from JosJuice/isvolumewiidisc
Don't read from disk when checking volume type
2015-01-21 13:45:28 -06:00
skidau 6f61f90dab Merge pull request #1777 from JosJuice/filemonitor-volumedirectory
Add FileMonitor support for VolumeDirectory
2015-01-20 12:32:42 +11:00
JosJuice ace060748b Don't read from disk when checking volume type
Should be faster than relying on the OS to cache the magic words.
Also gets rid of the odd recursive call in VolumeDirectory.
2015-01-17 13:21:02 +01:00
JosJuice 358183e34a Fix 4.0-4901 VolumeDirectory stack overflow
I actually fixed this once, but then I broke it in a
failed attempt to optimize. VolumeHandler::IsWii calls
CVolumeDirectory::Read(0x18, 4, &MagicWord, false);
2015-01-09 22:50:07 +01:00
JosJuice bb93336ecf DiscIO: Replace "raw" functions with "decrypt" parameters
This is intended to make decryption look less implicit in the code.
2014-12-28 10:35:48 +01:00
JosJuice 7f04a23e23 Add FileMonitor support for VolumeDirectory 2014-12-27 20:13:31 +01:00
JosJuice 72f8f243c7 Never decrypt data when using DI command 0xA8
CleanRip relies on this when ripping Wii discs.
2014-12-27 13:49:25 +01:00
Lioncash f14f0caea6 DiscIO: Remove some explicit deletes 2014-12-04 11:39:20 -05:00
Lioncash 56bc58b9f4 VolumeDirectory: Pass std::string by reference for SetUniqueID/SetName 2014-10-28 14:18:54 -04:00
skidau 4cb25633e1 Merge pull request #1048 from lioncash/discio
DiscIO: Minor changes to VolumeDirectory.
2014-09-12 11:31:29 +10:00
Lioncash 9601f5ec5f DiscIO: Get rid of some casts and a c_str call in VolumeDirectory 2014-09-09 19:01:20 -04:00
Lioncash b34f2a78f5 DiscIO: Simplify GetUniqueID in VolumeDirectory 2014-09-09 18:57:45 -04:00
Rohit Nirmal fbc64984ca Include CommonTypes.h instead of Common.h. 2014-09-08 15:39:58 -04:00
Lioncash 1977ea42ae DiscIO: Prefix class member variables with "m_" 2014-09-01 15:48:02 -04:00
Lioncash 5082afa670 DiscIO: Move VolumeDirectory off of raw pointers 2014-08-26 00:23:16 -04: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
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
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
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
Lioncash 2afe215271 Convert all includes to relative paths. 2014-02-18 02:19:10 -05:00
Lioncash 3fd87a7636 Second and final pass of clearing out tabs. 2014-02-17 02:19:41 -05:00