public class OpenNIHelper
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
OpenNIHelper.DeviceOpenListener
Used for receiving the result of
requestDeviceOpen(String uri, DeviceOpenListener listener) . |
Constructor and Description |
---|
OpenNIHelper(Context context)
Constructs an OpenNIHelper object.
|
Modifier and Type | Method and Description |
---|---|
UsbDevice |
getUsbDevice(DeviceInfo deviceInfo) |
UsbDevice |
getUsbDevice(java.lang.String uri) |
void |
requestDeviceOpen(java.lang.String uri,
OpenNIHelper.DeviceOpenListener listener)
Requests opening the specified device.
|
void |
shutdown()
Releases the resources used by the helper.
|
public OpenNIHelper(Context context)
assets/openni
,
to make them accessible to OpenNI.context
- a Context object used to access application assets.public void requestDeviceOpen(java.lang.String uri, OpenNIHelper.DeviceOpenListener listener)
OpenNIHelper.DeviceOpenListener
interface.
If successful, this grants the caller permission to access the device only until the device is
disconnected.uri
- device to openlistener
- a listener to be notified about the result.public UsbDevice getUsbDevice(java.lang.String uri)
public UsbDevice getUsbDevice(DeviceInfo deviceInfo)
public void shutdown()