When testing non-RomData files with `rp-stub -R`, I got random crashes.
gdb traced it back to an invalid g_bytes_unref() due to pngBytes not
being initialized properly.
This only affects the GTK4 version.
This fixes a regression from commit bc32b0c3a2.
([gtk] DragImage: Implement GTK4 drag & drop.)
Affects: v2.4 - v2.5
It seems this was broken since it was initially implemented in v2.0
in commit d732fbc010
([cmake] platform/gcc.cmake: Initial support for detecting DT_RELR.)
because TMP_HAVE_DT_RELR was unset too early.
Need to use be32_to_cpu() for 32-bit values, not be16_to_cpu().
This fixes a regression from commit 5cfce44312.
([libromdata] ISO: Always use host-endian except for CD-i, in which case, always use big-endian.)
Affects: v1.8 - v2.5
NOTE: v1.8 was the first version with CD-i support, so this was
effectively "always" broken.
Make it sort in ascending order by default instead.
NOTE: Using column -1 to suppress the sort indicator visibility.
Might want to guard this with QT_VERSION_CHECK(6, 0, 0), but it seems
to have no effect on KF5 on my system, but it might on some other
systems with weird shenanigans happening...
The SparseDiscReader changes in v2.3 broke this, so anything that uses
an ISO-9660 format showed 2048-byte sectors, even if this wasn't the case.
SparseDiscReader subclasses now have a set of CD-ROM specific fields to
set, e.g. CD-ROM sector size, mode, and subchannels. For multi-track
images, this should be set for the "main" data track.
Updated the following classes to set these fields:
- CdiReader (uses Track 02 for Dreamcast games)
- GdiReader (uses Track 03 for Dreamcast games)
- Cdrom2352Reader (always uses 2352-byte sectors, but gets mode from
the first sector)
- CisoPspReader (always uses MODE1/2048)
GameCube and Wii disc reading classes don't set these, since they aren't
CD-ROM formats with multiple sector sizes.
It was showing an error if the file specified was in fact a device file,
which prevents it from working.
This fixes a regression from commit 837315505e.
([rpcli] rpcli.cpp: Un-indent a few functions.)
Affects: v2.3 - v2.5
This was previously handled by NintendoDS before banner parsing was
split out into a separate RomData subclass.
Without IMGPF_ICON_ANIMATED, rpcli won't indicate if an animated icon
is present, but it can still be extracted with `-a`.
This fixes a regression from commit f2565965b2.
([libromdata] NintendoDS_BNR: Split icon/title data parsing out of NintendoDS.)
Affects: v2.4 - v2.5
Unstaged images contain sets of components instead of a fully-installed
Windows system. These aren't as common as staged images.
The list of editions appears to be in the display description, though
I don't have an unstaged image to verify this. If the display description
contains "EDITIONS:", and the regular edition field and languages are
both empty, then it will be assumed to be unstaged. The list of editions
will be split and one image will be shown for each edition, using the
image number and a letter.
Should fix#445: [libromdata - WIM] Unstaged Windows OS installation images not properly supported
Requested by @pivotman319-owo.
NOTE: Needs to be verified!
Note that NEON's vtbl instructions doesn't support the bit 7 "zero it"
feature that x86's pshufb supports, so we have to use an AND mask in
addition to an OR mask.
Tested using luminance_alpha_reference_u.ktx2, which has a swizzle
value 'rrrg'. (Also used this for testing the previous commit, which
switched some mask stuff from 8-bit operations to 32-bit.)
Both lastmodtime_high and lastmodtime_low were being initialized to
strtoul(s_highPart, ...).
Testing Windows 10 (10.0.19041.5363) recovery image: (winre.wim)
- HIGHPART: 0x01D5ACCD
- LOWPART: 0x97A856C3
- Decimal: 132201763089962691
Timestamp conversions before and after: (using TZ=UTC)
- Before: 12/07/2019 07:07:37 AM
- After: 12/07/2019 07:11:48 AM
Manually converting it using a website:
- Saturday, December 7, 2019 7:11:48 AM
TODO: Split the XML code into a separate .cpp file and add DelayLoad checks.
It's only supported by glibc on Linux (and possibly some of the BSDs),
and it adds a lot of complexity. The regular C dispatch functions only
have a few instructions of overhead in most cases.
Adding ARM NEON would have complicated things:
- 32-bit ARMv7: Needs a check on Linux and Android; on Windows, it's
guaranteed to be present.
- 64-bit ARMv8: Always exists.
Both the GDI and CDI branches were attempting to create CdiReader objects.
That obviously won't work for GDI.
This fixes a regression from commit 209ea0d951.
([libromdata] MultiTrackSparseDiscReader.hpp: New interface for multi-track sparse disc reader classes.)
Affects: v2.4 - v2.4.1
qoi.h is used for upstream, instead of writing a custom decoder.
I may write a custom decoder later to decode the Qoi data directly
into an rp_image without having an intermediate step.
RomDataFactory::T_create(): Check if the filename is a drive letter.
IRpFile: Move IsDriveLetter*() and related from RpFile_win32.cpp to
IRpFile.hpp, #ifdef'd for Windows only.
CD-ROM drive volume roots can now be handled by rom-properties again.
This broke when support for Wii U Packages was added, since devices are
also considered root directories, so the directory check was done instead
of the device check.
Affects: v2.4 - v2.4.1
This should fix a bunch of STFSes that previously claimed an encryption
key was missing because they were unable to decompress LZX data correctly.
TODO:
- Create a SparseDiscReader instead of reading the entire file into memory.
- Handle non-contiguous files. (Unlikely in packages; more likely in
save files.)
Sonic the Fighters has a value '3', which isn't defined in Xenia's enum
for ACB. Rework it such that G=0,1; PG=2,3; M=4,5; MA15+=6,7.
TODO: Need to verify this with more titles.
These are supposed to use the "hybrid metadata pointer", but some older
DLLs have a separate machine type instead.
EXE_PE.cpp: Change "CHPE" to "CHPEv1".
Fixes#439: Missing ARM64 machine type IMAGE_FILE_MACHINE_CHPE_X86
Reported by @pivotman319-owo.
This caused asserts when using libstdc++ debug mode.
wiiu_application_types: "Game Update" should be after "Game DLC".
This broke "Super Smash Bros. for Wii U (USA) (Update)".
/usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/bits/stl_algo.h:1970:
In function:
_FIter std::lower_bound(_FIter, _FIter, const _Tp&, _Compare) [with
_FIter = const LibRomData::WiiUData::WiiUApplicationType*; _Tp =
unsigned int; _Compare =
LibRomData::WiiUData::lookup_application_type(uint32_t)::<lambda(const
LibRomData::WiiUData::WiiUApplicationType&, uint32_t)>]
Error: elements in iterator range [first, last) are not partitioned by the
predicate __comp and value __val.
Objects involved in the operation:
iterator "first" @ 0x7fffffffc578 {
type = LibRomData::WiiUData::WiiUApplicationType const* (constant iterator);
}
iterator "last" @ 0x7fffffffc570 {
type = LibRomData::WiiUData::WiiUApplicationType const* (constant iterator);
}
disc_publishers_noregion: Three disc publishers were out of order.
This broke "NES REMIX (USA)" and "NES REMIX 2 (USA)".
/usr/lib/gcc/x86_64-pc-linux-gnu/14/include/g++-v14/bits/stl_algo.h:1970:
In function:
_FIter std::lower_bound(_FIter, _FIter, const _Tp&, _Compare) [with
_FIter = const LibRomData::WiiUData::WiiUDiscPublisher*; _Tp = unsigned
int; _Compare = LibRomData::WiiUData::lookup_disc_publisher(const
char*)::<lambda(const LibRomData::WiiUData::WiiUDiscPublisher&,
uint32_t)>]
Error: elements in iterator range [first, last) are not partitioned by the
predicate __comp and value __val.
Objects involved in the operation:
iterator "first" @ 0x7ffc13befb38 {
type = LibRomData::WiiUData::WiiUDiscPublisher const* (constant iterator);
}
iterator "last" @ 0x7ffc13befb30 {
type = LibRomData::WiiUData::WiiUDiscPublisher const* (constant iterator);
}
Remove lblCredits from the .ui file and create it manually after creating
the QComboBoxes. This eliminates the need to use setTabOrder(), which
wasn't working properly when trying to set lblCredits to after the final
QComboBox that was created by createComboBox().
FIXME: Tab ordering still has the label itself as a tab stop, in addition
to the two links...
d->pvr3Header hasn't been initialized at this point.
This broke when PowerVR3 was extended to handle PowerVR 2.0 textures.
Most PowerVR3 files are little-endian, so the usual case of x86/amd64/arm
wouldn't have caused a problem. On PowerPC, the files weren't detected.
This fixes a regression from commit f5a099d169.
([librptexture] PowerVR3: Preliminary support for PowerVR v2.0 files.)
This fixes ImageDecoderTest's PowerVR3 tests.
Affects: v2.4 - v2.4.1
Also, un-indent PowerVR3Private.
This was already done in the GTK and KDE UI frontends, but not in
Win32, which results in PSP Minis showing a gigantic banner because
they have a 310x180 background image that's used as a banner.
Also, remove RP_ShellPropSheetExt_Private::rescaleImage(). This was
copied to DragImageLabel in commit c234c6cf36
([win32] DragImageLabel: Copied image sizing, including rescaleImage(), to DragImageLabel.)
because it was still used for the banner code, but was never removed.
NOTE: Prior to DragImageLabel, the banner was unconditionally resized
to 96x32. This would have prevented the giant image issue, but it's
the wrong aspect ratio for PSP Minis. (310x180 -> 55x32)
Also, icons were previously unconditionally resized to 32x32, which
usually works, unless something has a non-square icon.
Fixes#433: [Bug Report] The ROM type is not displayed correctly for some PSP Mini ROMs
Reported by @xxmichibxx.
Affects: v1.5 - v2.4.1