7 using System.Collections.Generic;
10 using System.Runtime.InteropServices;
29 internal void SetTrackingStateCPtr(ulong trackingStateCPtr)
31 cPtr = trackingStateCPtr;
34 internal ulong GetTrackingStateCPtr()
43 ulong trackingResultCPtr;
45 if (Application.platform == RuntimePlatform.IPhonePlayer)
47 trackingResultCPtr =
NativeStaticAPI.TrackingState_getTrackingResult(cPtr);
51 trackingResultCPtr =
NativeSharedAPI.TrackingState_getTrackingResult(cPtr);
54 trackingResult.SetCPtr(trackingResultCPtr);
55 return trackingResult;
62 if (Application.platform == RuntimePlatform.IPhonePlayer)
64 int length =
NativeStaticAPI.TrackingState_getCodeScanResultLength(cPtr);
67 byte[] result =
new byte[length];
69 return Encoding.UTF8.GetString(result);
78 int length =
NativeSharedAPI.TrackingState_getCodeScanResultLength(cPtr);
81 byte[] result =
new byte[length];
83 return Encoding.UTF8.GetString(result);
99 if (Application.platform == RuntimePlatform.IPhonePlayer)
108 image.SetData(Image_Cptr);
115 ulong Image_Cptr = 0;
116 if (Application.platform == RuntimePlatform.IPhonePlayer)
122 Image_Cptr = NativeSharedAPI.TrackingState_getImage(cPtr);
125 image.SetDataPtr(Image_Cptr);
TrackingResult GetTrackingResult()
Output the number of trackers that have been tracked successfully.
Container for individual tracking information
string GetCodeScanResult()
Outputs the recognition result of the bar code / QR code.
TrackedImage GetImage()
Extract image used for tracking
Contains tracked targets informations
image data which is used for tracker and rendering