public Viewer(ICasterSocket casterSocket, IScreenCapturer screenCapturer, IClipboardService clipboardService, IWebRtcSessionFactory webRtcSessionFactory, IAudioCapturer audioCapturer) { Capturer = screenCapturer; CasterSocket = casterSocket; WebRtcSessionFactory = webRtcSessionFactory; ClipboardService = clipboardService; ClipboardService.ClipboardTextChanged += ClipboardService_ClipboardTextChanged; AudioCapturer = audioCapturer; AudioCapturer.AudioSampleReady += AudioCapturer_AudioSampleReady; }
public Viewer(CasterSocket casterSocket, IScreenCapturer screenCapturer, IClipboardService clipboardService, IWebRtcSessionFactory webRtcSessionFactory, IAudioCapturer audioCapturer) { Capturer = screenCapturer; CasterSocket = casterSocket; WebRtcSessionFactory = webRtcSessionFactory; EncoderParams = new EncoderParameters(); ImageQuality = defaultImageQuality; ClipboardService = clipboardService; ClipboardService.ClipboardTextChanged += ClipboardService_ClipboardTextChanged; AudioCapturer = audioCapturer; AudioCapturer.AudioSampleReady += AudioCapturer_AudioSampleReady; }
public PlaybackStreamViewModel(IScreenCapturer screenCapturer, IWindowManager windowManager, IActiveProfileProvider activeProfileProvider) { _screenCapturer = screenCapturer; _windowManager = windowManager; _activeProfileProvider = activeProfileProvider; _activeProfileProvider.ActiveProfileChanged += ChangeProfile; _screenCapturer.CaptureRegionResolver = () => _activeProfile != null ? _activeProfile.CaptureRegion : new ScreenRegion(); _screenCapturer.CapturesPerSecondResolver = () => _activeProfile != null ? _activeProfile.CPS : 25; _screenCapturer.ScreenCaptured += (sender, args) => { CapturedImage = args.CapturedImage; }; CanShow = true; }
public Tuple <double, double> GetAbsolutePointFromRelativePercent(double percentX, double percentY, IScreenCapturer capturer) { var absoluteX = (capturer.CurrentScreenBounds.Width * percentX) + capturer.CurrentScreenBounds.Left; var absoluteY = (capturer.CurrentScreenBounds.Height * percentY) + capturer.CurrentScreenBounds.Top; return(new Tuple <double, double>(absoluteX, absoluteY)); }
public CurrentActivityProvider(IKeyLogger keyLogger, IScreenCapturer screenCapture) { _keyLogger = keyLogger; _screenCapture = screenCapture; }
public Hands(IInputGenerator inputGenerator, IScreenCapturer screenCapturer) { this.inputGenerator = inputGenerator; this.screenCapturer = screenCapturer; }
public Eyes(IScreenCapturer screenCapturer, IBrain brain, IBoardLogger boardLogger) { this.screenCapturer = screenCapturer; this.brain = brain; this.boardLogger = boardLogger; }
public Tuple <double, double> GetAbsolutePercentFromRelativePercent(double percentX, double percentY, IScreenCapturer capturer) { var screenBounds = capturer.CurrentScreenBounds; var absoluteX = (screenBounds.Width * percentX) + screenBounds.Left - capturer.GetVirtualScreenBounds().Left; var absoluteY = (screenBounds.Height * percentY) + screenBounds.Top - capturer.GetVirtualScreenBounds().Top; return(new Tuple <double, double>(absoluteX / capturer.GetVirtualScreenBounds().Width, absoluteY / capturer.GetVirtualScreenBounds().Height)); }