Skip to content

Commit

Permalink
OpenXR - Move skyplane compat flag into compatvr.ini
Browse files Browse the repository at this point in the history
  • Loading branch information
lvonasek committed Sep 13, 2022
1 parent e406dc4 commit e4f44e6
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 20 deletions.
2 changes: 1 addition & 1 deletion Common/VR/PPSSPPVR.cpp
Expand Up @@ -301,7 +301,7 @@ bool PreVRRender() {
VR_SetConfig(VR_CONFIG_3D_GEOMETRY_COUNT, VR_GetConfig(VR_CONFIG_3D_GEOMETRY_COUNT) / 2);

// Set compatibility
vrCompat[VR_COMPAT_SKYPLANE] = PSP_CoreParameter().compat.flags().VRSkyplane;
vrCompat[VR_COMPAT_SKYPLANE] = PSP_CoreParameter().compat.vrCompat().Skyplane;

// Set customizations
VR_SetConfig(VR_CONFIG_6DOF_ENABLED, g_Config.bEnable6DoF);
Expand Down
2 changes: 1 addition & 1 deletion Core/Compatibility.cpp
Expand Up @@ -46,6 +46,7 @@ void Compatibility::Load(const std::string &gameID) {
IniFile compat;
// This loads from assets.
if (compat.LoadFromVFS("compatvr.ini")) {
CheckSetting(compat, gameID, "Skyplane", &vrCompat_.Skyplane);
CheckSetting(compat, gameID, "UnitsPerMeter", &vrCompat_.UnitsPerMeter);
}
}
Expand Down Expand Up @@ -108,7 +109,6 @@ void Compatibility::CheckSettings(IniFile &iniFile, const std::string &gameID) {
CheckSetting(iniFile, gameID, "SplitFramebufferMargin", &flags_.SplitFramebufferMargin);
CheckSetting(iniFile, gameID, "ForceLowerResolutionForEffectsOn", &flags_.ForceLowerResolutionForEffectsOn);
CheckSetting(iniFile, gameID, "AllowDownloadCLUT", &flags_.AllowDownloadCLUT);
CheckSetting(iniFile, gameID, "VRSkyplane", &flags_.VRSkyplane);
}

void Compatibility::CheckSetting(IniFile &iniFile, const std::string &gameID, const char *option, bool *flag) {
Expand Down
2 changes: 1 addition & 1 deletion Core/Compatibility.h
Expand Up @@ -89,10 +89,10 @@ struct CompatFlags {
bool SplitFramebufferMargin;
bool ForceLowerResolutionForEffectsOn;
bool AllowDownloadCLUT;
bool VRSkyplane;
};

struct VRCompat {
bool Skyplane;
float UnitsPerMeter;
};

Expand Down
17 changes: 0 additions & 17 deletions assets/compat.ini
Expand Up @@ -1302,20 +1302,3 @@ ULKS46087 = true

[AllowDownloadCLUT]
# Temporary compatibility option, while developing a GPU CLUT-from-framebuffer path.

[VRSkyplane]
# Grand Theft Auto: Liberty City Stories
ULUS10041 = true
ULES00151 = true
ULJM05255 = true
ULJM05359 = true
ULJM05885 = true
NPJH50825 = true

# Grand Theft Auto: Vice City Stories
ULES00502 = true
ULUS10160 = true
ULJM05297 = true
ULJM05395 = true
ULJM05884 = true
NPJH50827 = true
18 changes: 18 additions & 0 deletions assets/compatvr.ini
Expand Up @@ -29,6 +29,24 @@
# Issue numbers refer to issues on https://github.com/hrydgard/ppsspp/issues
# ========================================================================================


[Skyplane]
# Grand Theft Auto: Liberty City Stories
ULUS10041 = true
ULES00151 = true
ULJM05255 = true
ULJM05359 = true
ULJM05885 = true
NPJH50825 = true

# Grand Theft Auto: Vice City Stories
ULES00502 = true
ULUS10160 = true
ULJM05297 = true
ULJM05395 = true
ULJM05884 = true
NPJH50827 = true

[UnitsPerMeter]
# Values exported from https://github.com/CarlKenner/ppsspp/tree/VR/Sys/GameSettings
ELF000000 = 10.0
Expand Down

0 comments on commit e4f44e6

Please sign in to comment.