internal FaceModel(FaceTracker faceTracker, IFTModel faceModelPtr) { if (faceTracker == null || faceModelPtr == null) { throw new InvalidOperationException("Cannot associate face model with null face tracker or native face model reference"); } this.faceTrackingModelPtr = faceModelPtr; this.faceTracker = faceTracker; }
protected virtual void Dispose(bool disposing) { if (!this.disposed) { if (this.faceTrackingModelPtr != null) { Marshal.FinalReleaseComObject(this.faceTrackingModelPtr); this.faceTrackingModelPtr = null; } this.disposed = true; } }