Arr, that's a real pitty!the current version is only designed for one instance, cause the VideoOutputController, which is a static unique class, can only have one video output. So the last created VlcElement, which sets the video output in the VideoOutputController class, will display the video.
Code: Select all
//publicENEMY
public TimeSpan WatcherInterval
{
get { return watcherTimer.Interval; }
set
{
watcherTimer.Interval = value;
}
}
Code: Select all
private void buttonBrowse_Click(object sender, RoutedEventArgs e)
{
OpenFileDialog openFileDialog = new OpenFileDialog();
if (openFileDialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
{
Source.Text = openFileDialog.FileNames[0];
string[] safeFileNames = openFileDialog.SafeFileNames;
}
}
The Play2() method is a dirty workaround for a libvlc 0.8.6 bug. If a conetnt finished in libvlc 0.8.6 and you clear the playlist, add a new target to it and invoke play(), it will play the last content and not the current one (although the playlist has only 1 item!). The only way I've managed to solve it, was to invoke play() and after some waiting cycles (e.g. 100 ms) restart the content by invoke stop() and play() again -> after that the right content will be played. So it could be that some other issues can be appear by doing it that way.sometime when i use Play2(), the position is not correct. so the position slider does not move. is there anything i have to keep in mind when using Play2()?
Just now I've created a version, which allows a variable count of instances of the vlc element. Works good, but I have to do some performance tests, before I can release it.BenZC wrote:the current version is only designed for one instance, cause the VideoOutputController, which is a static unique class, can only have one video output. So the last created VlcElement, which sets the video output in the VideoOutputController class, will display the video.
Arr, that's a real pitty!
(How ) can this be solved?
Code: Select all
public string Source
{
get { return source; }
set
{
source = value;
vlc.PlaylistClear();
char[] delimiterChars = { ' ', };
string[] words = Source.Split(delimiterChars, StringSplitOptions.RemoveEmptyEntries);
if (words.Length>1)
{
string[] options = new string[words.Length-1];
for (int i=1; i<words.Length; i++)
{
options[i-1] = words[i];
}
vlc.AddTarget(words[0], options);
}
else
{
vlc.AddTarget(source);
}
}
}
Is there a chance to get the version that allows more instances of the vlc element? I would be more than happy testing itJust now I've created a version, which allows a variable count of instances of the vlc element. Works good, but I have to do some performance tests, before I can release it.
Return to “VLC media player for Windows Troubleshooting”
Users browsing this forum: No registered users and 116 guests