Esempio n. 1
0
 /// <summary>
 /// Release all the unmanaged memory associated with the GScalar
 /// </summary>
 protected override void DisposeObject()
 {
     if (IntPtr.Zero != _ptr)
     {
         GapiInvoke.cveGScalarRelease(ref _ptr);
     }
 }
Esempio n. 2
0
        /// <summary>
        /// Execute an unary computation (with compilation on the fly)
        /// </summary>
        /// <param name="input">Input Mat for unary computation</param>
        /// <returns>Resulting scalar for unary computation</returns>
        public MCvScalar ApplyS(Mat input)
        {
            MCvScalar result = new MCvScalar();

            GapiInvoke.cveGComputationApply2(_ptr, input, ref result);
            return(result);
        }
Esempio n. 3
0
 /// <summary>
 /// Release all the unmanaged memory associated with this GMat
 /// </summary>
 protected override void DisposeObject()
 {
     if (_needDispose && (IntPtr.Zero != _ptr))
     {
         GapiInvoke.cveGMatRelease(ref _ptr);
     }
 }
Esempio n. 4
0
 /// <summary>
 /// Create a GScalar from a scalar value.
 /// </summary>
 /// <param name="value">The scalar value</param>
 public GScalar(MCvScalar value)
 {
     _ptr = GapiInvoke.cveGScalarCreate(ref value);
 }
Esempio n. 5
0
 /// <summary>
 /// Execute an unary computation (with compilation on the fly)
 /// </summary>
 /// <param name="input">Input Mat for unary computation</param>
 /// <param name="output">Output Mat for unary computation</param>
 public void Apply(Mat input, Mat output)
 {
     GapiInvoke.cveGComputationApply1(_ptr, input, output);
 }
Esempio n. 6
0
 /// <summary>
 /// Defines a computation with arbitrary input/output number.
 /// </summary>
 /// <param name="inputs">Vector of inputs GMats for this computation</param>
 /// <param name="outputs">Vector of outputs GMats for this computation</param>
 public GComputation(VectorOfGMat inputs, VectorOfGMat outputs)
 {
     _ptr = GapiInvoke.cveGComputationCreate5(inputs, outputs);
 }
Esempio n. 7
0
 /// <summary>
 /// Defines a binary (two inputs – one output) computation.
 /// </summary>
 /// <param name="input1">First input GMat of the defined binary computation</param>
 /// <param name="input2">Second input GMat of the defined binary computation</param>
 /// <param name="output">Output GScalar of the defined binary computation</param>
 public GComputation(GMat input1, GMat input2, GScalar output)
 {
     _ptr = GapiInvoke.cveGComputationCreate4(input1, input2, output);
 }
Esempio n. 8
0
 /// <summary>
 /// Defines an unary (one input – one output) computation.
 /// </summary>
 /// <param name="input">Input GMat of the defined unary computation</param>
 /// <param name="output">Output GScalar of the defined unary computation</param>
 public GComputation(GMat input, GScalar output)
 {
     _ptr = GapiInvoke.cveGComputationCreate2(input, output);
 }
Esempio n. 9
0
 /// <summary>
 /// Defines an unary (one input – one output) computation.
 /// </summary>
 /// <param name="input">Input GMat of the defined unary computation</param>
 /// <param name="output">Output GMat of the defined unary computation</param>
 public GComputation(GMat input, GMat output)
 {
     _ptr = GapiInvoke.cveGComputationCreate1(input, output);
 }
Esempio n. 10
0
 /// <summary>
 /// Execute a computation with arbitrary number of inputs/outputs (with compilation on-the-fly).
 /// </summary>
 /// <param name="input">Vector of input Mat objects to process by the computation.</param>
 /// <param name="output">Vector of output Mat objects to produce by the computation.</param>
 public void Apply(VectorOfMat input, VectorOfMat output)
 {
     GapiInvoke.cveGComputationApply5(_ptr, input, output);
 }
Esempio n. 11
0
 /// <summary>
 /// Execute a binary computation (with compilation on the fly)
 /// </summary>
 /// <param name="input1">First input Mat for binary computation</param>
 /// <param name="input2">Second input Mat for binary computation</param>
 /// <param name="output">Output Mat for binary computation</param>
 public void Apply(Mat input1, Mat input2, Mat output)
 {
     GapiInvoke.cveGComputationApply3(_ptr, input1, input2, output);
 }
Esempio n. 12
0
 /// <summary>
 /// Create a new GMat
 /// </summary>
 public GMat()
     : this(GapiInvoke.cveGMatCreate(), true)
 {
 }