TeslasuitDocumentation
APIs

Assets

Interfaces#

IAsset#

TsSDK::IAsset

Provides Asset base object to manipulate with.

Properties

Handle — IntPtr (read-only)

Native handle of the loaded asset.

AssetType — TsAssetType (read-only)

Loaded asset type.


IAssetManager#

TsSDK::IAssetManager

Asset manager provides functionality to load assets from a file on the disk or from a binary array of data, to get information about a loaded asset and to unload an asset from memory.

Methods

Load#

IAsset Load(byte[] bytes);

Loads an asset from byte array.

Parameters

bytes: byte[]

Asset bytes

Returns: IAsset


Load#

IAsset Load(string path);

Loads an asset by path.

Parameters

path: string

Asset path

Returns: IAsset


Unload#

void Unload(IAsset asset);

Unloads an asset from memory.

Parameters

asset: IAsset

Asset object


GetAsset#

IAsset GetAsset(IntPtr handle);

Gets an asset interface object by native handle.

Parameters

handle: IntPtr

Native handle of asset

Returns: IAsset


CreateMaterialAsset#

IHapticAsset CreateMaterialAsset(IHapticAsset touchSequenceAsset, IHapticAsset effectAsset);

Creates haptic material asset.

Parameters

touchSequenceAsset: IHapticAsset

Handle to the touch sequence asset

effectAsset: IHapticAsset

Handle to the effect asset

Returns: IHapticAsset

IHapticAsset Material asset handle



IHapticAsset#

TsSDK::IHapticAsset

Haptic asset object that can be used to create playable from with IHapticPlayer.


IHapticPlayableManager#

TsSDK::IHapticPlayableManager

Provides cross-device access to device-related IHapticPlayable objects by given IHapticAsset

Due to various electrodes mapping versions between the devices, some haptic assets that addressing the electric channels should be converted to target device channel mapping. Therefore HapticPlayableManager incapsulates the IHapticPlayable access logic for a specific device.

Methods

GetPlayable#

IHapticPlayable GetPlayable(IDevice device, IHapticAsset asset);

Gets IHapticPlayable by given haptic asset and device

Parameters

device: IDevice

Device to get playable from

asset: IHapticAsset

Asset from which the playable created

Returns: IHapticPlayable



Enumerations#

TsAssetType#

Asset types.

Members

Undefined 0 Spline 1 HapticEffect 2 Material 3 TouchSequence 4 PresetAnimation 5 SceneAnimation 6 SceneDataCapture 7 AvatarDataCapture 8 SubsystemsDataCapture 9 SubsystemDataCapture 10 DataCapture 11 SkeletonMocapDataCapture 12 RawMocapDataCapture 13 SceneConfig 14 RawEmgDataCapture 15 EmgSpectrogramDataCapture 16 EmgArtifactsData 17 EmgActivityData 18 HeartRate 19 PpgDataCapture 20 RawPpgDataCapture 21 RawTemperatureDataCapture 22 RawBiaDataCapture 23 DataMarkup 24 DataMarkupTrack 25