コード例 #1
0
 public override IntPtr Get()
 {
     return(NativeMethods.features2d_Ptr_KAZE_get(ptr));
 }
コード例 #2
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="state"></param>
 public RNG(ulong state)
 {
     State = NativeMethods.core_RNG_new(state);
 }
コード例 #3
0
 /// <summary>
 /// Releases unmanaged resources
 /// </summary>
 protected override void DisposeUnmanaged()
 {
     NativeMethods.HandleException(
         NativeMethods.imgproc_LineIterator_delete(ptr));
     base.DisposeUnmanaged();
 }
コード例 #4
0
 /// <summary>
 /// returns uniformly distributed floating-point random number from [a,b) range
 /// </summary>
 /// <param name="a"></param>
 /// <param name="b"></param>
 /// <returns></returns>
 public float Uniform(float a, float b)
 {
     return(NativeMethods.core_RNG_uniform(State, a, b));
 }
コード例 #5
0
 /// <summary>
 ///
 /// </summary>
 public RNG()
 {
     State = NativeMethods.core_RNG_new();
 }
コード例 #6
0
 /// <summary>
 /// Releases unmanaged resources
 /// </summary>
 protected override void DisposeUnmanaged()
 {
     NativeMethods.vector_DMatch_delete(ptr);
     base.DisposeUnmanaged();
 }
コード例 #7
0
 /// <summary>
 ///
 /// </summary>
 /// <returns></returns>
 public uint Run()
 {
     return(NativeMethods.core_RNG_operatorThis(State));
 }
コード例 #8
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="pt"></param>
 /// <param name="edge"></param>
 /// <param name="vertex"></param>
 /// <returns></returns>
 public int Locate(Point2f pt, out int edge, out int vertex)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_locate(ptr, pt, out edge, out vertex);
 }
コード例 #9
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="pt"></param>
 /// <param name="nearestPt"></param>
 /// <returns></returns>
 public int FindNearest(Point2f pt, out Point2f nearestPt)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_findNearest(ptr, pt, out nearestPt);
 }
コード例 #10
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="rect"></param>
 public void InitDelaunay(Rect rect)
 {
     if(disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     NativeMethods.imgproc_Subdiv2D_initDelaunay(ptr, rect);
 }
コード例 #11
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="pt"></param>
 /// <returns></returns>
 public int Insert(Point2f pt)
 {
     if(disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_insert(ptr, pt);
 }
コード例 #12
0
ファイル: SparseMat.cs プロジェクト: zhaohh1985/opencvsharp
        /// <summary>
        /// 空の疎行列として初期化
        /// </summary>
#else
        /// <summary>
        /// Creates empty SparseMat
        /// </summary>
#endif
        public SparseMat()
        {
            NativeMethods.HandleException(
                NativeMethods.core_SparseMat_new1(out ptr));
        }
コード例 #13
0
ファイル: SparseMat.cs プロジェクト: zhaohh1985/opencvsharp
 /// <summary>
 /// Releases unmanaged resources
 /// </summary>
 protected override void DisposeUnmanaged()
 {
     NativeMethods.HandleException(
         NativeMethods.core_SparseMat_delete(ptr));
     base.DisposeUnmanaged();
 }
コード例 #14
0
 protected override void DisposeUnmanaged()
 {
     NativeMethods.features2d_Ptr_KAZE_delete(ptr);
     base.DisposeUnmanaged();
 }
コード例 #15
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="deviceId"></param>
 /// <returns></returns>
 public static FrameSource CreateFrameSource_Camera(int deviceId)
 {
     IntPtr ptr = NativeMethods.superres_createFrameSource_Camera(deviceId);
     return FrameSourceImpl.FromPtr(ptr);
 }
コード例 #16
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="vertex"></param>
 /// <param name="firstEdge"></param>
 /// <returns></returns>
 public Point2f GetVertex(int vertex, out int firstEdge)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_getVertex(ptr, vertex, out firstEdge);
 }
コード例 #17
0
 /// <summary>
 ///
 /// </summary>
 public VectorOfDMatch()
 {
     ptr = NativeMethods.vector_DMatch_new1();
 }
コード例 #18
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="edge"></param>
 /// <param name="nextEdgeType"></param>
 /// <returns></returns>
 public int GetEdge(int edge, int nextEdgeType)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_getEdge(ptr, edge, nextEdgeType);
 }
コード例 #19
0
 /// <summary>
 /// updates the state and returns the next 32-bit unsigned integer random number
 /// </summary>
 /// <returns></returns>
 public uint Next()
 {
     return(NativeMethods.core_RNG_next(State));
 }
コード例 #20
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="edge"></param>
 /// <param name="rotate"></param>
 /// <returns></returns>
 public int RotateEdge(int edge, int rotate)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_rotateEdge(ptr, edge, rotate);
 }
コード例 #21
0
 /// <summary>
 /// returns uniformly distributed integer random number from [a,b) range
 /// </summary>
 /// <param name="a"></param>
 /// <param name="b"></param>
 /// <returns></returns>
 public int Uniform(int a, int b)
 {
     return(NativeMethods.core_RNG_uniform(State, a, b));
 }
コード例 #22
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="edge"></param>
 /// <returns></returns>
 public int SymEdge(int edge)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_symEdge(ptr, edge);
 }
コード例 #23
0
 /// <summary>
 /// returns uniformly distributed double-precision floating-point random number from [a,b) range
 /// </summary>
 /// <param name="a"></param>
 /// <param name="b"></param>
 /// <returns></returns>
 public double Uniform(double a, double b)
 {
     return(NativeMethods.core_RNG_uniform(State, a, b));
 }
コード例 #24
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 /// 
 /// </summary>
 /// <param name="edge"></param>
 /// <param name="dstpt"></param>
 /// <returns></returns>
 public int EdgeDst(int edge, out Point2f dstpt)
 {
     if (disposed)
         throw new ObjectDisposedException("Subdiv2D", "");
     return NativeMethods.imgproc_Subdiv2D_edgeDst(ptr, edge, out dstpt);
 }
コード例 #25
0
 /// <summary>
 /// returns Gaussian random variate with mean zero.
 /// </summary>
 /// <param name="sigma"></param>
 /// <returns></returns>
 public double Gaussian(double sigma)
 {
     return(NativeMethods.core_RNG_gaussian(State, sigma));
 }
コード例 #26
0
ファイル: Subdiv2D.cs プロジェクト: 180D-FW-2020/Team13
        /// <summary>
        /// Subdiv2D コンストラクタ
        /// </summary>
        /// <param name="rect"></param>
#else
        /// <summary>
        /// Subdiv2D Constructor
        /// </summary>
        /// <param name="rect"></param>
#endif
        public Subdiv2D(Rect rect)
        {
            ptr = NativeMethods.imgproc_Subdiv2D_new(rect);
            if (ptr == IntPtr.Zero)
                throw new OpenCvSharpException();
        }
コード例 #27
0
ファイル: VectorOfRect.cs プロジェクト: 180D-FW-2020/Team13
 /// <summary>
 ///
 /// </summary>
 public VectorOfRect()
 {
     ptr = NativeMethods.vector_Rect_new1();
 }
コード例 #28
0
 /// <summary>
 /// 
 /// </summary>
 /// <returns></returns>
 public static FrameSource CreateFrameSource_Empty()
 {
     IntPtr ptr = NativeMethods.superres_createFrameSource_Empty();
     return FrameSourceImpl.FromPtr(ptr);
 }
コード例 #29
0
 protected override void DisposeUnmanaged()
 {
     NativeMethods.HandleException(
         NativeMethods.features2d_Ptr_AKAZE_delete(ptr));
     base.DisposeUnmanaged();
 }
コード例 #30
0
 /// <summary>
 /// Adds elements to the bottom of the matrix. (Mat::push_back)
 /// </summary>
 /// <param name="value">Added element(s)</param>
 public override void Add(double value)
 {
     ThrowIfDisposed();
     NativeMethods.core_Mat_push_back_double(ptr, value);
 }