mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-10-11 16:48:23 +03:00
## Link to GitHub Issue or related Pull Request, if one exists Fixes #717, fixes #647 ## Description of change Adds an option to downmix surround sound (5.1, 7.1, etc) down to stereo (2 speakers). This can be used in most WASAPI games, including Gitadora and FTT. How it works: when the game tries to open surround format (say, 7.1) we create a fake buffer and tell the game that it is supported. In reality we open a 2-channel stream with the real sound card. When the stream begins, we downmix the channels down to two (using one of many algorithms) and output to the sound card. While we're here, implement an option to boost the game volume by some decibel value, which is a feature often requested by SDVX players. This was needed since downmixing can sometimes result in quieter audio. ## Testing Tested GW Delta and FTT. Downmix doesn't work on IIDX (32 bits) but volume boost works.
330 lines
10 KiB
C++
330 lines
10 KiB
C++
#pragma once
|
|
|
|
#include <memory>
|
|
#include <vector>
|
|
|
|
#include "cfg/option.h"
|
|
|
|
namespace launcher {
|
|
|
|
// options list - order matters
|
|
namespace Options {
|
|
enum {
|
|
GameExecutable,
|
|
OpenConfigurator,
|
|
OpenKFControl,
|
|
EAmusementEmulation,
|
|
ServiceURL,
|
|
PCBID,
|
|
Player1Card,
|
|
Player2Card,
|
|
Player1PinMacro,
|
|
Player2PinMacro,
|
|
AutoPinMacroTrigger0,
|
|
AutoPinMacroTrigger1,
|
|
WindowedMode,
|
|
InjectHook,
|
|
EarlyInjectHook,
|
|
ExecuteScript,
|
|
CaptureCursor,
|
|
ShowCursor,
|
|
PrimaryMonitor,
|
|
DXDisplayAdapter,
|
|
GraphicsForceSingleAdapter,
|
|
GraphicsForceRefresh,
|
|
FullscreenResolution,
|
|
FullscreenOrientationFlip,
|
|
FullscreenSubResolution,
|
|
FullscreenSubRefreshRate,
|
|
Graphics9On12,
|
|
spice2x_Dx9On12,
|
|
NoLegacy,
|
|
RichPresence,
|
|
SmartEAmusement,
|
|
EAmusementMaintenance,
|
|
spice2x_EAmusementMaintenance,
|
|
AdapterNetwork,
|
|
AdapterSubnet,
|
|
DisableNetworkFixes,
|
|
HTTP11,
|
|
DisableSSL,
|
|
URLSlash,
|
|
SOFTID,
|
|
VREnable,
|
|
DisableOverlay,
|
|
OverlayScaling,
|
|
NotificationPosition,
|
|
spice2x_FpsAutoShow,
|
|
spice2x_FpsOpposite,
|
|
spice2x_SubScreenAutoShow,
|
|
spice2x_IOPanelAutoShow,
|
|
spice2x_KeypadAutoShow,
|
|
LoadIIDXModule,
|
|
IIDXCameraOrderFlip,
|
|
IIDXDisableCameras,
|
|
IIDXCabCamAccess,
|
|
IIDXCamHook,
|
|
IIDXCamHookRatio,
|
|
IIDXCamHookOverride,
|
|
IIDXCamHookTopId,
|
|
IIDXCamHookFrontId,
|
|
IIDXSoundOutputDevice,
|
|
IIDXAsioDriver,
|
|
IIDXBIO2FW,
|
|
IIDXTDJMode,
|
|
spice2x_IIDXDigitalTTSensitivity,
|
|
IIDXDigitalTTSocd,
|
|
spice2x_IIDXLDJForce720p,
|
|
spice2x_IIDXTDJSubSize,
|
|
spice2x_IIDXLEDFontSize,
|
|
spice2x_IIDXLEDColor,
|
|
spice2x_IIDXLEDPos,
|
|
IIDXLEDBorderless,
|
|
LoadSoundVoltexModule,
|
|
SDVXForce720p,
|
|
SDVXPrinterEmulation,
|
|
SDVXPrinterOutputPath,
|
|
SDVXPrinterOutputClear,
|
|
SDVXPrinterOutputOverwrite,
|
|
SDVXPrinterOutputFormat,
|
|
SDVXPrinterJPGQuality,
|
|
SDVXDisableCameras,
|
|
SDVXNativeTouch,
|
|
spice2x_SDVXSubRedraw,
|
|
spice2x_SDVXDigitalKnobSensitivity,
|
|
SDVXDigitalKnobSocd,
|
|
spice2x_SDVXAsioDriver,
|
|
spice2x_SDVXSubPos,
|
|
SDVXSubMonitorOverride,
|
|
LoadDDRModule,
|
|
DDR43Mode,
|
|
DDRSkipCodecRegisteration,
|
|
LoadPopnMusicModule,
|
|
PopnMusicForceHDMode,
|
|
PopnMusicForceSDMode,
|
|
PopnNoSub,
|
|
PopnSubMonitorOverride,
|
|
PopnNativeTouch,
|
|
LoadHelloPopnMusicModule,
|
|
LoadGitaDoraModule,
|
|
GitaDoraTwoChannelAudio,
|
|
GitaDoraCabinetType,
|
|
GitaDoraLefty,
|
|
GitaDoraWailHold,
|
|
GitaDoraPickAlgo,
|
|
GitaDoraSubOverlaySize,
|
|
GitaDoraArenaSingleWindow,
|
|
GitaDoraArenaWindowLayout,
|
|
GitaDoraArenaAsioDriver,
|
|
LoadJubeatModule,
|
|
LoadReflecBeatModule,
|
|
LoadShogikaiModule,
|
|
LoadBeatstreamModule,
|
|
LoadNostalgiaModule,
|
|
LoadDanceEvolutionModule,
|
|
LoadFutureTomTomModule,
|
|
LoadBBCModule,
|
|
LoadMetalGearArcadeModule,
|
|
LoadQuizMagicAcademyModule,
|
|
LoadRoadFighters3DModule,
|
|
LoadSteelChronicleModule,
|
|
LoadMahjongFightClubModule,
|
|
LoadScottoModule,
|
|
LoadDanceRushModule,
|
|
LoadWinningElevenModule,
|
|
LoadOtocaModule,
|
|
LoadLovePlusModule,
|
|
LoadChargeMachineModule,
|
|
LoadOngakuParadiseModule,
|
|
LoadBusouShinkiModule,
|
|
LoadCCJModule,
|
|
LoadQKSModule,
|
|
LoadMFGModule,
|
|
LoadPCModule,
|
|
LoadMusecaModule,
|
|
PathToModules,
|
|
ScreenshotFolder,
|
|
ConfigurationPath,
|
|
ScreenResizeConfigPath,
|
|
PatchManagerConfigPath,
|
|
IntelSDEFolder,
|
|
PathToEa3Config,
|
|
PathToAppConfig,
|
|
PathToAvsConfig,
|
|
PathToBootstrap,
|
|
PathToLog,
|
|
APITCPPort,
|
|
APIPassword,
|
|
APIVerboseLogging,
|
|
APISerialPort,
|
|
APISerialBaud,
|
|
APIPretty,
|
|
APIDebugMode,
|
|
APIScreenMirrorQuality,
|
|
APIScreenMirrorDivide,
|
|
EnableAllIOModules,
|
|
EnableACIOModule,
|
|
EnableICCAModule,
|
|
EnableDEVICEModule,
|
|
EnableEXTDEVModule,
|
|
EnableAMI2000Module,
|
|
EnableSCIUNITModule,
|
|
EnableDevicePassthrough,
|
|
ForceWinTouch,
|
|
ForceTouchEmulation,
|
|
InvertTouchCoordinates,
|
|
DisableTouchCardInsert,
|
|
spice2x_TouchCardInsert,
|
|
ICCAReaderPort,
|
|
ICCAReaderPortToggle,
|
|
CardIOHIDReaderSupport,
|
|
CardIOHIDReaderOrderFlip,
|
|
CardIOHIDReaderOrderToggle,
|
|
HIDSmartCard,
|
|
HIDSmartCardOrderFlip,
|
|
HIDSmartCardOrderToggle,
|
|
HIDSmartCardIdConvert,
|
|
SextetStreamPort,
|
|
EnableBemaniTools5API,
|
|
RealtimeProcessPriority,
|
|
spice2x_ProcessPriority,
|
|
spice2x_ProcessAffinity,
|
|
spice2x_ProcessorEfficiencyClass,
|
|
HeapSize,
|
|
DisableGSyncDetection,
|
|
spice2x_NvapiProfile,
|
|
DisableAudioHooks,
|
|
spice2x_DisableVolumeHook,
|
|
AudioBackend,
|
|
AsioDriverId,
|
|
AsioDriverName,
|
|
AudioDummy,
|
|
DownmixAudioToStereo,
|
|
VolumeBoost,
|
|
DelayBy5Seconds,
|
|
spice2x_DelayByNSeconds,
|
|
LoadStubs,
|
|
AdjustOrientation,
|
|
spice2x_AutoOrientation,
|
|
ChangeResolution,
|
|
LogLevel,
|
|
EAAutomap,
|
|
EANetdump,
|
|
DiscordAppID,
|
|
BlockingLogger,
|
|
DebugCreateFile,
|
|
VerboseGraphicsLogging,
|
|
VerboseAVSLogging,
|
|
AllowEA3Verbose,
|
|
DisableColoredOutput,
|
|
DisableACPHook,
|
|
DisableSignalHandling,
|
|
DisableDebugHooks,
|
|
DisableAvsVfsDriveMountRedirection,
|
|
DisableAvsCache,
|
|
OutputPEB,
|
|
DumpSystemInfo,
|
|
QKSArgs,
|
|
CCJArgs,
|
|
CCJMouseTrackball,
|
|
CCJMouseTrackballWithToggle,
|
|
CCJTrackballSensitivity,
|
|
MFGArgs,
|
|
MFGCabType,
|
|
MFGNoIO,
|
|
PCArgs,
|
|
PCNoIO,
|
|
PCKnobMode,
|
|
spice2x_LightsOverallBrightness,
|
|
spice2x_WindowBorder,
|
|
spice2x_WindowSize,
|
|
spice2x_WindowPosition,
|
|
spice2x_WindowAlwaysOnTop,
|
|
WindowForceScaling,
|
|
WindowDisableRoundedCorners,
|
|
GitaDoraWindowedMainMonitor,
|
|
GitaDoraWindowedLeftMonitor,
|
|
GitaDoraWindowedRightMonitor,
|
|
GitaDoraWindowedSmallMonitor,
|
|
spice2x_IIDXWindowedSubscreenSize,
|
|
spice2x_IIDXWindowedSubscreenPosition,
|
|
IIDXWindowedSubscreenBorderless,
|
|
IIDXWindowedSubscreenAlwaysOnTop,
|
|
spice2x_JubeatLegacyTouch,
|
|
JubeatTouchAlgo,
|
|
spice2x_RBTouchScale,
|
|
RBTouchSize,
|
|
RBTouchPollRate,
|
|
spice2x_AsioForceUnload,
|
|
spice2x_IIDXNoESpec,
|
|
spice2x_IIDXWindowedTDJ,
|
|
spice2x_DRSDisableTouch,
|
|
spice2x_DRSTransposeTouch,
|
|
DRSRGBCameraHook,
|
|
spice2x_IIDXNativeTouch,
|
|
spice2x_IIDXNoSub,
|
|
IIDXSubMonitorOverride,
|
|
spice2x_IIDXEmulateSubscreenKeypadTouch,
|
|
spice2x_AutoCard,
|
|
spice2x_LowLatencySharedAudio,
|
|
spice2x_TapeLedAlgorithm,
|
|
spice2x_NoNVAPI,
|
|
spice2x_NoD3D9DeviceHook,
|
|
spice2x_SDVXNoSub,
|
|
SDVXFullscreenLandscape,
|
|
spice2x_EnableSMXStage,
|
|
spice2x_EnableSMXDedicab,
|
|
IIDXRecQuality,
|
|
IIDXRecDisable,
|
|
MidiAlgoVer,
|
|
MidiNoteSustain,
|
|
DDRP4IOBufferMode,
|
|
InputRequiresFocus,
|
|
NostalgiaPoke,
|
|
ForceBackBufferCount,
|
|
SDVXWindowedSubscreenSize,
|
|
SDVXWindowedSubscreenPosition,
|
|
SDVXWindowedSubscreenBorderless,
|
|
SDVXWindowedSubscreenAlwaysOnTop,
|
|
LovePlusCamEnable,
|
|
LovePlusPrinterOutputPath,
|
|
LovePlusPrinterOutputClear,
|
|
LovePlusPrinterOutputOverwrite,
|
|
LovePlusPrinterOutputFormat,
|
|
LovePlusPrinterJPGQuality,
|
|
OptionConflictResolution,
|
|
OtocaCamHook,
|
|
DisableHighResTimer,
|
|
EnableICMPHook,
|
|
AutoElevate,
|
|
CfgForceSoftwareRender
|
|
};
|
|
|
|
enum class OptionsCategory {
|
|
Everything,
|
|
Basic,
|
|
Advanced,
|
|
Dev,
|
|
API
|
|
};
|
|
}
|
|
|
|
extern bool USE_CMD_OVERRIDE;
|
|
|
|
const std::vector<std::string> &get_categories(Options::OptionsCategory category);
|
|
const std::vector<OptionDefinition> &get_option_definitions();
|
|
std::unique_ptr<std::vector<Option>> parse_options(int argc, char *argv[]);
|
|
std::vector<Option> merge_options(const std::vector<Option> &options, const std::vector<Option> &overrides);
|
|
|
|
struct GameVersion {
|
|
std::string model;
|
|
std::string dest;
|
|
std::string spec;
|
|
std::string rev;
|
|
std::string ext;
|
|
};
|
|
|
|
std::string detect_bootstrap_release_code(const std::string& bootstrap_user);
|
|
GameVersion detect_gameversion(const std::string& ea3_user, const std::string& bootstrap_user);
|
|
}
|