Mosharraf Hossain
Mosharraf Hossain

Reputation: 11

How can I use webcam as a source of Media with LibVLCSharp

I want to stream my webcam. How can I do that?

using var libVLC = new LibVLC(enableDebugLogs: true);

using var media = new Media(libVLC, new Uri("HD Webcam"));

using var mp = new MediaPlayer(media);

mp.Play();

Also want to use libVLCharp as audio/video devices as receivers and sources.

Upvotes: 1

Views: 954

Answers (1)

cube45
cube45

Reputation: 4039

Use dshow:// as the media URL, if you're using windows.

As a rule of thumb, try to find the syntax for the VLC command line, and this will give you the way for LibVLCSharp.

Upvotes: 2

Related Questions