createDevice() function
The main entry point to @rnbo/js. Use this createDevice factory function to create Devices from your RNBO Patches. Refer to the guide on Loading a RNBO Device in the Browser for more details on how to use this function.
Signature
export declare function createDevice(parameters: ICreateDeviceParameters, prevDevice?: Device): Promise<Device>;
Parameters
Parameter | Type | Description |
---|---|---|
parameters | ICreateDeviceParameters | The parameters used in creating a new RNBO Device (see ICreateDeviceParameters) |
prevDevice | Device | Optional previous device. Use this parameter to create a device from an existing one including state restoration. CAUTION: This makes the previous device invalid and therefore non-functional. This functionality is only useful for specific, advanced use-cases. |
Returns:
Promise<Device>
a Promise returning the created Device