OpenCvSharp.Cv2.GetWindowProperty C# (CSharp) Method

GetWindowProperty() public static method

Provides parameters of a window.
public static GetWindowProperty ( string winName, WindowProperty propId ) : double
winName string Name of the window.
propId WindowProperty Window property to retrieve.
return double
        public static double GetWindowProperty(string winName, WindowProperty propId)
        {
            if (String.IsNullOrEmpty(winName))
                throw new ArgumentNullException(nameof(winName));
            return NativeMethods.highgui_getWindowProperty(winName, (int) propId);
        }

Usage Example

コード例 #1
0
        /// <summary>
        /// ウィンドウのプロパティを取得する
        /// </summary>
        /// <param name="propId">プロパティの種類</param>
        /// <returns>プロパティの値</returns>
#else
        /// <summary>
        /// Get Property of the window
        /// </summary>
        /// <param name="propId">Property identifier</param>
        /// <returns>Value of the specified property</returns>
#endif
        public double GetProperty(WindowProperty propId)
        {
            return(Cv2.GetWindowProperty(name, propId));
        }
Cv2