VuoOscDevices implementation.
Definition in file VuoOscDevices.cc.
Go to the source code of this file.
Macros | |
#define | setRealizedDevice(newDevice) |
Helper for VuoOscInputDevice_realize. More... | |
Functions | |
VuoList_VuoOscInputDevice | VuoOsc_getInputDeviceList (void) |
Returns a list of the currently-avaialble OSC input devices. More... | |
VuoList_VuoOscOutputDevice | VuoOsc_getOutputDeviceList (void) |
Returns a list of the currently-avaialble OSC output devices. More... | |
void | VuoOsc_clientCallback (CFNetServiceRef service, CFStreamError *error, void *info) |
Called when service details have been resolved. More... | |
void | VuoOsc_deviceCallback (CFNetServiceBrowserRef browser, CFOptionFlags flags, CFTypeRef domainOrService, CFStreamError *error, void *info) |
Called when a new domain or service appears. More... | |
void | VuoOsc_use (void) |
Indicates that the caller needs to get notifications about OSC devices. More... | |
void | VuoOsc_disuse (void) |
Indicates that the caller no longer needs notifications about OSC devices. More... | |
void | VuoOsc_addDevicesChangedTriggers (VuoOutputTrigger(inputDevices, VuoList_VuoOscInputDevice), VuoOutputTrigger(outputDevices, VuoList_VuoOscOutputDevice)) |
Adds a trigger callback, to be invoked whenever the list of known OSC devices changes. More... | |
void | VuoOsc_removeDevicesChangedTriggers (VuoOutputTrigger(inputDevices, VuoList_VuoOscInputDevice), VuoOutputTrigger(outputDevices, VuoList_VuoOscOutputDevice)) |
Removes a trigger callback previously added by VuoOsc_addDevicesChangedTriggers. More... | |
bool | VuoOscInputDevice_realize (VuoOscInputDevice device, VuoOscInputDevice *realizedDevice) |
If any of device 's properties are unknown: More... | |
bool | VuoOscOutputDevice_realize (VuoOscOutputDevice device, VuoOscOutputDevice *realizedDevice) |
If any of device 's properties are unknown: More... | |
Variables | |
static dispatch_queue_t | VuoOsc_deviceQueue |
Serializes access to the below device lists. More... | |
static VuoList_VuoOscInputDevice | VuoOsc_inputDevices |
All known input devices. More... | |
static VuoList_VuoOscOutputDevice | VuoOsc_outputDevices |
All known output devices. More... | |
static VuoTriggerSet< VuoList_VuoOscInputDevice > | VuoOsc_inputDeviceCallbacks |
Trigger functions to call when the list of devices changes. More... | |
static VuoTriggerSet< VuoList_VuoOscOutputDevice > | VuoOsc_outputDeviceCallbacks |
Trigger functions to call when the list of devices changes. More... | |
unsigned int | VuoOsc_useCount = 0 |
Process-wide count of callers (typically node instances) interested in notifications about OSC devices. More... | |
CFNetServiceBrowserRef | VuoOsc_browser |
Manages notifications about OSC devices. More... | |
#define setRealizedDevice | ( | newDevice | ) |
Helper for VuoOscInputDevice_realize.
Definition at line 386 of file VuoOscDevices.cc.
void VuoOsc_addDevicesChangedTriggers | ( | VuoOutputTrigger(inputDevices, VuoList_VuoOscInputDevice) | , |
VuoOutputTrigger(outputDevices, VuoList_VuoOscOutputDevice) | |||
) |
Adds a trigger callback, to be invoked whenever the list of known OSC devices changes.
Call VuoOsc_use()
before calling this.
This function may be called from any thread.
Definition at line 348 of file VuoOscDevices.cc.
void VuoOsc_clientCallback | ( | CFNetServiceRef | service, |
CFStreamError * | error, | ||
void * | info | ||
) |
Called when service details have been resolved.
Definition at line 69 of file VuoOscDevices.cc.
void VuoOsc_deviceCallback | ( | CFNetServiceBrowserRef | browser, |
CFOptionFlags | flags, | ||
CFTypeRef | domainOrService, | ||
CFStreamError * | error, | ||
void * | info | ||
) |
Called when a new domain or service appears.
Definition at line 175 of file VuoOscDevices.cc.
void VuoOsc_disuse | ( | void | ) |
Indicates that the caller no longer needs notifications about OSC devices.
This function may be called from any thread.
Definition at line 312 of file VuoOscDevices.cc.
VuoList_VuoOscInputDevice VuoOsc_getInputDeviceList | ( | void | ) |
Returns a list of the currently-avaialble OSC input devices.
Definition at line 45 of file VuoOscDevices.cc.
VuoList_VuoOscOutputDevice VuoOsc_getOutputDeviceList | ( | void | ) |
Returns a list of the currently-avaialble OSC output devices.
Definition at line 57 of file VuoOscDevices.cc.
void VuoOsc_removeDevicesChangedTriggers | ( | VuoOutputTrigger(inputDevices, VuoList_VuoOscInputDevice) | , |
VuoOutputTrigger(outputDevices, VuoList_VuoOscOutputDevice) | |||
) |
Removes a trigger callback previously added by VuoOsc_addDevicesChangedTriggers.
This function may be called from any thread.
Definition at line 371 of file VuoOscDevices.cc.
void VuoOsc_use | ( | void | ) |
Indicates that the caller needs to get notifications about OSC devices.
This function may be called from any thread.
Definition at line 270 of file VuoOscDevices.cc.
bool VuoOscInputDevice_realize | ( | VuoOscInputDevice | device, |
VuoOscInputDevice * | realizedDevice | ||
) |
If any of device
's properties are unknown:
realizedDevice
to that device, and returns true.realizedDevice
unset.If all of device
's properties are already known, sets realizedDevice
to a copy of device
, and returns true. (Doesn't bother checking whether the device is currently present.)
Call VuoOsc_use()
before calling this.
This function may be called from any thread.
Definition at line 403 of file VuoOscDevices.cc.
bool VuoOscOutputDevice_realize | ( | VuoOscOutputDevice | device, |
VuoOscOutputDevice * | realizedDevice | ||
) |
If any of device
's properties are unknown:
realizedDevice
to that device, and returns true.realizedDevice
unset.If all of device
's properties are already known, sets realizedDevice
to a copy of device
, and returns true. (Doesn't bother checking whether the device is currently present.)
Call VuoOsc_use()
before calling this.
This function may be called from any thread.
Definition at line 464 of file VuoOscDevices.cc.
CFNetServiceBrowserRef VuoOsc_browser |
Manages notifications about OSC devices.
Definition at line 263 of file VuoOscDevices.cc.
|
static |
Serializes access to the below device lists.
Definition at line 36 of file VuoOscDevices.cc.
|
static |
Trigger functions to call when the list of devices changes.
Definition at line 39 of file VuoOscDevices.cc.
|
static |
All known input devices.
Definition at line 37 of file VuoOscDevices.cc.
|
static |
Trigger functions to call when the list of devices changes.
Definition at line 40 of file VuoOscDevices.cc.
|
static |
All known output devices.
Definition at line 38 of file VuoOscDevices.cc.
unsigned int VuoOsc_useCount = 0 |
Process-wide count of callers (typically node instances) interested in notifications about OSC devices.
Definition at line 262 of file VuoOscDevices.cc.