Track Finger IDs on Switch

This commit is contained in:
Florian Märkl 2021-01-12 12:23:02 +01:00
commit fc58e83e9c
No known key found for this signature in database
GPG key ID: 125BC8A5A6A1E857
5 changed files with 46 additions and 34 deletions

View file

@ -35,6 +35,8 @@ Reproducible: False
#endif
#include <mutex>
#include <map>
extern "C"
{
#include <libavcodec/avcodec.h>
@ -96,7 +98,7 @@ class IO
GLuint CreateAndCompileShader(GLenum type, const char *source);
void SetOpenGlYUVPixels(AVFrame *frame);
bool ReadGameKeys(SDL_Event *event, ChiakiControllerState *state);
bool ReadGameTouchScreen(ChiakiControllerState *state);
bool ReadGameTouchScreen(ChiakiControllerState *state, std::map<uint32_t, int8_t> *finger_id_touch_id);
bool ReadGameSixAxis(ChiakiControllerState *state);
public:
// singleton configuration
@ -114,7 +116,7 @@ class IO
bool InitController();
bool FreeController();
bool MainLoop();
void UpdateControllerState(ChiakiControllerState *state);
void UpdateControllerState(ChiakiControllerState *state, std::map<uint32_t, int8_t> *finger_id_touch_id);
void SetRumble(uint8_t left, uint8_t right);
};