Key changes:
- Added "Sample Rate" to `ScreenOptionsGraphicsSound` with choices:
- "Default" (resolves to 44100 Hz for now)
- "44100 Hz"
- "48000 Hz"
- Created a new ConfOption "PreferredSampleRate" in `ScreenOptionsMasterPrefs.cpp` mapping UI choices to the integer values (0, 44100, 48000) for the existing `m_iSoundPreferredSampleRate` preference.
- Updated relevant sound drivers:
- DirectSound (RageSoundDriver_DSound_Software): Primary buffer now attempts to use the preferred rate. Secondary buffers already handled it correctly.
- WaveOut (RageSoundDriver_WaveOut): Already handled 0 as 44.1kHz correctly.
- PulseAudio (RageSoundDriver_PulseAudio): Ensured m_InitStream uses the constructor-initialized rate based on preference.
- AudioUnit (RageSoundDriver_AU): Already handled 0 as 44.1kHz and attempts to set hardware rate.
- OSS (RageSoundDriver_OSS): Updated to read and apply the preferred sample rate.
- WDMKS (RageSoundDriver_WDMKS): Updated to pass the resolved preferred rate to its stream opening logic.
- Null (RageSoundDriver_Null): Already handled 0 as 44.1kHz correctly.
- Updated `RageSoundReader_Chain` constructor to use the preferred system sample rate for its internal default.
- Added English localization for the new option title and explanation.
The implementation ensures that if the preference is 0 (Default), the system currently defaults to 44100 Hz across all drivers. This lays the groundwork for future dynamic hardware rate detection. A game restart is recommended for the new sample rate to take full effect.
This is required for the RString to std::string migration.
Mostly automated from https://github.com/aeubanks/rewriter/blob/main/c_str.cc, with some manual intervention required for fixing up `a + b.c_str()` to `(a + b).c_str()`.
Added some overloads for some common global functions like sm_crash to reduce the number of changes required here.
- Generally Supports either ITG (9ms) or NULL (0ms).
- Alternatively, one could edit the preference manually to put a different value
- Name/Description probably worth ironing out
Grant users the ability to change the maximum amount of credits available rather than the constant cap at 20.
(cherry picked from commit 2ec2355d7a7d9fec9410cf6b7d2b5c31a4406074)
(cherry picked from commit 48245ab51600ede16096e70e27c94345918eaed7)
* Use XRandR 1.2 to set fullscreen resolution for single output
Squash of roothorick's PR #497
(also includes Kyzentun's CMake changes from PR #716)
* Cherry-pick json c++1x stuff (b9e3d7174e)
* Cherry-pick c++11 support from 5bba5c0038 and 9f8b045309
* rework Linux (X11) fullscreen, improve display-related Graphics Options
Implement option to select between monitors for exclusive fullscreen mode
on X11 (using XRandR 1.2), or use a fullscreen borderless window.
Reimplement resolution/refresh rate/display mode-related option rows
using Lua, update choices dynamically so only known-good groupings of
resolution/refresh rate/aspect ratio can be selected.
Minimally update Windows/MacOS LowLevelWindow implementations to support
changes made for Linux side. Fullscreen Borderless Window/multi monitor
support from X11 not implemented for those in this commit.
* allow forcibly disabling xinerama use on Linux
When libXinerama is available, SM tries to use it to find the proper
monitor indexes to use to set _NET_WM_FULLSCREEN_MONITORS (on borderless
fullscreen). xfwm4 seems to assume that monitors are numbered in increasing
order from left to right (rather than using the Xinerama-assigned numbers),
so _NET_WM_FULLSCREEN_MONITORS misbehaves on Xfce.
This commit bypasses use of libXinerama, and instead forces SM to induce fullscreen
on the desired monitor in the backup, hacky way: remove all window hints, move window
to desired monitor, then add _NET_WM_STATE_FULLSCREEN hint. This works on
mutter and Xfce.
* Remove multiple warnings on redundant define.
This used to be hard-coded due to pthread related items, but now it's dynamically determined.
* fix _fallback menu behavior for unrecognized aspect ratios
* Fix error recreating existing FS texture
* Bump deployment target to 10.7 to use libc++ on XCode 8
* Add explicit casts to please clang
* Update changelog