mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-07 07:14:56 +01:00
add required request buffer factory for Wiimote
This commit is contained in:
parent
0d9efc1148
commit
e2f6c59639
3 changed files with 22 additions and 1 deletions
|
|
@ -48,6 +48,12 @@ probe_wiimote_protocol (ControlProtocolDescriptor*)
|
||||||
{
|
{
|
||||||
return WiimoteControlProtocol::probe ();
|
return WiimoteControlProtocol::probe ();
|
||||||
}
|
}
|
||||||
|
static void*
|
||||||
|
wiimote_request_buffer_factory (uint32_t num_requests)
|
||||||
|
{
|
||||||
|
return WiimoteControlProtocol::request_factory (num_requests);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static ControlProtocolDescriptor wiimote_descriptor = {
|
static ControlProtocolDescriptor wiimote_descriptor = {
|
||||||
name : "Wiimote",
|
name : "Wiimote",
|
||||||
|
|
@ -58,7 +64,8 @@ static ControlProtocolDescriptor wiimote_descriptor = {
|
||||||
supports_feedback : false,
|
supports_feedback : false,
|
||||||
probe : probe_wiimote_protocol,
|
probe : probe_wiimote_protocol,
|
||||||
initialize : new_wiimote_protocol,
|
initialize : new_wiimote_protocol,
|
||||||
destroy : delete_wiimote_protocol
|
destroy : delete_wiimote_protocol,
|
||||||
|
request_buffer_factory : wiimote_request_buffer_factory
|
||||||
};
|
};
|
||||||
|
|
||||||
extern "C" ARDOURSURFACE_API ControlProtocolDescriptor* protocol_descriptor () { return &wiimote_descriptor; }
|
extern "C" ARDOURSURFACE_API ControlProtocolDescriptor* protocol_descriptor () { return &wiimote_descriptor; }
|
||||||
|
|
|
||||||
|
|
@ -455,3 +455,15 @@ wiimote_control_protocol_mesg_callback (cwiid_wiimote_t *wiimote, int mesg_count
|
||||||
|
|
||||||
DEBUG_TRACE (DEBUG::WiimoteControl, "WiimoteControlProtocol::mesg_callback done\n");
|
DEBUG_TRACE (DEBUG::WiimoteControl, "WiimoteControlProtocol::mesg_callback done\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void*
|
||||||
|
WiimoteControlProtocol::request_factory (uint32_t num_requests)
|
||||||
|
{
|
||||||
|
/* AbstractUI<T>::request_buffer_factory() is a template method only
|
||||||
|
instantiated in this source module. To provide something visible for
|
||||||
|
use in the interface/descriptor, we have this static method that is
|
||||||
|
template-free.
|
||||||
|
*/
|
||||||
|
return request_buffer_factory (num_requests);
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -43,6 +43,8 @@ public:
|
||||||
virtual ~WiimoteControlProtocol ();
|
virtual ~WiimoteControlProtocol ();
|
||||||
|
|
||||||
static bool probe ();
|
static bool probe ();
|
||||||
|
static void* request_factory (uint32_t);
|
||||||
|
|
||||||
int set_active (bool yn);
|
int set_active (bool yn);
|
||||||
|
|
||||||
XMLNode& get_state ();
|
XMLNode& get_state ();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue