Exemplo n.º 1
0
 private void IntrinsicDataHandler(IntPtr handle)
 {
     if (OnIntrinsicData != null)
     {
         VLIntrinsicDataWrapper intrinsicData =
             new VLIntrinsicDataWrapper(handle, false);
         OnIntrinsicData(intrinsicData);
         intrinsicData.Dispose();
     }
 }
Exemplo n.º 2
0
 private static void DispatchNamedIntrinsicDataEvent(IntPtr handle,
                                                     IntPtr clientData)
 {
     try
     {
         VLIntrinsicDataWrapper intrinsicData = new VLIntrinsicDataWrapper(
             handle, false);
         GCHandle gcHandle = GCHandle.FromIntPtr(clientData);
         VLDebugCameraBehaviour debugCameraBehaviour =
             (VLDebugCameraBehaviour)gcHandle.Target;
         debugCameraBehaviour.OnIntrinsicData(intrinsicData);
         intrinsicData.Dispose();
     }
     catch (Exception e) // Catch all exceptions, because this is a callback
                         // invoked from native code
     {
         Debug.LogError("[vlUnitySDK] " + e.GetType().Name + ": " +
                        e.Message);
     }
 }