I\'ve used AForge library to make this little program, that shows live feed from a webcam into a PictureBox.
private FilterInfoCollection VideoCaptureDevices;
pr
Nager.VideoStream is based on ffmpeg and can therefore easily be used across platforms. Network cameras and webcams can be accessed via ffmpeg.
PM> install-package Nager.VideoStream
var inputSource = new StreamInputSource("rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mov");
//var inputSource = new WebcamInputSource("Microsoft® LifeCam HD-3000");
var cancellationTokenSource = new CancellationTokenSource();
var client = new VideoStreamClient();
client.NewImageReceived += NewImageReceived;
var task = client.StartFrameReaderAsync(inputSource, OutputImageFormat.Bmp, cancellationTokenSource.Token);
//Console.ReadLine();
client.NewImageReceived -= NewImageReceived;
private static void NewImageReceived(byte[] imageData)
{
File.WriteAllBytes($@"{DateTime.Now.Ticks}.bmp", imageData);
}