Merge latest master changes

This commit is contained in:
Rodolfo Bogado 2017-08-19 14:01:13 -03:00
parent 82c99f375e
commit 2d35f037d8
334 changed files with 59906 additions and 21679 deletions

Binary file not shown.

View file

@ -0,0 +1,21 @@
# 1-2 - Wii System Menu
[Core]
# Values set here will override the main Dolphin settings.
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 5
EmulationIssues = Requires Safe Texture Cache to avoid input fields not updating.
[OnLoad]
# Add memory patches to be loaded once on boot here.
[OnFrame]
# Add memory patches to be applied every frame here.
[ActionReplay]
# Add action replay cheats here.
[Video_Settings]
SafeTextureCacheColorSamples = 0

View file

@ -0,0 +1,19 @@
# 1-2 - System Menu (v1, Startup Disc Menu)
[Core]
# Values set here will override the main Dolphin settings.
DSPHLE = False
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId =
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.
[OnFrame]
# Add memory patches to be applied every frame here.
[ActionReplay]
# Add action replay cheats here.

View file

@ -6,12 +6,10 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues =
EmulationIssues =
[Video]
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -5,11 +5,9 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationIssues =
EmulationIssues =
EmulationStateId = 4
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -9,6 +9,7 @@ EmulationIssues = Texture filtering will cause glitches.
EmulationStateId = 4
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Video_Hacks]
@ -24,6 +25,3 @@ EFBToTextureEnable = False
[Video_Enhancements]
MaxAnisotropy = 0
ForceFiltering = False
[Wii]
Widescreen = False

View file

@ -6,7 +6,7 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues = If EFB scale is not integral, serious texture glitches occur.
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.
@ -19,6 +19,4 @@ EmulationIssues = If EFB scale is not integral, serious texture glitches occur.
[Video_Settings]
EFBScale = -1
SafeTextureCacheColorSamples = 0

View file

@ -7,7 +7,7 @@ FPRF = True
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues = EFB must be an integer (integral, 1x, 2x, 3x).
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.

View file

@ -41,19 +41,15 @@ E0000000 80008000
[ActionReplay]
# Add action replay cheats here.
$Open all levels and nozzles (not working?)
$Open all levels and nozzles
04570958 FFFFFFFF
0457095C FFFFFFFF
$8 red coins(press L & B) (not working?)
0A3FBBF4 00000240
025709DE 00000008
$8 Red Coins on Gain
041BE42C 38A00008
$Infinite hover time
042640BC 60000000
$Infinite water
04263F58 38002710
042635B0 60000000
$Infinite health (not working?)
424057F4 00040009
$Infinite health
04243838 3BE00000
$Infinite Jetpack
0426C330 60000000
$Infinite Hose
@ -71,25 +67,6 @@ $Test Level
043E9710 00000C01
$Low Gravity
4240E12C 05003E00
$Jesus Mode A.K.A. Walk on Water D-Pad Up/Down = On/Off (not supported yet)
04002F00 3C608041
04002F04 8063E12C
04002F08 80C3FFCC
04002F0C 2C060000
04002F10 4D820020
04002F14 C2660008
04002F18 EE852824
04002F1C EE93A02A
04002F20 FC019840
04002F24 4C800020
04002F28 FC20A090
04002F2C 38C00008
04002F30 90C30248
04002F34 4E800020
0A404454 00000008
04189854 4BE796AC
0A404454 00000004
04189854 4E800020
$Do Not Have To Move Before Triple Jump
4240E10C 06B00000
$Spin Jump Gravity - Really Slow Fall
@ -126,20 +103,6 @@ $Warped camera view
044176A8 3E000000
$Poorly Shaded Mario
044176FC 00000000
# Press the buttons below to switch to another nozzle. You must have your nozzle set to squirt for it to work
# B+D-Pad Up: Rocket Nozzle
# B+D-Pad Left: Turbo Nozzle
# B+D-Pad Right: Hover Nozzle
# B+D-PadDown: Jump Nozzle
$Nozzle Modifier
0A404454 00000208
04269F50 3BE00001
0A404454 00000204
04269F50 3BE00002
0A404454 00000201
04269F50 3BE00005
0A404454 00000202
04269F50 3BE00004
$Always Green Yoshi
405F3A90 04AE4C00
$Hold B To Run Super Fast
@ -165,10 +128,86 @@ $D-Pad Left For Normal Mario
4240E12C 4DE63F80
4240E12C 4DE83F80
00000000 40000000
$Widescreen Heat Wave Fix [YoshiOG1]
043AA050 3F2AAAAB
043AA05C BF2AAAAB
043AA060 3F2AAAAB
043AA070 3FAAAAAB
$Remove Heat Wave
0419F83C 4E800020
[Gecko]
$Improved Jesus Mode A.K.A Walk on Water DPad Up/Down = On/Off
28404454 FFF70008
C224F134 0000000A
A8030000 2C000101
4082000C 60008000
B0030000 2C000102
4082000C 60008000
B0030000 2C000103
4082000C 60008000
B0030000 2C000100
4082000C 60008000
B0030000 7C030378
60000000 00000000
E2000001 80008000
28404454 FFFB0004
0424F134 A0630000
E2000001 80008000
$Infinite Water
C2141DD8 00000002
3B002710 93131C80
60000000 00000000
$Widescreen
04416758 44480000
044123E8 442F0000
04416620 442F0000
04176AA4 C002B83C
0429B974 C002B83C
04176C40 C002B83C
04176FF4 C002B83C
04177198 C002B83C
04412408 3FE38E39
04416B74 3F9A7643
0429610C 380002EA
042960A0 3860FF96
C214EF74 00000002
3B20FFA9 93380004
931F0140 00000000
C214EE24 00000002
3B20FFA9 93380004
931F0108 00000000
C214F09C 00000002
3860FFA9 90780004
931F0160 00000000
C214F308 00000002
3BA00251 93B80004
931F02F8 00000000
C214F70C 00000002
3860FFA9 90780004
931F0400 00000000
C214F830 00000002
3860FFA9 90780004
931F042C 00000000
C214F93C 00000002
3860FFA9 90780004
931F0450 00000000
C214D8EC 00000002
38800251 9081056C
807F02A0 00000000
0414E7D4 3880023C
C22CB330 00000004
2C00019F 40820008
38000203 2C00018D
40820008 380001F1
901F0014 00000000
C2156004 00000004
809F0018 38A0EC78
90A40014 7CA500D0
90A4001C 38800000
60000000 00000000
C214F114 00000002
3BA00258 93B80004
931F01C4 00000000
C2363138 00000009
80ED8D08 800701E8
540C24B6 2C030000
41820030 7C032A14
7C006000 41820024
5580F87E 7C601850
1C630003 1CA50003
7C631670 54A5F0BE
7C630194 7C630214
60000000 00000000

View file

@ -7,68 +7,103 @@
# Add memory patches to be applied every frame here.
$60 fps hack
0x804167B8:dword:0x3F600000
[Gecko]
$16:9
0440E0D4 3F9A7643
$21:9 (2560x1080)
0440E0D4 3FCE6087
$21:9 (3440x1440)
0440E0D4 3FCF8E94
[ActionReplay]
# Add action replay cheats here.
$99 Lives
00E60ADE 18000000
00570967 00000063
$Infinite Health
00E60ADF 18000000
424057F4 00040009
$Infinite water
00E6151F 18000000
04263F58 38002710
042635B0 60000000
$Infinite hover time
00E61520 18000000
042640BC 60000000
$8 Red coins (Press L+B)
00E61642 18000000
0A3FBBF4 00000240
025709DE 00000008
$8 Red Coins on Gain
041B62E4 38A00008
$Open Levels/Nozzles
00E60AE0 18000000
04570958 FFFFFFFF
0457095C FFFFFFFF
$All Shines
00E60AE1 18000000
045708E8 FFFFFFFF
045708EC FFFFFFFF
045708F0 FFFFFFFF
$Low Gravity
00E60AE2 18000000
424057F4 05003E00
$Low Spin Gravity
00E60AE3 18000000
424057F4 050A3200
$Super Spin
00E60AE4 18000000
424057F4 09423200
$Super Speed
00E60AE5 18000000
424057F4 06E44200
$Breath Underwater
00E60AE6 18000000
424057F4 08967FFF
$Have Sunshine Shirt
00E60AE7 18000000
424057F4 00000010
$Any Fruit Opens Yoshi Eggs
00E66B5B 18000000
041B47B8 60000000
$Yoshi Loves Water
00E66B5C 18000000
0426837C 4E800020
$Widescreen Heat Wave Fix
F0N5-B36H-HZDVX
6GRT-TJHW-8MR45
$Remove Heat Wave
041980C4 4E800020
[Gecko]
$Widescreen
0440DCB0 44480000
04409930 442F0000
0440DB78 442F0000
0416CA6C C002B6A4
04293850 C002B6A4
0416CC08 C002B6A4
0416CFBC C002B6A4
0416D160 C002B6A4
04409950 3FE38E39
0440E0D4 3F9A7643
0428DFA4 380002EA
0428DF38 3860FF96
C2143C04 00000002
3B20FFA9 93380004
931F0140 00000000
C2143AB4 00000002
3B20FFA9 93380004
931F0108 00000000
C2143D2C 00000002
3860FFA9 90780004
931F0160 00000000
C2143F98 00000002
3BA00251 93B80004
931F02F8 00000000
C214439C 00000002
3860FFA9 90780004
931F0400 00000000
C21444C0 00000002
3860FFA9 90780004
931F042C 00000000
C21445CC 00000002
3860FFA9 90780004
931F0450 00000000
C214257C 00000002
38800251 9081056C
807F02A0 00000000
04143464 3880023C
C22C33C4 00000004
2C00019F 40820008
38000203 2C00018D
40820008 380001F1
901F0014 00000000
C214B020 00000004
809F0018 38A0EC78
90A40014 7CA500D0
90A4001C 38800000
60000000 00000000
C2143DA4 00000002
3BA00258 93B80004
931F01C4 00000000
C235B358 00000009
80ED8CC8 800701E8
540C24B6 2C030000
41820030 7C032A14
7C006000 41820024
5580F87E 7C601850
1C630003 1CA50003
7C631670 54A5F0BE
7C630194 7C630214
60000000 00000000
$Full Water Tank
C21369EC 00000002
3B002710 93131C80
60000000 00000000

View file

@ -7,7 +7,7 @@ SyncGPU = True
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues = HLE music fades in and out. If EFB scale is not integral, 1x, 2x or 3x serious texture glitches occur
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.

View file

@ -5,8 +5,8 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 3
EmulationIssues = Will not connect. Uses WiiConnect24.
EmulationStateId = 5
EmulationIssues = Requires Safe Texture Cache to avoid input fields not updating.
[OnLoad]
# Add memory patches to be loaded once on boot here.
@ -20,3 +20,4 @@ EmulationIssues = Will not connect. Uses WiiConnect24.
[Video]
[Video_Settings]
SafeTextureCacheColorSamples = 0

View file

@ -5,11 +5,9 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationIssues =
EmulationIssues =
EmulationStateId = 4
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -6,12 +6,10 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues =
EmulationIssues =
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
UseXFB = True
UseRealXFB = True
[Wii]
Widescreen = False

View file

@ -5,11 +5,9 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationIssues =
EmulationIssues =
EmulationStateId = 4
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -1,4 +1,4 @@
# Nxxxxx - All Nintendo 64 Virtual Console games
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -1,4 +1,4 @@
# Pxxxxx - All TurboGrafx 16 Virtual Console games
# Pxxxxx - All TurboGrafx 16 Virtual Console games
# Note: there are a few weird GameCube games (mostly bonus disks) which also use this code.
[Core]
@ -7,12 +7,10 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues =
EmulationIssues =
[Video]
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -3,12 +3,10 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues =
EmulationIssues =
[Video]
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -18,7 +18,5 @@ EmulationIssues =
# Add action replay cheats here.
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 0
[Wii]
Widescreen = False

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -18,7 +18,5 @@ EmulationIssues =
# Add action replay cheats here.
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 512
[Wii]
Widescreen = False

View file

@ -18,7 +18,5 @@ EmulationIssues =
# Add action replay cheats here.
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 512
[Wii]
Widescreen = False

View file

@ -6,7 +6,7 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationStateId = 4
EmulationIssues = Needs integral scaling for the black lines to disappear.
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.
@ -20,4 +20,3 @@ EmulationIssues = Needs integral scaling for the black lines to disappear.
[Video_Settings]
EFBScale = -1
SafeTextureCacheColorSamples = 512

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -18,7 +18,5 @@ EmulationStateId = 5
# Add action replay cheats here.
[Video_Settings]
SuggestedAspectRatio = 2
SafeTextureCacheColorSamples = 512
[Wii]
Widescreen = False

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -20,5 +20,5 @@ EmulationIssues =
[Video_Hacks]
EFBEmulateFormatChanges = True
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -18,5 +18,5 @@ EmulationIssues = Needs Synchronise GPU thread for stability. Use direct3d11 for
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -20,5 +20,5 @@ EmulationIssues =
[Video_Hacks]
EFBEmulateFormatChanges = True
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -17,5 +17,5 @@ EmulationIssues =
[ActionReplay]
# Add action replay cheats here.
[Wii]
Widescreen = False
[Video_Settings]
SuggestedAspectRatio = 2

View file

@ -5,8 +5,8 @@
[EmuState]
# The Emulation State. 1 is worst, 5 is best, 0 is not set.
EmulationIssues = Skip any errors at startup and use integral efb scale.
EmulationStateId = 4
EmulationIssues =
[OnLoad]
# Add memory patches to be loaded once on boot here.
@ -20,4 +20,3 @@ EmulationStateId = 4
[Video_Settings]
EFBScale = -1
SafeTextureCacheColorSamples = 512

View file

@ -20,7 +20,6 @@ EmulationIssues =
[Video_Settings]
UseXFB = True
UseRealXFB = False
SafeTextureCacheColorSamples = 512
EFBScale = 2

Binary file not shown.

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -1,6 +1,9 @@
#!/bin/bash
cd ${0/gettextize/}/..
# This script updates the dolphin-emu.pot file to match the strings in
# the source code.
cd "$(dirname "$0")/.."
SRCDIR=Source
find $SRCDIR -name '*.cpp' -o -name '*.h' -o -name '*.c' | \
xgettext -d dolphin-emu -s --keyword=_ --keyword=wxTRANSLATE --keyword=SuccessAlertT \
@ -11,11 +14,3 @@ find $SRCDIR -name '*.cpp' -o -name '*.h' -o -name '*.c' | \
sed -i "s/SOME DESCRIPTIVE TITLE\./Translation of dolphin-emu.pot to LANGUAGE/" Languages/po/dolphin-emu.pot
sed -i "s/YEAR THE PACKAGE'S COPYRIGHT HOLDER/2003-2013/" Languages/po/dolphin-emu.pot
sed -i "s/license as the PACKAGE package/license as the dolphin-emu package/" Languages/po/dolphin-emu.pot
# XXX: Disabled now that we use Transifex (the tool will handle this automatically).
#POTFILE=./Languages/po/dolphin-emu.pot
#PO_FILES=$(find ./Languages/po -name '*.po')
#for PO in $PO_FILES
#do
# msgmerge --quiet --update --backup=none -s $PO $POTFILE
#done

View file

@ -0,0 +1,10 @@
#!/bin/bash
# This script goes through the translated .po files to ensure that they
# match dolphin-emu.pot and are correctly formatted. You must run this
# script before committing changes to the .po files, otherwise the .po
# files might get modified the next time you try to build using cmake.
cd "$(dirname "$0")/.."
POTFILE=./Languages/po/dolphin-emu.pot
find ./Languages/po -name '*.po' -exec msgmerge --quiet --update --backup=none -s {} $POTFILE \;

View file

@ -454,13 +454,13 @@ public final class SettingsAdapter extends RecyclerView.Adapter<SettingViewHolde
break;
case 1:
disableSpecializedShaders = new BooleanSetting(SettingsFile.KEY_DISABLE_SPECIALIZED_SHADERS, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, true);
backgroundShaderCompilation = new BooleanSetting(SettingsFile.KEY_BACKGROUND_SHADER_COMPILING, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, false);
disableSpecializedShaders = new BooleanSetting(SettingsFile.KEY_DISABLE_SPECIALIZED_SHADERS, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, false);
backgroundShaderCompilation = new BooleanSetting(SettingsFile.KEY_BACKGROUND_SHADER_COMPILING, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, true);
break;
case 2:
disableSpecializedShaders = new BooleanSetting(SettingsFile.KEY_DISABLE_SPECIALIZED_SHADERS, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, true);
backgroundShaderCompilation = new BooleanSetting(SettingsFile.KEY_BACKGROUND_SHADER_COMPILING, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, true);
backgroundShaderCompilation = new BooleanSetting(SettingsFile.KEY_BACKGROUND_SHADER_COMPILING, SettingsFile.SECTION_GFX_SETTINGS, SettingsFile.SETTINGS_GFX, false);
break;
}

View file

@ -104,9 +104,7 @@
<!-- Internal Resolution Preference -->
<string-array name="internalResolutionEntries" translatable="false">
<item>1x Native (640x528)</item>
<item>1.5x Native (960x792)</item>
<item>2x Native (1280x1056) for 720p</item>
<item>2.5x Native (1600x1320)</item>
<item>3x Native (1920x1584) for 1080p</item>
<item>4x Native (2560x2112)</item>
<item>5x Native (3200x2640)</item>
@ -114,9 +112,7 @@
</string-array>
<integer-array name="internalResolutionValues" translatable="false">
<item>2</item>
<item>3</item>
<item>4</item>
<item>5</item>
<item>6</item>
<item>7</item>
<item>8</item>

View file

@ -152,7 +152,7 @@ void Host_UpdateProgressDialog(const char* caption, int position, int total)
{
}
static bool MsgAlert(const char* caption, const char* text, bool yes_no, int /*Style*/)
static bool MsgAlert(const char* caption, const char* text, bool yes_no, MsgType /*style*/)
{
__android_log_print(ANDROID_LOG_ERROR, DOLPHIN_TAG, "%s:%s", caption, text);

View file

@ -4,7 +4,6 @@
#include "AudioCommon/AudioCommon.h"
#include "AudioCommon/AlsaSoundStream.h"
#include "AudioCommon/CoreAudioSoundStream.h"
#include "AudioCommon/CubebStream.h"
#include "AudioCommon/Mixer.h"
#include "AudioCommon/NullSoundStream.h"
@ -46,8 +45,6 @@ void InitSoundStream()
}
else if (backend == BACKEND_ALSA && AlsaSound::isValid())
g_sound_stream = std::make_unique<AlsaSound>();
else if (backend == BACKEND_COREAUDIO && CoreAudioSound::isValid())
g_sound_stream = std::make_unique<CoreAudioSound>();
else if (backend == BACKEND_PULSEAUDIO && PulseAudio::isValid())
g_sound_stream = std::make_unique<PulseAudio>();
else if (backend == BACKEND_OPENSLES && OpenSLESStream::isValid())
@ -101,7 +98,7 @@ std::string GetDefaultSoundBackend()
if (AlsaSound::isValid())
backend = BACKEND_ALSA;
#elif defined __APPLE__
backend = BACKEND_COREAUDIO;
backend = BACKEND_CUBEB;
#elif defined _WIN32
backend = BACKEND_XAUDIO2;
#endif
@ -117,9 +114,7 @@ std::vector<std::string> GetSoundBackends()
if (XAudio2_7::isValid() || XAudio2::isValid())
backends.push_back(BACKEND_XAUDIO2);
if (AlsaSound::isValid())
backends.push_back(BACKEND_ALSA);
if (CoreAudioSound::isValid())
backends.push_back(BACKEND_COREAUDIO);
backends.push_back(BACKEND_ALSA);
if (PulseAudio::isValid())
backends.push_back(BACKEND_PULSEAUDIO);
if (OpenALStream::isValid())
@ -152,7 +147,7 @@ bool SupportsVolumeChanges(const std::string& backend)
// FIXME: this one should ask the backend whether it supports it.
// but getting the backend from string etc. is probably
// too much just to enable/disable a stupid slider...
return backend == BACKEND_COREAUDIO || backend == BACKEND_CUBEB || backend == BACKEND_OPENAL ||
return backend == BACKEND_CUBEB || backend == BACKEND_OPENAL ||
backend == BACKEND_XAUDIO2;
}

View file

@ -54,7 +54,6 @@
<ClInclude Include="AlsaSoundStream.h" />
<ClInclude Include="AudioCommon.h" />
<ClInclude Include="AudioStretcher.h" />
<ClInclude Include="CoreAudioSoundStream.h" />
<ClInclude Include="CubebStream.h" />
<ClInclude Include="CubebUtils.h" />
<ClInclude Include="DPL2Decoder.h" />

View file

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="SoundStreams">
@ -53,9 +53,6 @@
<ClInclude Include="OpenSLESStream.h">
<Filter>SoundStreams</Filter>
</ClInclude>
<ClInclude Include="CoreAudioSoundStream.h">
<Filter>SoundStreams</Filter>
</ClInclude>
<ClInclude Include="AlsaSoundStream.h">
<Filter>SoundStreams</Filter>
</ClInclude>
@ -69,4 +66,4 @@
<ItemGroup>
<Text Include="CMakeLists.txt" />
</ItemGroup>
</Project>
</Project>

View file

@ -67,9 +67,6 @@ if(WIN32)
else()
message(FATAL_ERROR "OpenAL NOT found in Externals")
endif()
elseif(APPLE)
target_sources(audiocommon PRIVATE CoreAudioSoundStream.cpp)
endif()
target_link_libraries(audiocommon PRIVATE cubeb SoundTouch)

View file

@ -1,123 +0,0 @@
// Copyright 2009 Dolphin Emulator Project
// Licensed under GPLv2+
// Refer to the license.txt file included.
#include <AudioUnit/AudioUnit.h>
#include "AudioCommon/CoreAudioSoundStream.h"
#include "Common/Logging/Log.h"
OSStatus CoreAudioSound::callback(void* inRefCon, AudioUnitRenderActionFlags* ioActionFlags,
const AudioTimeStamp* inTimeStamp, UInt32 inBusNumber,
UInt32 inNumberFrames, AudioBufferList* ioData)
{
for (UInt32 i = 0; i < ioData->mNumberBuffers; i++)
((CoreAudioSound*)inRefCon)
->m_mixer->Mix((short*)ioData->mBuffers[i].mData, ioData->mBuffers[i].mDataByteSize / 4);
return noErr;
}
bool CoreAudioSound::Start()
{
OSStatus err;
AURenderCallbackStruct callback_struct;
AudioStreamBasicDescription format;
AudioComponentDescription desc;
AudioComponent component;
desc.componentType = kAudioUnitType_Output;
desc.componentSubType = kAudioUnitSubType_DefaultOutput;
desc.componentFlags = 0;
desc.componentFlagsMask = 0;
desc.componentManufacturer = kAudioUnitManufacturer_Apple;
component = AudioComponentFindNext(nullptr, &desc);
if (component == nullptr)
{
ERROR_LOG(AUDIO, "error finding audio component");
return false;
}
err = AudioComponentInstanceNew(component, &audioUnit);
if (err != noErr)
{
ERROR_LOG(AUDIO, "error opening audio component");
return false;
}
FillOutASBDForLPCM(format, m_mixer->GetSampleRate(), 2, 16, 16, false, false, false);
err = AudioUnitSetProperty(audioUnit, kAudioUnitProperty_StreamFormat, kAudioUnitScope_Input, 0,
&format, sizeof(AudioStreamBasicDescription));
if (err != noErr)
{
ERROR_LOG(AUDIO, "error setting audio format");
return false;
}
callback_struct.inputProc = callback;
callback_struct.inputProcRefCon = this;
err = AudioUnitSetProperty(audioUnit, kAudioUnitProperty_SetRenderCallback, kAudioUnitScope_Input,
0, &callback_struct, sizeof callback_struct);
if (err != noErr)
{
ERROR_LOG(AUDIO, "error setting audio callback");
return false;
}
err = AudioUnitSetParameter(audioUnit, kHALOutputParam_Volume, kAudioUnitScope_Output, 0,
m_volume / 100., 0);
if (err != noErr)
ERROR_LOG(AUDIO, "error setting volume");
err = AudioUnitInitialize(audioUnit);
if (err != noErr)
{
ERROR_LOG(AUDIO, "error initializing audiounit");
return false;
}
err = AudioOutputUnitStart(audioUnit);
if (err != noErr)
{
ERROR_LOG(AUDIO, "error starting audiounit");
return false;
}
return true;
}
void CoreAudioSound::SetVolume(int volume)
{
OSStatus err;
m_volume = volume;
err = AudioUnitSetParameter(audioUnit, kHALOutputParam_Volume, kAudioUnitScope_Output, 0,
volume / 100., 0);
if (err != noErr)
ERROR_LOG(AUDIO, "error setting volume");
}
void CoreAudioSound::SoundLoop()
{
}
void CoreAudioSound::Stop()
{
OSStatus err;
err = AudioOutputUnitStop(audioUnit);
if (err != noErr)
ERROR_LOG(AUDIO, "error stopping audiounit");
err = AudioUnitUninitialize(audioUnit);
if (err != noErr)
ERROR_LOG(AUDIO, "error uninitializing audiounit");
err = AudioComponentInstanceDispose(audioUnit);
if (err != noErr)
ERROR_LOG(AUDIO, "error closing audio component");
}
void CoreAudioSound::Update()
{
}

View file

@ -1,32 +0,0 @@
// Copyright 2008 Dolphin Emulator Project
// Licensed under GPLv2+
// Refer to the license.txt file included.
#pragma once
#ifdef __APPLE__
#include <AudioUnit/AudioUnit.h>
#endif
#include "AudioCommon/SoundStream.h"
class CoreAudioSound final : public SoundStream
{
#ifdef __APPLE__
public:
bool Start() override;
void SetVolume(int volume) override;
void SoundLoop() override;
void Stop() override;
void Update() override;
static bool isValid() { return true; }
private:
AudioUnit audioUnit;
int m_volume;
static OSStatus callback(void* inRefCon, AudioUnitRenderActionFlags* ioActionFlags,
const AudioTimeStamp* inTimeStamp, UInt32 inBusNumber,
UInt32 inNumberFrames, AudioBufferList* ioData);
#endif
};

File diff suppressed because it is too large Load diff

View file

@ -60,171 +60,171 @@ enum ARM64Reg
WSP, // 32bit stack pointer
// 64bit registers
X0 = 0x20,
X1,
X2,
X3,
X4,
X5,
X6,
X7,
X8,
X9,
X10,
X11,
X12,
X13,
X14,
X15,
X16,
X17,
X18,
X19,
X20,
X21,
X22,
X23,
X24,
X25,
X26,
X27,
X28,
X29,
X30,
// 64bit registers
X0 = 0x20,
X1,
X2,
X3,
X4,
X5,
X6,
X7,
X8,
X9,
X10,
X11,
X12,
X13,
X14,
X15,
X16,
X17,
X18,
X19,
X20,
X21,
X22,
X23,
X24,
X25,
X26,
X27,
X28,
X29,
X30,
SP, // 64bit stack pointer
SP, // 64bit stack pointer
// VFP single precision registers
S0 = 0x40,
S1,
S2,
S3,
S4,
S5,
S6,
S7,
S8,
S9,
S10,
S11,
S12,
S13,
S14,
S15,
S16,
S17,
S18,
S19,
S20,
S21,
S22,
S23,
S24,
S25,
S26,
S27,
S28,
S29,
S30,
S31,
// VFP single precision registers
S0 = 0x40,
S1,
S2,
S3,
S4,
S5,
S6,
S7,
S8,
S9,
S10,
S11,
S12,
S13,
S14,
S15,
S16,
S17,
S18,
S19,
S20,
S21,
S22,
S23,
S24,
S25,
S26,
S27,
S28,
S29,
S30,
S31,
// VFP Double Precision registers
D0 = 0x80,
D1,
D2,
D3,
D4,
D5,
D6,
D7,
D8,
D9,
D10,
D11,
D12,
D13,
D14,
D15,
D16,
D17,
D18,
D19,
D20,
D21,
D22,
D23,
D24,
D25,
D26,
D27,
D28,
D29,
D30,
D31,
// VFP Double Precision registers
D0 = 0x80,
D1,
D2,
D3,
D4,
D5,
D6,
D7,
D8,
D9,
D10,
D11,
D12,
D13,
D14,
D15,
D16,
D17,
D18,
D19,
D20,
D21,
D22,
D23,
D24,
D25,
D26,
D27,
D28,
D29,
D30,
D31,
// ASIMD Quad-Word registers
Q0 = 0xC0,
Q1,
Q2,
Q3,
Q4,
Q5,
Q6,
Q7,
Q8,
Q9,
Q10,
Q11,
Q12,
Q13,
Q14,
Q15,
Q16,
Q17,
Q18,
Q19,
Q20,
Q21,
Q22,
Q23,
Q24,
Q25,
Q26,
Q27,
Q28,
Q29,
Q30,
Q31,
// ASIMD Quad-Word registers
Q0 = 0xC0,
Q1,
Q2,
Q3,
Q4,
Q5,
Q6,
Q7,
Q8,
Q9,
Q10,
Q11,
Q12,
Q13,
Q14,
Q15,
Q16,
Q17,
Q18,
Q19,
Q20,
Q21,
Q22,
Q23,
Q24,
Q25,
Q26,
Q27,
Q28,
Q29,
Q30,
Q31,
// For PRFM(prefetch memory) encoding
// This is encoded in the Rt register
// Data preload
PLDL1KEEP = 0,
PLDL1STRM,
PLDL2KEEP,
PLDL2STRM,
PLDL3KEEP,
PLDL3STRM,
// Instruction preload
PLIL1KEEP = 8,
PLIL1STRM,
PLIL2KEEP,
PLIL2STRM,
PLIL3KEEP,
PLIL3STRM,
// Prepare for store
PLTL1KEEP = 16,
PLTL1STRM,
PLTL2KEEP,
PLTL2STRM,
PLTL3KEEP,
PLTL3STRM,
// For PRFM(prefetch memory) encoding
// This is encoded in the Rt register
// Data preload
PLDL1KEEP = 0,
PLDL1STRM,
PLDL2KEEP,
PLDL2STRM,
PLDL3KEEP,
PLDL3STRM,
// Instruction preload
PLIL1KEEP = 8,
PLIL1STRM,
PLIL2KEEP,
PLIL2STRM,
PLIL3KEEP,
PLIL3STRM,
// Prepare for store
PLTL1KEEP = 16,
PLTL1STRM,
PLTL2KEEP,
PLTL2STRM,
PLTL3KEEP,
PLTL3STRM,
WZR = WSP,
ZR = SP,
WZR = WSP,
ZR = SP,
INVALID_REG = 0xFFFFFFFF
INVALID_REG = 0xFFFFFFFF
};
constexpr bool Is64Bit(ARM64Reg reg)
@ -279,7 +279,7 @@ constexpr ARM64Reg EncodeRegToQuad(ARM64Reg reg)
// For AND/TST/ORR/EOR etc
bool IsImmLogical(uint64_t value, unsigned int width, unsigned int* n, unsigned int* imm_s,
unsigned int* imm_r);
unsigned int* imm_r);
// For ADD/SUB
bool IsImmArithmetic(uint64_t input, u32* val, bool* shift);
@ -513,7 +513,7 @@ private:
void EncodeExceptionInst(u32 instenc, u32 imm);
void EncodeSystemInst(u32 op0, u32 op1, u32 CRn, u32 CRm, u32 op2, ARM64Reg Rt);
void EncodeArithmeticInst(u32 instenc, bool flags, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm,
ArithOption Option);
ArithOption Option);
void EncodeArithmeticCarryInst(u32 op, bool flags, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
void EncodeCondCompareImmInst(u32 op, ARM64Reg Rn, u32 imm, u32 nzcv, CCFlags cond);
void EncodeCondCompareRegInst(u32 op, ARM64Reg Rn, ARM64Reg Rm, u32 nzcv, CCFlags cond);
@ -533,7 +533,7 @@ private:
void EncodeAddSubImmInst(u32 op, bool flags, u32 shift, u32 imm, ARM64Reg Rn, ARM64Reg Rd);
void EncodeLogicalImmInst(u32 op, ARM64Reg Rd, ARM64Reg Rn, u32 immr, u32 imms, int n);
void EncodeLoadStorePair(u32 op, u32 load, IndexType type, ARM64Reg Rt, ARM64Reg Rt2, ARM64Reg Rn,
s32 imm);
s32 imm);
void EncodeAddressInst(u32 op, ARM64Reg Rd, s32 imm);
void EncodeLoadStoreUnscaled(u32 size, u32 op, ARM64Reg Rt, ARM64Reg Rn, s32 imm);
@ -721,7 +721,7 @@ public:
void MOV(ARM64Reg Rd, ARM64Reg Rm);
void MVN(ARM64Reg Rd, ARM64Reg Rm);
// TODO: These are "slow" as they use arith+shift, should be replaced with UBFM/EXTR variants.
// Convenience wrappers around UBFM/EXTR.
void LSR(ARM64Reg Rd, ARM64Reg Rm, int shift);
void LSL(ARM64Reg Rd, ARM64Reg Rm, int shift);
void ASR(ARM64Reg Rd, ARM64Reg Rm, int shift);
@ -863,7 +863,7 @@ public:
void CMPI2R(ARM64Reg Rn, u64 imm, ARM64Reg scratch = INVALID_REG);
void ADDI2R_internal(ARM64Reg Rd, ARM64Reg Rn, u64 imm, bool negative, bool flags,
ARM64Reg scratch);
ARM64Reg scratch);
void ADDI2R(ARM64Reg Rd, ARM64Reg Rn, u64 imm, ARM64Reg scratch = INVALID_REG);
void ADDSI2R(ARM64Reg Rd, ARM64Reg Rn, u64 imm, ARM64Reg scratch = INVALID_REG);
void SUBI2R(ARM64Reg Rd, ARM64Reg Rn, u64 imm, ARM64Reg scratch = INVALID_REG);
@ -953,7 +953,7 @@ public:
void FSQRT(ARM64Reg Rd, ARM64Reg Rn);
void FMOV(ARM64Reg Rd, ARM64Reg Rn, bool top = false); // Also generalized move between GPR/FP
// Scalar - 2 Source
// Scalar - 2 Source
void FADD(ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
void FMUL(ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
void FSUB(ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
@ -1095,18 +1095,18 @@ private:
// Emitting functions
void EmitLoadStoreImmediate(u8 size, u32 opc, IndexType type, ARM64Reg Rt, ARM64Reg Rn, s32 imm);
void EmitScalar2Source(bool M, bool S, u32 type, u32 opcode, ARM64Reg Rd, ARM64Reg Rn,
ARM64Reg Rm);
ARM64Reg Rm);
void EmitThreeSame(bool U, u32 size, u32 opcode, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
void EmitCopy(bool Q, u32 op, u32 imm5, u32 imm4, ARM64Reg Rd, ARM64Reg Rn);
void Emit2RegMisc(bool Q, bool U, u32 size, u32 opcode, ARM64Reg Rd, ARM64Reg Rn);
void EmitLoadStoreSingleStructure(bool L, bool R, u32 opcode, bool S, u32 size, ARM64Reg Rt,
ARM64Reg Rn);
ARM64Reg Rn);
void EmitLoadStoreSingleStructure(bool L, bool R, u32 opcode, bool S, u32 size, ARM64Reg Rt,
ARM64Reg Rn, ARM64Reg Rm);
ARM64Reg Rn, ARM64Reg Rm);
void Emit1Source(bool M, bool S, u32 type, u32 opcode, ARM64Reg Rd, ARM64Reg Rn);
void EmitConversion(bool sf, bool S, u32 type, u32 rmode, u32 opcode, ARM64Reg Rd, ARM64Reg Rn);
void EmitConversion2(bool sf, bool S, bool direction, u32 type, u32 rmode, u32 opcode, int scale,
ARM64Reg Rd, ARM64Reg Rn);
ARM64Reg Rd, ARM64Reg Rn);
void EmitCompare(bool M, bool S, u32 op, u32 opcode2, ARM64Reg Rn, ARM64Reg Rm);
void EmitCondSelect(bool M, bool S, CCFlags cond, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
void EmitPermute(u32 size, u32 op, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm);
@ -1115,16 +1115,16 @@ private:
void EmitScalarShiftImm(bool U, u32 immh, u32 immb, u32 opcode, ARM64Reg Rd, ARM64Reg Rn);
void EmitLoadStoreMultipleStructure(u32 size, bool L, u32 opcode, ARM64Reg Rt, ARM64Reg Rn);
void EmitLoadStoreMultipleStructurePost(u32 size, bool L, u32 opcode, ARM64Reg Rt, ARM64Reg Rn,
ARM64Reg Rm);
ARM64Reg Rm);
void EmitScalar1Source(bool M, bool S, u32 type, u32 opcode, ARM64Reg Rd, ARM64Reg Rn);
void EmitVectorxElement(bool U, u32 size, bool L, u32 opcode, bool H, ARM64Reg Rd, ARM64Reg Rn,
ARM64Reg Rm);
ARM64Reg Rm);
void EmitLoadStoreUnscaled(u32 size, u32 op, ARM64Reg Rt, ARM64Reg Rn, s32 imm);
void EmitConvertScalarToInt(ARM64Reg Rd, ARM64Reg Rn, RoundingMode round, bool sign);
void EmitScalar3Source(bool isDouble, ARM64Reg Rd, ARM64Reg Rn, ARM64Reg Rm, ARM64Reg Ra,
int opcode);
int opcode);
void EncodeLoadStorePair(u32 size, bool load, IndexType type, ARM64Reg Rt, ARM64Reg Rt2,
ARM64Reg Rn, s32 imm);
ARM64Reg Rn, s32 imm);
void EncodeLoadStoreRegisterOffset(u32 size, bool load, ARM64Reg Rt, ARM64Reg Rn, ArithOption Rm);
void EncodeModImm(bool Q, u8 op, u8 cmode, u8 o2, ARM64Reg Rd, u8 abcdefgh);

View file

@ -6,6 +6,9 @@ set(SRCS
Config/Config.cpp
Config/Layer.cpp
Config/Section.cpp
Crypto/AES.cpp
Crypto/bn.cpp
Crypto/ec.cpp
ENetUtil.cpp
File.cpp
FileSearch.cpp
@ -15,7 +18,9 @@ set(SRCS
HttpRequest.cpp
IniFile.cpp
JitRegister.cpp
Logging/LogManager.cpp
MathUtil.cpp
MD5.cpp
MemArena.cpp
MemoryUtil.cpp
MsgHandler.cpp
@ -32,14 +37,10 @@ set(SRCS
Thread.cpp
Timer.cpp
TraversalClient.cpp
UPnP.cpp
Version.cpp
x64ABI.cpp
x64Emitter.cpp
MD5.cpp
Crypto/AES.cpp
Crypto/bn.cpp
Crypto/ec.cpp
Logging/LogManager.cpp
)
set(LIBS ${LIBS} ${MBEDTLS_LIBRARIES})
@ -119,6 +120,10 @@ endif()
add_dolphin_library(common "${SRCS}" "${LIBS}")
if(OPROFILE_FOUND)
target_link_libraries(common PRIVATE ${OPROFILE_LIBRARIES})
endif()
if(UNIX)
# Posix networking code needs to be fixed for Windows
add_executable(traversal_server TraversalServer.cpp)

View file

@ -128,6 +128,7 @@
<ClInclude Include="HttpRequest.h" />
<ClInclude Include="IniFile.h" />
<ClInclude Include="JitRegister.h" />
<ClInclude Include="Lazy.h" />
<ClInclude Include="LdrWatcher.h" />
<ClInclude Include="LinearDiskCache.h" />
<ClInclude Include="MathUtil.h" />
@ -153,6 +154,7 @@
<ClInclude Include="Timer.h" />
<ClInclude Include="TraversalClient.h" />
<ClInclude Include="TraversalProto.h" />
<ClInclude Include="UPnP.h" />
<ClInclude Include="x64ABI.h" />
<ClInclude Include="x64Emitter.h" />
<ClInclude Include="x64Reg.h" />
@ -205,6 +207,7 @@
<ClCompile Include="ThreadPool.cpp" />
<ClCompile Include="Timer.cpp" />
<ClCompile Include="TraversalClient.cpp" />
<ClCompile Include="UPnP.cpp" />
<ClCompile Include="Version.cpp" />
<ClCompile Include="x64ABI.cpp" />
<ClCompile Include="x64CPUDetect.cpp" />

View file

@ -260,6 +260,8 @@
<ClInclude Include="File.h" />
<ClInclude Include="LdrWatcher.h" />
<ClInclude Include="GL\GLExtensions\ARB_texture_compression_bptc.h" />
<ClInclude Include="Lazy.h" />
<ClInclude Include="UPnP.h" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="CDUtils.cpp" />
@ -330,6 +332,7 @@
<ClCompile Include="File.cpp" />
<ClCompile Include="LdrWatcher.cpp" />
<ClCompile Include="CompatPatches.cpp" />
<ClCompile Include="UPnP.cpp" />
</ItemGroup>
<ItemGroup>
<Text Include="CMakeLists.txt" />

View file

@ -38,17 +38,6 @@ void AddLayer(std::unique_ptr<ConfigLayerLoader> loader)
AddLayer(std::make_unique<Layer>(std::move(loader)));
}
void AddLoadLayer(std::unique_ptr<Layer> layer)
{
layer->Load();
AddLayer(std::move(layer));
}
void AddLoadLayer(std::unique_ptr<ConfigLayerLoader> loader)
{
AddLoadLayer(std::make_unique<Layer>(std::move(loader)));
}
Layer* GetLayer(LayerType layer)
{
if (!LayerExists(layer))
@ -112,7 +101,7 @@ void ClearCurrentRunLayer()
static const std::map<System, std::string> system_to_name = {
{ System::Main, "Dolphin" },{ System::GCPad, "GCPad" },{ System::WiiPad, "Wiimote" },
{ System::GCKeyboard, "GCKeyboard" },{ System::GFX, "Graphics" },{ System::Logger, "Logger" },
{ System::Debugger, "Debugger" },{ System::UI, "UI" },
{ System::Debugger, "Debugger" },{ System::UI, "UI" },{ System::SYSCONF, "SYSCONF" }
};
const std::string& GetSystemName(System system)

View file

@ -43,8 +43,6 @@ Section* GetOrCreateSection(System system, const std::string& section_name);
Layers* GetLayers();
void AddLayer(std::unique_ptr<Layer> layer);
void AddLayer(std::unique_ptr<ConfigLayerLoader> loader);
void AddLoadLayer(std::unique_ptr<Layer> layer);
void AddLoadLayer(std::unique_ptr<ConfigLayerLoader> loader);
Layer* GetLayer(LayerType layer);
void RemoveLayer(LayerType layer);
bool LayerExists(LayerType layer);
@ -68,9 +66,7 @@ LayerType GetActiveLayerForConfig(const ConfigLocation&);
template <typename T>
T Get(LayerType layer, const ConfigInfo<T>& info)
{
return GetLayer(layer)
->GetOrCreateSection(info.location.system, info.location.section)
->template Get<T>(info.location.key, info.default_value);
return GetLayer(layer)->Get(info);
}
template <typename T>
@ -94,9 +90,8 @@ LayerType GetActiveLayerForConfig(const ConfigInfo<T>& info)
template <typename T>
void Set(LayerType layer, const ConfigInfo<T>& info, const T& value)
{
GetLayer(layer)
->GetOrCreateSection(info.location.system, info.location.section)
->Set(info.location.key, value);
GetLayer(layer)->Set(info, value);
InvokeConfigChangedCallbacks();
}
template <typename T>

View file

@ -23,6 +23,7 @@ enum class LayerType
enum class System
{
Main,
SYSCONF,
GCPad,
WiiPad,
GCKeyboard,

View file

@ -28,7 +28,7 @@ Layer::Layer(LayerType type) : m_layer(type)
}
Layer::Layer(std::unique_ptr<ConfigLayerLoader> loader)
: m_layer(loader->GetLayer()), m_loader(std::move(loader))
: m_layer(loader->GetLayer()), m_loader(std::move(loader))
{
Load();
}
@ -70,7 +70,7 @@ Section* Layer::GetOrCreateSection(System system, const std::string& section_nam
if (m_layer == LayerType::Meta)
{
m_sections[system].emplace_back(
std::make_unique<RecursiveSection>(m_layer, system, section_name));
std::make_unique<RecursiveSection>(m_layer, system, section_name));
}
else
{
@ -109,16 +109,11 @@ const LayerMap& Layer::GetLayerMap() const
return m_sections;
}
ConfigLayerLoader* Layer::GetLoader() const
{
return m_loader.get();
}
bool Layer::IsDirty() const
{
return std::any_of(m_sections.begin(), m_sections.end(), [](const auto& system) {
return std::any_of(system.second.begin(), system.second.end(),
[](const auto& section) { return section->IsDirty(); });
[](const auto& section) { return section->IsDirty(); });
});
}
@ -126,7 +121,7 @@ void Layer::ClearDirty()
{
std::for_each(m_sections.begin(), m_sections.end(), [](auto& system) {
std::for_each(system.second.begin(), system.second.end(),
[](auto& section) { section->ClearDirty(); });
[](auto& section) { section->ClearDirty(); });
});
}
@ -146,7 +141,7 @@ Section* RecursiveLayer::GetOrCreateSection(System system, const std::string& se
if (!section)
{
m_sections[system].emplace_back(
std::make_unique<RecursiveSection>(m_layer, system, section_name));
std::make_unique<RecursiveSection>(m_layer, system, section_name));
section = m_sections[system].back().get();
}
return section;

View file

@ -14,6 +14,9 @@
namespace Config
{
template <typename T>
struct ConfigInfo;
using LayerMap = std::map<System, std::vector<std::unique_ptr<Section>>>;
class ConfigLayerLoader
@ -52,14 +55,26 @@ public:
virtual Section* GetSection(System system, const std::string& section_name);
virtual Section* GetOrCreateSection(System system, const std::string& section_name);
template <typename T>
T Get(const ConfigInfo<T>& config_info)
{
return GetOrCreateSection(config_info.location.system, config_info.location.section)
->template Get<T>(config_info.location.key, config_info.default_value);
}
template <typename T>
void Set(const ConfigInfo<T>& config_info, const T& value)
{
GetOrCreateSection(config_info.location.system, config_info.location.section)
->Set(config_info.location.key, value);
}
// Explicit load and save of layers
void Load();
void Save();
LayerType GetLayer() const;
const LayerMap& GetLayerMap() const;
// Stay away from this routine as much as possible
ConfigLayerLoader* GetLoader() const;
protected:
bool IsDirty() const;

View file

@ -17,7 +17,7 @@ namespace Config
const std::string& Section::NULL_STRING = "";
Section::Section(LayerType layer, System system, const std::string& name)
: m_layer(layer), m_system(system), m_name(name)
: m_layer(layer), m_system(system), m_name(name)
{
}
@ -54,6 +54,11 @@ void Section::Set(const std::string& key, const std::string& value)
}
}
void Section::Set(const std::string& key, u16 newValue)
{
Section::Set(key, StringFromFormat("0x%04x", newValue));
}
void Section::Set(const std::string& key, u32 newValue)
{
Section::Set(key, StringFromFormat("0x%08x", newValue));
@ -80,7 +85,7 @@ void Section::Set(const std::string& key, bool newValue)
}
void Section::Set(const std::string& key, const std::string& newValue,
const std::string& defaultValue)
const std::string& defaultValue)
{
if (newValue != defaultValue)
Set(key, newValue);
@ -95,7 +100,7 @@ void Section::SetLines(const std::vector<std::string>& lines)
}
bool Section::Get(const std::string& key, std::string* value,
const std::string& default_value) const
const std::string& default_value) const
{
const auto& it = m_values.find(key);
if (it != m_values.end())
@ -124,6 +129,18 @@ bool Section::Get(const std::string& key, int* value, int defaultValue) const
return false;
}
bool Section::Get(const std::string& key, u16* value, u16 defaultValue) const
{
std::string temp;
bool retval = Get(key, &temp);
if (retval && TryParse(temp, value))
return true;
*value = defaultValue;
return false;
}
bool Section::Get(const std::string& key, u32* value, u32 defaultValue) const
{
std::string temp;
@ -231,7 +248,7 @@ void Section::ClearDirty()
}
RecursiveSection::RecursiveSection(LayerType layer, System system, const std::string& name)
: Section(layer, system, name)
: Section(layer, system, name)
{
}
@ -251,7 +268,7 @@ bool RecursiveSection::Exists(const std::string& key) const
}
bool RecursiveSection::Get(const std::string& key, std::string* value,
const std::string& default_value) const
const std::string& default_value) const
{
for (auto layer_id : SEARCH_ORDER)
{

View file

@ -35,6 +35,7 @@ public:
// Setters
virtual void Set(const std::string& key, const std::string& value);
void Set(const std::string& key, u16 newValue);
void Set(const std::string& key, u32 newValue);
void Set(const std::string& key, float newValue);
void Set(const std::string& key, double newValue);
@ -54,9 +55,10 @@ public:
// Getters
virtual bool Get(const std::string& key, std::string* value,
const std::string& default_value = NULL_STRING) const;
const std::string& default_value = NULL_STRING) const;
bool Get(const std::string& key, int* value, int defaultValue = 0) const;
bool Get(const std::string& key, u16* value, u16 defaultValue = 0) const;
bool Get(const std::string& key, u32* value, u32 defaultValue = 0) const;
bool Get(const std::string& key, bool* value, bool defaultValue = false) const;
bool Get(const std::string& key, float* value, float defaultValue = 0.0f) const;
@ -104,7 +106,7 @@ public:
bool Exists(const std::string& key) const override;
bool Get(const std::string& key, std::string* value,
const std::string& default_value = NULL_STRING) const override;
const std::string& default_value = NULL_STRING) const override;
void Set(const std::string& key, const std::string& value) override;
};

View file

@ -85,7 +85,7 @@ void IOFile::SetHandle(std::FILE* file)
m_file = file;
}
u64 IOFile::GetSize()
u64 IOFile::GetSize() const
{
if (IsOpen())
return File::GetSize(m_file);

View file

@ -74,7 +74,7 @@ public:
bool Seek(s64 off, int origin);
u64 Tell() const;
u64 GetSize();
u64 GetSize() const;
bool Resize(u64 size);
bool Flush();

View file

@ -1742,7 +1742,7 @@ const GLFunc gl_function_array[] = {
"GL_OES_draw_elements_base_vertex VERSION_GLES_3 !VERSION_GLES_3_2"),
GLFUNC_SUFFIX(glDrawRangeElementsBaseVertex, OES,
"GL_OES_draw_elements_base_vertex VERSION_GLES_3 !VERSION_GLES_3_2"),
GLFUNC_SUFFIX(glMultiDrawElementsBaseVertex, OES,
GLFUNC_SUFFIX(glMultiDrawElementsBaseVertex, EXT,
"GL_OES_draw_elements_base_vertex GL_EXT_multi_draw_arrays"),
// EXT_draw_elements_base_vertex

Some files were not shown because too many files have changed in this diff Show more