Class Algorithm
- Namespace
- OpenCvSharp
- Assembly
- OpenCvSharp.dll
Base class for high-level OpenCV algorithms
public abstract class Algorithm : CvPtrObject, IDisposable
- Inheritance
-
Algorithm
- Implements
- Derived
- Inherited Members
Constructors
Algorithm(nint, Action<nint>)
Constructor for the direct-allocation pattern (raw T* only).
protected Algorithm(nint rawPtr, Action<nint> releaseRawPtr)
Parameters
Algorithm(nint, nint, Action<nint>)
Constructor for the factory pattern (cv::Ptr<T>* + raw T*).
protected Algorithm(nint smartPtr, nint rawPtr, Action<nint> releaseSmartPtr)
Parameters
Properties
Empty
Returns true if the Algorithm is empty (e.g. in the very beginning or after unsuccessful read
public virtual bool Empty { get; }
Property Value
Methods
GetDefaultName()
Returns the algorithm string identifier. This string is used as top level xml/yml node tag when the object is saved to a file or string.
public virtual string GetDefaultName()
Returns
Read(FileNode)
Reads algorithm parameters from a file storage
public virtual void Read(FileNode fn)
Parameters
fnFileNode
Save(string)
Saves the algorithm to a file. In order to make this method work, the derived class must implement Algorithm::write(FileStorage fs).
public virtual void Save(string fileName)
Parameters
fileNamestring
Write(FileStorage)
Stores algorithm parameters in a file storage
public virtual void Write(FileStorage fs)
Parameters
fsFileStorage