mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-08-01 22:30:42 -07:00
nost: touch piano mode (#830)
## Link to GitHub Issue or related Pull Request, if one exists n/a ## Description of change Touch piano mode. Allows piano keys to be played with the touch screen. Since the touch screen is still needed for menu navigation (including during songs) a toggle switch is added so that the user can flip between navigation mode and piano mode. The touch targets are pixel-perfect. Don't let the game's piano animations fool you. ## Testing
This commit is contained in:
@@ -1,8 +1,23 @@
|
||||
#pragma once
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
namespace nativetouch {
|
||||
struct NativeTouchEvent {
|
||||
DWORD id;
|
||||
LONG x;
|
||||
LONG y;
|
||||
bool down;
|
||||
bool move;
|
||||
bool up;
|
||||
bool synthetic;
|
||||
};
|
||||
|
||||
using TouchInputFilter = bool (*)(const NativeTouchEvent &event);
|
||||
|
||||
void hook(HMODULE module);
|
||||
void refresh_contact_lifetime();
|
||||
void set_input_filter(TouchInputFilter filter);
|
||||
|
||||
// true once hook() has installed the native touch stack for the current game;
|
||||
// such games consume touch through the GetTouchInputInfo hook rather than spicetouch
|
||||
|
||||
Reference in New Issue
Block a user