ZeBobo5 / Vlc.DotNet

.NET control that hosts the audio/video capabilities of the VLC libraries
MIT License
946 stars 418 forks source link

two player play at the same time #690

Open xzjs opened 3 years ago

xzjs commented 3 years ago

I have an issue / a question (pick one) about Vlc.DotNet.

Generic information

Summary

I have two players. I want them to play at the same time, what should I do?

jeremyVignelles commented 3 years ago

Use two media player controls?

Also, please consider switching to LibVLCSharp, this project is deprecated.

xzjs commented 3 years ago

yes, but i have done a lot of work in Vlc.DotNet ,are there any solutions?

mfkl commented 3 years ago

Use two media player controls?

xzjs commented 3 years ago

Use two media player controls?

yeah,i use two media player controls,and i play meida by this code

var actions = new Action[] {
    ()=>vlcControl1.Play(),
    ()=>vlcControl2.Play()
};
Parallel.Invoke(actions);

The two media are not playing simultaneously

mfkl commented 3 years ago

there is no easy way to sync 2 mediaplayers.

ZeBobo5 commented 3 years ago

You can try playing 2 videos in one media player like https://www.vlchelp.com/how-to-open-two-videos-side-by-side/ Not tested