void DoProcess() { if (!(owner.Value is OpenCVForUnityPlayMakerActions.MatOfDouble)) { LogError("owner is not initialized. Add Action \"newMatOfDouble\"."); return; } OpenCVForUnity.CoreModule.MatOfDouble wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.MatOfDouble, OpenCVForUnity.CoreModule.MatOfDouble>(owner); List <System.Double> wrapped_lb = new List <System.Double>(); OpenCVForUnityPlayMakerActionsUtils.ConvertFsmArrayToList <OpenCVForUnityPlayMakerActions.Double, System.Double>(lb, wrapped_lb); wrapped_owner.fromList(wrapped_lb); OpenCVForUnityPlayMakerActionsUtils.ConvertListToFsmArray <System.Double, OpenCVForUnityPlayMakerActions.Double>(wrapped_lb, lb); }
void DoProcess() { if (!(owner.Value is OpenCVForUnityPlayMakerActions.MatOfDouble)) { LogError("owner is not initialized. Add Action \"newMatOfDouble\"."); return; } OpenCVForUnity.CoreModule.MatOfDouble wrapped_owner = OpenCVForUnityPlayMakerActionsUtils.GetWrappedObject <OpenCVForUnityPlayMakerActions.MatOfDouble, OpenCVForUnity.CoreModule.MatOfDouble>(owner); float[] float_lb = lb.floatValues; double[] casted_lb = new double[float_lb.Length]; float_lb.CopyTo(casted_lb, 0); List <double> wrapped_lb = new List <double>(casted_lb); wrapped_owner.fromList(wrapped_lb); for (int i = 0; i < wrapped_lb.Count; i++) { lb.Set(i, (float)wrapped_lb[i]); } lb.SaveChanges(); }