![]() |
![]() |
![]() |
GNOME Color Manager Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy | Properties |
#define GCM_USB_ERROR enum GcmUsbError; struct GcmUsb; struct GcmUsbClass; gboolean gcm_usb_load (GcmUsb *usb
,GError **error
); gboolean gcm_usb_connect (GcmUsb *usb
,guint vendor_id
,guint product_id
,guint configuration
,guint interface
,GError **error
); gboolean gcm_usb_get_connected (GcmUsb *usb
); void gcm_usb_attach_to_context (GcmUsb *usb
,GMainContext *context
); libusb_device_handle * gcm_usb_get_device_handle (GcmUsb *usb
); GcmUsb * gcm_usb_new (void
); GcmUsbPrivate;
gboolean gcm_usb_load (GcmUsb *usb
,GError **error
);
Connects to libusb. You normally don't have to call this method manually.
Since 2.91.1
gboolean gcm_usb_connect (GcmUsb *usb
,guint vendor_id
,guint product_id
,guint configuration
,guint interface
,GError **error
);
Connects to a specific device.
|
a GcmUsb instance |
|
the vendor ID to connect to |
|
the product ID to connect to |
|
the configuration index to use, usually '1' |
|
the configuration interface to use, usually '0' |
|
a GError, or NULL
|
Returns : |
TRUE for success |
Since 2.91.1
void gcm_usb_attach_to_context (GcmUsb *usb
,GMainContext *context
);
Connects up usb-1 with the GLib event loop. This functionality allows you to submit async requests using usb, and the callbacks just kinda happen at the right time.
Since 2.91.1
libusb_device_handle * gcm_usb_get_device_handle (GcmUsb *usb
);
Gets the low-level device handle
Since 2.91.1