public FakeCapturer() { timer = new LiveSourceTimer(); timer.ElapsedTime += delegate(Time ellapsedTime) { if (ElapsedTime != null) { ElapsedTime(ellapsedTime); } }; }
public unsafe GstCameraCapturer(string filename) : base(IntPtr.Zero) { if (GetType() != typeof(GstCameraCapturer)) { throw new InvalidOperationException("Can't override this constructor."); } IntPtr error = IntPtr.Zero; Raw = gst_camera_capturer_new(out error); if (error != IntPtr.Zero) { throw new GLib.GException(error); } timer = new LiveSourceTimer(); timer.ElapsedTime += delegate(Time ellapsedTime) { if (ElapsedTime != null) { ElapsedTime(ellapsedTime); } }; this.GlibError += (o, args) => { if (Error != null) { Error(this, args.Message); } }; this.GlibDeviceChange += (o, args) => { if (DeviceChange != null) { DeviceChange(args.DeviceChange); } }; this.GlibMediaInfo += (o, args) => { if (MediaInfo != null) { MediaInfo(args.Width, args.Height, args.ParN, args.ParD); } }; this.GlibReadyToCapture += (o, args) => { if (ReadyToCapture != null) { ReadyToCapture(this); } }; }