From a778d878ff3648c6c6fb399dfc9513741305e5d2 Mon Sep 17 00:00:00 2001 From: Sebastien Ronsse Date: Wed, 27 Jul 2016 20:14:43 +1000 Subject: [PATCH] net retropad core: Add analog device processing --- cores/libretro-net-retropad/net_retropad_core.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/cores/libretro-net-retropad/net_retropad_core.c b/cores/libretro-net-retropad/net_retropad_core.c index 72fa2400af..09b06c0524 100644 --- a/cores/libretro-net-retropad/net_retropad_core.c +++ b/cores/libretro-net-retropad/net_retropad_core.c @@ -94,8 +94,19 @@ static struct descriptor joypad = { .id_max = RETRO_DEVICE_ID_JOYPAD_R3 }; +static struct descriptor analog = { + .device = RETRO_DEVICE_ANALOG, + .port_min = 0, + .port_max = 0, + .index_min = RETRO_DEVICE_INDEX_ANALOG_LEFT, + .index_max = RETRO_DEVICE_INDEX_ANALOG_RIGHT, + .id_min = RETRO_DEVICE_ID_ANALOG_X, + .id_max = RETRO_DEVICE_ID_ANALOG_Y +}; + static struct descriptor *descriptors[] = { - &joypad + &joypad, + &analog }; void NETRETROPAD_CORE_PREFIX(retro_init)(void)