12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879 |
-
- using OpenCVForUnity.CoreModule;
- using OpenCVForUnity.UtilsModule;
- using System;
- using System.Collections.Generic;
- using System.Runtime.InteropServices;
- namespace OpenCVForUnity.XphotoModule
- {
- // C++: class WhiteBalancer
- //javadoc: WhiteBalancer
- public class WhiteBalancer : Algorithm
- {
- protected override void Dispose (bool disposing)
- {
- #if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
- try {
- if (disposing) {
- }
- if (IsEnabledDispose) {
- if (nativeObj != IntPtr.Zero)
- xphoto_WhiteBalancer_delete(nativeObj);
- nativeObj = IntPtr.Zero;
- }
- } finally {
- base.Dispose (disposing);
- }
- #else
- return;
- #endif
- }
- protected internal WhiteBalancer (IntPtr addr) : base (addr) { }
- // internal usage only
- public static new WhiteBalancer __fromPtr__ (IntPtr addr) { return new WhiteBalancer (addr); }
- //
- // C++: void cv::xphoto::WhiteBalancer::balanceWhite(Mat src, Mat& dst)
- //
- //javadoc: WhiteBalancer::balanceWhite(src, dst)
- public void balanceWhite (Mat src, Mat dst)
- {
- ThrowIfDisposed ();
- if (src != null) src.ThrowIfDisposed ();
- if (dst != null) dst.ThrowIfDisposed ();
- #if ((UNITY_ANDROID || UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR) || UNITY_5 || UNITY_5_3_OR_NEWER
-
- xphoto_WhiteBalancer_balanceWhite_10(nativeObj, src.nativeObj, dst.nativeObj);
-
- return;
- #else
- return;
- #endif
- }
- #if (UNITY_IOS || UNITY_WEBGL) && !UNITY_EDITOR
- const string LIBNAME = "__Internal";
- #else
- const string LIBNAME = "opencvforunity";
- #endif
- // C++: void cv::xphoto::WhiteBalancer::balanceWhite(Mat src, Mat& dst)
- [DllImport (LIBNAME)]
- private static extern void xphoto_WhiteBalancer_balanceWhite_10 (IntPtr nativeObj, IntPtr src_nativeObj, IntPtr dst_nativeObj);
- // native support for java finalize()
- [DllImport (LIBNAME)]
- private static extern void xphoto_WhiteBalancer_delete (IntPtr nativeObj);
- }
- }
|