Esempio n. 1
0
        public DatumProducer(StdSharedPtr <Producer> producerSharedPtr,
                             ulong frameFirst = 0,
                             ulong frameStep  = 1,
                             ulong frameLast  = ulong.MaxValue)
        {
            if (producerSharedPtr == null)
            {
                throw new ArgumentNullException(nameof(producerSharedPtr));
            }

            producerSharedPtr.ThrowIfDisposed();

            this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
            this.NativePtr = NativeMethods.op_DatumProducer_new(this._DataType,
                                                                producerSharedPtr.NativePtr,
                                                                frameFirst,
                                                                frameStep,
                                                                frameLast,
                                                                IntPtr.Zero);
        }
Esempio n. 2
0
 internal WDatumProducer(IntPtr ptr, bool isEnabledDispose = true) :
     base(ptr, isEnabledDispose)
 {
     this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
     this.NativePtr = ptr;
 }
Esempio n. 3
0
 public ThreadManager(ThreadManagerMode threadManagerMode = ThreadManagerMode.Synchronous)
 {
     this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
     this.NativePtr = OpenPose.Native.op_ThreadManager_new(this._DataType, threadManagerMode);
 }
Esempio n. 4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="Wrapper{T}"/> class with the specified ThreadManager synchronization mode.
 /// </summary>
 /// <param name="threadManagerMode"></param>
 public Wrapper(ThreadManagerMode threadManagerMode = ThreadManagerMode.Synchronous)
 {
     this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
     this.NativePtr = NativeMethods.op_wrapper_new(this._DataType, threadManagerMode);
 }
 protected WorkerProducer(IntPtr ptr, bool isEnabledDispose = true) :
     base(ptr, isEnabledDispose)
 {
     this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
 }
Esempio n. 6
0
 protected Worker(IntPtr ptr, bool isEnabledDispose = true) :
     base(isEnabledDispose)
 {
     this._DataType = GenericHelpers.CheckDatumSupportTypes <T>();
     this.NativePtr = ptr;
 }