early-access version 2201
This commit is contained in:
@@ -73,6 +73,7 @@ add_library(common STATIC
|
||||
hex_util.h
|
||||
host_memory.cpp
|
||||
host_memory.h
|
||||
input.h
|
||||
intrusive_red_black_tree.h
|
||||
literals.h
|
||||
logging/backend.cpp
|
||||
|
@@ -6,7 +6,6 @@
|
||||
|
||||
#include <algorithm>
|
||||
#include <array>
|
||||
#include <atomic>
|
||||
#include <map>
|
||||
#include <optional>
|
||||
#include <string>
|
||||
@@ -560,25 +559,18 @@ struct Values {
|
||||
Setting<bool> enable_accurate_vibrations{false, "enable_accurate_vibrations"};
|
||||
|
||||
Setting<bool> motion_enabled{true, "motion_enabled"};
|
||||
BasicSetting<std::string> motion_device{"engine:motion_emu,update_period:100,sensitivity:0.01",
|
||||
"motion_device"};
|
||||
BasicSetting<std::string> udp_input_servers{"127.0.0.1:26760", "udp_input_servers"};
|
||||
|
||||
BasicSetting<bool> pause_tas_on_load{true, "pause_tas_on_load"};
|
||||
BasicSetting<bool> tas_enable{false, "tas_enable"};
|
||||
BasicSetting<bool> tas_loop{false, "tas_loop"};
|
||||
BasicSetting<bool> tas_swap_controllers{true, "tas_swap_controllers"};
|
||||
|
||||
BasicSetting<bool> mouse_panning{false, "mouse_panning"};
|
||||
BasicRangedSetting<u8> mouse_panning_sensitivity{10, 1, 100, "mouse_panning_sensitivity"};
|
||||
BasicSetting<bool> mouse_enabled{false, "mouse_enabled"};
|
||||
std::string mouse_device;
|
||||
MouseButtonsRaw mouse_buttons;
|
||||
|
||||
BasicSetting<bool> emulate_analog_keyboard{false, "emulate_analog_keyboard"};
|
||||
BasicSetting<bool> keyboard_enabled{false, "keyboard_enabled"};
|
||||
KeyboardKeysRaw keyboard_keys;
|
||||
KeyboardModsRaw keyboard_mods;
|
||||
|
||||
BasicSetting<bool> debug_pad_enabled{false, "debug_pad_enabled"};
|
||||
ButtonsRaw debug_pad_buttons;
|
||||
@@ -586,14 +578,11 @@ struct Values {
|
||||
|
||||
TouchscreenInput touchscreen;
|
||||
|
||||
BasicSetting<bool> use_touch_from_button{false, "use_touch_from_button"};
|
||||
BasicSetting<std::string> touch_device{"min_x:100,min_y:50,max_x:1800,max_y:850",
|
||||
"touch_device"};
|
||||
BasicSetting<int> touch_from_button_map_index{0, "touch_from_button_map"};
|
||||
std::vector<TouchFromButtonMap> touch_from_button_maps;
|
||||
|
||||
std::atomic_bool is_device_reload_pending{true};
|
||||
|
||||
// Data Storage
|
||||
BasicSetting<bool> use_virtual_sd{true, "use_virtual_sd"};
|
||||
BasicSetting<bool> gamecard_inserted{false, "gamecard_inserted"};
|
||||
|
@@ -62,11 +62,22 @@ enum Values : int {
|
||||
|
||||
constexpr int STICK_HID_BEGIN = LStick;
|
||||
constexpr int STICK_HID_END = NumAnalogs;
|
||||
constexpr int NUM_STICKS_HID = NumAnalogs;
|
||||
|
||||
extern const std::array<const char*, NumAnalogs> mapping;
|
||||
} // namespace NativeAnalog
|
||||
|
||||
namespace NativeTrigger {
|
||||
enum Values : int {
|
||||
LTrigger,
|
||||
RTrigger,
|
||||
|
||||
NumTriggers,
|
||||
};
|
||||
|
||||
constexpr int TRIGGER_HID_BEGIN = LTrigger;
|
||||
constexpr int TRIGGER_HID_END = NumTriggers;
|
||||
} // namespace NativeTrigger
|
||||
|
||||
namespace NativeVibration {
|
||||
enum Values : int {
|
||||
LeftVibrationDevice,
|
||||
@@ -115,10 +126,20 @@ constexpr int NUM_MOUSE_HID = NumMouseButtons;
|
||||
extern const std::array<const char*, NumMouseButtons> mapping;
|
||||
} // namespace NativeMouseButton
|
||||
|
||||
namespace NativeMouseWheel {
|
||||
enum Values {
|
||||
X,
|
||||
Y,
|
||||
|
||||
NumMouseWheels,
|
||||
};
|
||||
|
||||
extern const std::array<const char*, NumMouseWheels> mapping;
|
||||
} // namespace NativeMouseWheel
|
||||
|
||||
namespace NativeKeyboard {
|
||||
enum Keys {
|
||||
None,
|
||||
Error,
|
||||
|
||||
A = 4,
|
||||
B,
|
||||
@@ -156,22 +177,22 @@ enum Keys {
|
||||
N8,
|
||||
N9,
|
||||
N0,
|
||||
Enter,
|
||||
Return,
|
||||
Escape,
|
||||
Backspace,
|
||||
Tab,
|
||||
Space,
|
||||
Minus,
|
||||
Equal,
|
||||
LeftBrace,
|
||||
RightBrace,
|
||||
Backslash,
|
||||
Plus,
|
||||
OpenBracket,
|
||||
CloseBracket,
|
||||
Pipe,
|
||||
Tilde,
|
||||
Semicolon,
|
||||
Apostrophe,
|
||||
Grave,
|
||||
Quote,
|
||||
Backquote,
|
||||
Comma,
|
||||
Dot,
|
||||
Period,
|
||||
Slash,
|
||||
CapsLockKey,
|
||||
|
||||
@@ -188,7 +209,7 @@ enum Keys {
|
||||
F11,
|
||||
F12,
|
||||
|
||||
SystemRequest,
|
||||
PrintScreen,
|
||||
ScrollLockKey,
|
||||
Pause,
|
||||
Insert,
|
||||
@@ -257,8 +278,18 @@ enum Keys {
|
||||
ScrollLockActive,
|
||||
KPComma,
|
||||
|
||||
KPLeftParenthesis,
|
||||
KPRightParenthesis,
|
||||
Ro = 0x87,
|
||||
KatakanaHiragana,
|
||||
Yen,
|
||||
Henkan,
|
||||
Muhenkan,
|
||||
NumPadCommaPc98,
|
||||
|
||||
HangulEnglish = 0x90,
|
||||
Hanja,
|
||||
KatakanaKey,
|
||||
HiraganaKey,
|
||||
ZenkakuHankaku,
|
||||
|
||||
LeftControlKey = 0xE0,
|
||||
LeftShiftKey,
|
||||
@@ -307,6 +338,8 @@ enum Modifiers {
|
||||
CapsLock,
|
||||
ScrollLock,
|
||||
NumLock,
|
||||
Katakana,
|
||||
Hiragana,
|
||||
|
||||
NumKeyboardMods,
|
||||
};
|
||||
@@ -326,10 +359,6 @@ using ButtonsRaw = std::array<std::string, NativeButton::NumButtons>;
|
||||
using MotionsRaw = std::array<std::string, NativeMotion::NumMotions>;
|
||||
using VibrationsRaw = std::array<std::string, NativeVibration::NumVibrations>;
|
||||
|
||||
using MouseButtonsRaw = std::array<std::string, NativeMouseButton::NumMouseButtons>;
|
||||
using KeyboardKeysRaw = std::array<std::string, NativeKeyboard::NumKeyboardKeys>;
|
||||
using KeyboardModsRaw = std::array<std::string, NativeKeyboard::NumKeyboardMods>;
|
||||
|
||||
constexpr u32 JOYCON_BODY_NEON_RED = 0xFF3C28;
|
||||
constexpr u32 JOYCON_BUTTONS_NEON_RED = 0x1E0A0A;
|
||||
constexpr u32 JOYCON_BODY_NEON_BLUE = 0x0AB9E6;
|
||||
|
Reference in New Issue
Block a user