[NUI] Add GetBrightness()
authorJoogab Yun <joogab.yun@samsung.com>
Mon, 26 Jul 2021 01:49:07 +0000 (10:49 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Mon, 26 Jul 2021 06:49:17 +0000 (15:49 +0900)
src/Tizen.NUI/src/internal/Interop/Interop.PixelBuffer.cs
src/Tizen.NUI/src/public/PixelBuffer.cs

index 5b3ba309545ffc0191e6345724a61802f1fb7739..3762de5fdf146b9adcf0eee32b2e52c4e11ae91c 100755 (executable)
@@ -66,6 +66,9 @@ namespace Tizen.NUI
 
             [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_PixelBuffer_Rotate")]
             public static extern bool PixelBuffer_Rotate(global::System.Runtime.InteropServices.HandleRef jarg1, global::System.Runtime.InteropServices.HandleRef jarg2);
+
+            [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_PixelBuffer_GetBrightness")]
+            public static extern uint GetBrightness(global::System.Runtime.InteropServices.HandleRef jarg1);
         }
     }
 }
\ No newline at end of file
index 83a3b26a0b57a514d9b4312cf275e809fcf2b48e..a6686bac76429a8c77ee872fbe62bc2a50f56196 100755 (executable)
@@ -272,6 +272,17 @@ namespace Tizen.NUI
             return ret;
         }
 
+        /// <summary>
+        ///  Gets the brightness value of the pixel buffer.
+        /// </summary>
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        public uint GetBrightness()
+        {
+            uint ret = Interop.PixelBuffer.GetBrightness(swigCPtr);
+            if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+            return ret;
+        }
+
         internal static global::System.Runtime.InteropServices.HandleRef getCPtr(PixelBuffer obj)
         {
             return (obj == null) ? new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero) : obj.swigCPtr;