private void SetupStep(SharedRef <IRasterImageBase> imageIn) { IRasterImageBase imgIn = imageIn.Reference; IRasterImageBase imgOut = imageOut.Reference; if (imgIn.Width != imgOut.Width || imgIn.Height != imgOut.Height) { imageCleaner.AddReference(imageOut); imageCleaner.CleanUpAll(); IRasterImageBase frame = new TrackerVideoFrame(imgIn.Height, imgIn.Width, new byte[imgIn.Height * imgIn.Width]); imageOut = SharedRef.Create(frame); } }
public P3CapTracker(EquipmentSettings settings) : base() { if (settings == null) { throw new ArgumentNullException("settings"); } this.settings = new EquipmentSettings(settings); this.pointDetector = null; this.pointLabeler = null; this.poseEstimator = null; IRasterImageBase frame = new TrackerVideoFrame(1, 1, new byte[1]); this.imageOut = SharedRef.Create(frame); this.imageCleaner = new SharedRefCleaner(32); this.trackerSync = new object(); }