HistogramPhaseUnwrapping.cs 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. 
  2. using OpenCVForUnity.CoreModule;
  3. using OpenCVForUnity.UtilsModule;
  4. using System;
  5. using System.Collections.Generic;
  6. using System.Runtime.InteropServices;
  7. namespace OpenCVForUnity.Phase_unwrappingModule
  8. {
  9. // C++: class HistogramPhaseUnwrapping
  10. //javadoc: HistogramPhaseUnwrapping
  11. public class HistogramPhaseUnwrapping : PhaseUnwrapping
  12. {
  13. protected override void Dispose (bool disposing)
  14. {
  15. #if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
  16. try {
  17. if (disposing) {
  18. }
  19. if (IsEnabledDispose) {
  20. if (nativeObj != IntPtr.Zero)
  21. phase_1unwrapping_HistogramPhaseUnwrapping_delete (nativeObj);
  22. nativeObj = IntPtr.Zero;
  23. }
  24. } finally {
  25. base.Dispose (disposing);
  26. }
  27. #else
  28. return;
  29. #endif
  30. }
  31. protected internal HistogramPhaseUnwrapping (IntPtr addr) : base (addr)
  32. {
  33. }
  34. // internal usage only
  35. public static new HistogramPhaseUnwrapping __fromPtr__ (IntPtr addr)
  36. {
  37. return new HistogramPhaseUnwrapping (addr);
  38. }
  39. //
  40. // C++: void cv::phase_unwrapping::HistogramPhaseUnwrapping::getInverseReliabilityMap(Mat& reliabilityMap)
  41. //
  42. //javadoc: HistogramPhaseUnwrapping::getInverseReliabilityMap(reliabilityMap)
  43. public void getInverseReliabilityMap (Mat reliabilityMap)
  44. {
  45. ThrowIfDisposed ();
  46. if (reliabilityMap != null)
  47. reliabilityMap.ThrowIfDisposed ();
  48. #if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
  49. phase_1unwrapping_HistogramPhaseUnwrapping_getInverseReliabilityMap_10 (nativeObj, reliabilityMap.nativeObj);
  50. return;
  51. #else
  52. return;
  53. #endif
  54. }
  55. #if (UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR
  56. const string LIBNAME = "__Internal";
  57. #else
  58. const string LIBNAME = "opencvforunity";
  59. #endif
  60. // C++: void cv::phase_unwrapping::HistogramPhaseUnwrapping::getInverseReliabilityMap(Mat& reliabilityMap)
  61. [DllImport (LIBNAME)]
  62. private static extern void phase_1unwrapping_HistogramPhaseUnwrapping_getInverseReliabilityMap_10 (IntPtr nativeObj, IntPtr reliabilityMap_nativeObj);
  63. // native support for java finalize()
  64. [DllImport (LIBNAME)]
  65. private static extern void phase_1unwrapping_HistogramPhaseUnwrapping_delete (IntPtr nativeObj);
  66. }
  67. }