diff --git a/LibVLCSharp.WPF.Sample/App.config b/LibVLCSharp.WPF.Sample/App.config
new file mode 100644
index 000000000..731f6de6c
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/App.config
@@ -0,0 +1,6 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/App.xaml b/LibVLCSharp.WPF.Sample/App.xaml
new file mode 100644
index 000000000..2d1dc7fcc
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/App.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
diff --git a/LibVLCSharp.WPF.Sample/App.xaml.cs b/LibVLCSharp.WPF.Sample/App.xaml.cs
new file mode 100644
index 000000000..814043037
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/App.xaml.cs
@@ -0,0 +1,8 @@
+using System.Windows;
+
+namespace LibVlcSharp.Wpf.Sample
+{
+ public class App : Application
+ {
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Controls.xaml b/LibVLCSharp.WPF.Sample/Controls.xaml
new file mode 100644
index 000000000..2f8b2f657
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Controls.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
diff --git a/LibVLCSharp.WPF.Sample/Controls.xaml.cs b/LibVLCSharp.WPF.Sample/Controls.xaml.cs
new file mode 100644
index 000000000..0fce3d4ca
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Controls.xaml.cs
@@ -0,0 +1,39 @@
+using LibVLCSharp.Shared;
+
+using System.Windows;
+using System.Windows.Controls;
+
+namespace LibVLCSharp.WPF.Sample
+{
+ public partial class Controls : UserControl
+ {
+ readonly Example1 parent;
+
+ public Controls(Example1 Parent)
+ {
+ parent = Parent;
+
+ InitializeComponent();
+
+ PlayButton.Click += PlayButton_Click;
+ StopButton.Click += StopButton_Click;
+ }
+
+ void StopButton_Click(object sender, RoutedEventArgs e)
+ {
+ if (parent.Player.MediaPlayer.IsPlaying)
+ {
+ parent.Player.MediaPlayer.Stop();
+ }
+ }
+
+ void PlayButton_Click(object sender, RoutedEventArgs e)
+ {
+ if (!parent.Player.MediaPlayer.IsPlaying)
+ {
+ parent.Player.MediaPlayer.Play(new Media(parent.Player.LibVLC,
+ "http://www.quirksmode.org/html5/videos/big_buck_bunny.mp4", Media.FromType.FromLocation));
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Example1.xaml b/LibVLCSharp.WPF.Sample/Example1.xaml
new file mode 100644
index 000000000..66e3afdae
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Example1.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Example1.xaml.cs b/LibVLCSharp.WPF.Sample/Example1.xaml.cs
new file mode 100644
index 000000000..627bfbd0a
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Example1.xaml.cs
@@ -0,0 +1,17 @@
+using System.Windows;
+
+namespace LibVLCSharp.WPF.Sample
+{
+ public partial class Example1 : Window
+ {
+ readonly Controls _controls;
+
+ public Example1()
+ {
+ InitializeComponent();
+
+ _controls = new Controls(this);
+ Player.Content = _controls;
+ }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Example2.xaml b/LibVLCSharp.WPF.Sample/Example2.xaml
new file mode 100644
index 000000000..db983e5ea
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Example2.xaml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/LibVLCSharp.WPF.Sample/Example2.xaml.cs b/LibVLCSharp.WPF.Sample/Example2.xaml.cs
new file mode 100644
index 000000000..7e4da9396
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Example2.xaml.cs
@@ -0,0 +1,42 @@
+using LibVLCSharp.Shared;
+
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Media;
+
+namespace LibVLCSharp.WPF.Sample
+{
+ public partial class Example2 : Window
+ {
+ public Example2()
+ {
+ InitializeComponent();
+
+ var label = new Label
+ {
+ Content = "TEST",
+ HorizontalAlignment = HorizontalAlignment.Right,
+ VerticalAlignment = VerticalAlignment.Bottom,
+ Foreground = new SolidColorBrush(Colors.Red)
+ };
+ test.Children.Add(label);
+ }
+
+ void StopButton_Click(object sender, RoutedEventArgs e)
+ {
+ if (Player.MediaPlayer.IsPlaying)
+ {
+ Player.MediaPlayer.Stop();
+ }
+ }
+
+ void PlayButton_Click(object sender, RoutedEventArgs e)
+ {
+ if (!Player.MediaPlayer.IsPlaying)
+ {
+ Player.MediaPlayer.Play(new Media(Player.LibVLC,
+ "http://www.quirksmode.org/html5/videos/big_buck_bunny.mp4", Media.FromType.FromLocation));
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/LibVLCSharp.WPF.Sample.csproj b/LibVLCSharp.WPF.Sample/LibVLCSharp.WPF.Sample.csproj
new file mode 100644
index 000000000..e45159aa9
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/LibVLCSharp.WPF.Sample.csproj
@@ -0,0 +1,133 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}
+ WinExe
+ LibVLCSharp.WPF.Sample
+ LibVLCSharp.WPF.Sample
+ v4.6.1
+ 512
+ {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ 4
+ true
+
+
+
+
+ AnyCPU
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ AnyCPU
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+
+
+
+
+
+
+
+
+ 4.0
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+ Designer
+
+
+ App.xaml
+ Code
+
+
+ Controls.xaml
+
+
+ Example2.xaml
+
+
+ Example1.xaml
+
+
+ MainWindow.xaml
+ Code
+
+
+
+
+ Code
+
+
+ True
+ True
+ Resources.resx
+
+
+ True
+ Settings.settings
+ True
+
+
+ ResXFileCodeGenerator
+ Resources.Designer.cs
+
+
+
+ SettingsSingleFileGenerator
+ Settings.Designer.cs
+
+
+
+
+
+
+
+ {da7a2677-0944-481f-a59b-9128fc54fd5f}
+ LibVLCSharp.WPF
+
+
+ {d1c3b7c4-713b-46b2-b33a-e9298c819921}
+ LibVLCSharp
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/LibVLCSharp.Wpf.Sample.csproj b/LibVLCSharp.WPF.Sample/LibVLCSharp.Wpf.Sample.csproj
new file mode 100644
index 000000000..e45159aa9
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/LibVLCSharp.Wpf.Sample.csproj
@@ -0,0 +1,133 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}
+ WinExe
+ LibVLCSharp.WPF.Sample
+ LibVLCSharp.WPF.Sample
+ v4.6.1
+ 512
+ {60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
+ 4
+ true
+
+
+
+
+ AnyCPU
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ AnyCPU
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+
+
+
+
+
+
+
+
+ 4.0
+
+
+
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+ Designer
+
+
+ App.xaml
+ Code
+
+
+ Controls.xaml
+
+
+ Example2.xaml
+
+
+ Example1.xaml
+
+
+ MainWindow.xaml
+ Code
+
+
+
+
+ Code
+
+
+ True
+ True
+ Resources.resx
+
+
+ True
+ Settings.settings
+ True
+
+
+ ResXFileCodeGenerator
+ Resources.Designer.cs
+
+
+
+ SettingsSingleFileGenerator
+ Settings.Designer.cs
+
+
+
+
+
+
+
+ {da7a2677-0944-481f-a59b-9128fc54fd5f}
+ LibVLCSharp.WPF
+
+
+ {d1c3b7c4-713b-46b2-b33a-e9298c819921}
+ LibVLCSharp
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/MainWindow.xaml b/LibVLCSharp.WPF.Sample/MainWindow.xaml
new file mode 100644
index 000000000..a61fa9758
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/MainWindow.xaml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/MainWindow.xaml.cs b/LibVLCSharp.WPF.Sample/MainWindow.xaml.cs
new file mode 100644
index 000000000..4451e6bbe
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/MainWindow.xaml.cs
@@ -0,0 +1,26 @@
+using System.Windows;
+
+namespace LibVLCSharp.WPF.Sample
+{
+ public partial class MainWindow : Window
+ {
+ public MainWindow()
+ {
+ InitializeComponent();
+ Example1Btn.Click += Example1Btn_Click;
+ Example2Btn.Click += Example2Btn_Click;
+ }
+
+ void Example1Btn_Click(object sender, RoutedEventArgs e)
+ {
+ var window = new Example1();
+ window.Show();
+ }
+
+ void Example2Btn_Click(object sender, RoutedEventArgs e)
+ {
+ var window = new Example2();
+ window.Show();
+ }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Properties/AssemblyInfo.cs b/LibVLCSharp.WPF.Sample/Properties/AssemblyInfo.cs
new file mode 100644
index 000000000..db693448b
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Properties/AssemblyInfo.cs
@@ -0,0 +1,55 @@
+using System.Reflection;
+using System.Resources;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Windows;
+
+// Allgemeine Informationen über eine Assembly werden über die folgenden
+// Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
+// die einer Assembly zugeordnet sind.
+[assembly: AssemblyTitle("LibVLCSharp.WPF.Sample")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("LibVLCSharp.WPF.Sample")]
+[assembly: AssemblyCopyright("Copyright © 2018")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly
+// für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von
+// COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen.
+[assembly: ComVisible(false)]
+
+//Um mit dem Erstellen lokalisierbarer Anwendungen zu beginnen, legen Sie
+//ImCodeVerwendeteKultur in der .csproj-Datei
+//in einer fest. Wenn Sie in den Quelldateien beispielsweise Deutsch
+//(Deutschland) verwenden, legen Sie auf \"de-DE\" fest. Heben Sie dann die Auskommentierung
+//des nachstehenden NeutralResourceLanguage-Attributs auf. Aktualisieren Sie "en-US" in der nachstehenden Zeile,
+//sodass es mit der UICulture-Einstellung in der Projektdatei übereinstimmt.
+
+//[assembly: NeutralResourcesLanguage("en-US", UltimateResourceFallbackLocation.Satellite)]
+
+
+[assembly: ThemeInfo(
+ ResourceDictionaryLocation.None, //Speicherort der designspezifischen Ressourcenwörterbücher
+ //(wird verwendet, wenn eine Ressource auf der Seite nicht gefunden wird,
+ // oder in den Anwendungsressourcen-Wörterbüchern nicht gefunden werden kann.)
+ ResourceDictionaryLocation.SourceAssembly //Speicherort des generischen Ressourcenwörterbuchs
+ //(wird verwendet, wenn eine Ressource auf der Seite nicht gefunden wird,
+ // designspezifischen Ressourcenwörterbuch nicht gefunden werden kann.)
+)]
+
+
+// Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
+//
+// Hauptversion
+// Nebenversion
+// Buildnummer
+// Revision
+//
+// Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
+// übernehmen, indem Sie "*" eingeben:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/LibVLCSharp.WPF.Sample/Properties/Resources.Designer.cs b/LibVLCSharp.WPF.Sample/Properties/Resources.Designer.cs
new file mode 100644
index 000000000..9104d375e
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Properties/Resources.Designer.cs
@@ -0,0 +1,63 @@
+//------------------------------------------------------------------------------
+//
+// Dieser Code wurde von einem Tool generiert.
+// Laufzeitversion:4.0.30319.42000
+//
+// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
+// der Code erneut generiert wird.
+//
+//------------------------------------------------------------------------------
+
+namespace LibVLCSharp.WPF.Sample.Properties {
+ using System;
+
+
+ ///
+ /// Eine stark typisierte Ressourcenklasse zum Suchen von lokalisierten Zeichenfolgen usw.
+ ///
+ // Diese Klasse wurde von der StronglyTypedResourceBuilder automatisch generiert
+ // -Klasse über ein Tool wie ResGen oder Visual Studio automatisch generiert.
+ // Um einen Member hinzuzufügen oder zu entfernen, bearbeiten Sie die .ResX-Datei und führen dann ResGen
+ // mit der /str-Option erneut aus, oder Sie erstellen Ihr VS-Projekt neu.
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "15.0.0.0")]
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ internal class Resources {
+
+ private static global::System.Resources.ResourceManager resourceMan;
+
+ private static global::System.Globalization.CultureInfo resourceCulture;
+
+ [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+ internal Resources() {
+ }
+
+ ///
+ /// Gibt die zwischengespeicherte ResourceManager-Instanz zurück, die von dieser Klasse verwendet wird.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Resources.ResourceManager ResourceManager {
+ get {
+ if (object.ReferenceEquals(resourceMan, null)) {
+ global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("LibVLCSharp.WPF.Sample.Properties.Resources", typeof(Resources).Assembly);
+ resourceMan = temp;
+ }
+ return resourceMan;
+ }
+ }
+
+ ///
+ /// Überschreibt die CurrentUICulture-Eigenschaft des aktuellen Threads für alle
+ /// Ressourcenzuordnungen, die diese stark typisierte Ressourcenklasse verwenden.
+ ///
+ [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+ internal static global::System.Globalization.CultureInfo Culture {
+ get {
+ return resourceCulture;
+ }
+ set {
+ resourceCulture = value;
+ }
+ }
+ }
+}
diff --git a/LibVLCSharp.WPF.Sample/Properties/Resources.resx b/LibVLCSharp.WPF.Sample/Properties/Resources.resx
new file mode 100644
index 000000000..af7dbebba
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Properties/Resources.resx
@@ -0,0 +1,117 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ text/microsoft-resx
+
+
+ 2.0
+
+
+ System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
+ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/Properties/Settings.Designer.cs b/LibVLCSharp.WPF.Sample/Properties/Settings.Designer.cs
new file mode 100644
index 000000000..354e9d11b
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Properties/Settings.Designer.cs
@@ -0,0 +1,26 @@
+//------------------------------------------------------------------------------
+//
+// Dieser Code wurde von einem Tool generiert.
+// Laufzeitversion:4.0.30319.42000
+//
+// Änderungen an dieser Datei können falsches Verhalten verursachen und gehen verloren, wenn
+// der Code erneut generiert wird.
+//
+//------------------------------------------------------------------------------
+
+namespace LibVLCSharp.WPF.Sample.Properties {
+
+
+ [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+ [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.7.0.0")]
+ internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
+
+ private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
+
+ public static Settings Default {
+ get {
+ return defaultInstance;
+ }
+ }
+ }
+}
diff --git a/LibVLCSharp.WPF.Sample/Properties/Settings.settings b/LibVLCSharp.WPF.Sample/Properties/Settings.settings
new file mode 100644
index 000000000..033d7a5e9
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/Properties/Settings.settings
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF.Sample/packages.config b/LibVLCSharp.WPF.Sample/packages.config
new file mode 100644
index 000000000..3ad4bf9c9
--- /dev/null
+++ b/LibVLCSharp.WPF.Sample/packages.config
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF/ForegroundWindow.xaml b/LibVLCSharp.WPF/ForegroundWindow.xaml
new file mode 100644
index 000000000..ddd594472
--- /dev/null
+++ b/LibVLCSharp.WPF/ForegroundWindow.xaml
@@ -0,0 +1,10 @@
+
+
+
diff --git a/LibVLCSharp.WPF/ForegroundWindow.xaml.cs b/LibVLCSharp.WPF/ForegroundWindow.xaml.cs
new file mode 100644
index 000000000..7112653a6
--- /dev/null
+++ b/LibVLCSharp.WPF/ForegroundWindow.xaml.cs
@@ -0,0 +1,106 @@
+using System;
+using System.Diagnostics;
+using System.Windows;
+using System.Windows.Controls;
+
+using LibVLCSharp.Shared;
+
+namespace LibVLCSharp.WPF
+{
+ internal partial class ForegroundWindow : Window
+ {
+ Window _wndhost;
+ readonly ContentControl _bckgnd;
+ UIElement _content;
+ readonly Point _zeroPoint = new Point(0, 0);
+
+ internal new UIElement Content
+ {
+ get => _content;
+ set
+ {
+ _content = value;
+ if (_content != null)
+ {
+ PART_Content.Children.Clear();
+ PART_Content.Children.Add(_content);
+ }
+ }
+ }
+
+ internal ForegroundWindow(ContentControl background)
+ {
+ InitializeComponent();
+
+ _bckgnd = background;
+ _bckgnd.Loaded += Background_Loaded;
+ _bckgnd.Unloaded += Background_Unloaded;
+ }
+
+ void Background_Unloaded(object sender, RoutedEventArgs e)
+ {
+ _wndhost.Closing -= Wndhost_Closing;
+ _wndhost.SizeChanged -= Wndhost_SizeChanged;
+ _wndhost.LocationChanged -= Wndhost_LocationChanged;
+
+ Hide();
+ }
+
+ void Background_Loaded(object sender, RoutedEventArgs e)
+ {
+ _wndhost = GetWindow(_bckgnd);
+ Trace.Assert(_wndhost != null);
+
+ Owner = _wndhost;
+
+ _wndhost.Closing += Wndhost_Closing;
+ _wndhost.SizeChanged += Wndhost_SizeChanged;
+ _wndhost.LocationChanged += Wndhost_LocationChanged;
+
+ try
+ {
+ var locationFromScreen = _bckgnd.PointToScreen(_zeroPoint);
+ var source = PresentationSource.FromVisual(_wndhost);
+ var targetPoints = source.CompositionTarget.TransformFromDevice.Transform(locationFromScreen);
+ Left = targetPoints.X;
+ Top = targetPoints.Y;
+ var size = _bckgnd.PointToScreen(new Point(_bckgnd.ActualWidth, _bckgnd.ActualHeight)) - _bckgnd.PointToScreen(_zeroPoint);
+ Height = size.Y;
+ Width = size.X;
+ Show();
+ _wndhost.Focus();
+ }
+ catch
+ {
+ Hide();
+ throw new VLCException("Unable to create WPF Window in VideoView.");
+ }
+ }
+
+ void Wndhost_LocationChanged(object sender, EventArgs e)
+ {
+ var locationFromScreen = _bckgnd.PointToScreen(_zeroPoint);
+ var source = PresentationSource.FromVisual(_wndhost);
+ var targetPoints = source.CompositionTarget.TransformFromDevice.Transform(locationFromScreen);
+ Left = targetPoints.X;
+ Top = targetPoints.Y;
+ }
+
+ void Wndhost_SizeChanged(object sender, SizeChangedEventArgs e)
+ {
+ var locationFromScreen = _bckgnd.PointToScreen(_zeroPoint);
+ var source = PresentationSource.FromVisual(_wndhost);
+ var targetPoints = source.CompositionTarget.TransformFromDevice.Transform(locationFromScreen);
+ Left = targetPoints.X;
+ Top = targetPoints.Y;
+ var size = _bckgnd.PointToScreen(new Point(_bckgnd.ActualWidth, _bckgnd.ActualHeight)) - _bckgnd.PointToScreen(_zeroPoint);
+ Height = size.Y;
+ Width = size.X;
+ }
+
+ void Wndhost_Closing(object sender, System.ComponentModel.CancelEventArgs e)
+ {
+ Close();
+ }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.WPF/LibVLCSharp.WPF.csproj b/LibVLCSharp.WPF/LibVLCSharp.WPF.csproj
new file mode 100644
index 000000000..42674fc83
--- /dev/null
+++ b/LibVLCSharp.WPF/LibVLCSharp.WPF.csproj
@@ -0,0 +1,71 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}
+ Library
+ Properties
+ LibVLCSharp.WPF
+ LibVLCSharp.WPF
+ v4.6.1
+ 512
+
+
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ForegroundWindow.xaml
+
+
+
+
+
+
+ {d1c3b7c4-713b-46b2-b33a-e9298c819921}
+ LibVLCSharp
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF/LibVLCSharp.Wpf.csproj b/LibVLCSharp.WPF/LibVLCSharp.Wpf.csproj
new file mode 100644
index 000000000..42674fc83
--- /dev/null
+++ b/LibVLCSharp.WPF/LibVLCSharp.Wpf.csproj
@@ -0,0 +1,71 @@
+
+
+
+
+ Debug
+ AnyCPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}
+ Library
+ Properties
+ LibVLCSharp.WPF
+ LibVLCSharp.WPF
+ v4.6.1
+ 512
+
+
+ true
+ full
+ false
+ bin\Debug\
+ DEBUG;TRACE
+ prompt
+ 4
+
+
+ pdbonly
+ true
+ bin\Release\
+ TRACE
+ prompt
+ 4
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ ForegroundWindow.xaml
+
+
+
+
+
+
+ {d1c3b7c4-713b-46b2-b33a-e9298c819921}
+ LibVLCSharp
+
+
+
+
+ MSBuild:Compile
+
+
+ MSBuild:Compile
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF/Properties/AssemblyInfo.cs b/LibVLCSharp.WPF/Properties/AssemblyInfo.cs
new file mode 100644
index 000000000..ad4b206b4
--- /dev/null
+++ b/LibVLCSharp.WPF/Properties/AssemblyInfo.cs
@@ -0,0 +1,36 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// Allgemeine Informationen über eine Assembly werden über die folgenden
+// Attribute gesteuert. Ändern Sie diese Attributwerte, um die Informationen zu ändern,
+// die einer Assembly zugeordnet sind.
+[assembly: AssemblyTitle("LibVLCSharp.WPF")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("LibVLCSharp.WPF")]
+[assembly: AssemblyCopyright("Copyright © 2018")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Durch Festlegen von ComVisible auf FALSE werden die Typen in dieser Assembly
+// für COM-Komponenten unsichtbar. Wenn Sie auf einen Typ in dieser Assembly von
+// COM aus zugreifen müssen, sollten Sie das ComVisible-Attribut für diesen Typ auf "True" festlegen.
+[assembly: ComVisible(false)]
+
+// Die folgende GUID bestimmt die ID der Typbibliothek, wenn dieses Projekt für COM verfügbar gemacht wird
+[assembly: Guid("da7a2677-0944-481f-a59b-9128fc54fd5f")]
+
+// Versionsinformationen für eine Assembly bestehen aus den folgenden vier Werten:
+//
+// Hauptversion
+// Nebenversion
+// Buildnummer
+// Revision
+//
+// Sie können alle Werte angeben oder Standardwerte für die Build- und Revisionsnummern verwenden,
+// indem Sie "*" wie unten gezeigt eingeben:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
diff --git a/LibVLCSharp.WPF/Styles/VideoView.xaml b/LibVLCSharp.WPF/Styles/VideoView.xaml
new file mode 100644
index 000000000..b5765c782
--- /dev/null
+++ b/LibVLCSharp.WPF/Styles/VideoView.xaml
@@ -0,0 +1,23 @@
+
+
+
+
\ No newline at end of file
diff --git a/LibVLCSharp.WPF/VideoView.cs b/LibVLCSharp.WPF/VideoView.cs
new file mode 100644
index 000000000..59d778d10
--- /dev/null
+++ b/LibVLCSharp.WPF/VideoView.cs
@@ -0,0 +1,96 @@
+using System;
+using System.Windows;
+using System.Windows.Controls;
+
+using LibVLCSharp.Shared;
+
+namespace LibVLCSharp.WPF
+{
+ public class VideoView : UserControl, IVideoView, IDisposable
+ {
+ double _controlWidth;
+ double _controlHeight;
+ readonly ForegroundWindow _foreground;
+
+ public VideoView()
+ {
+ var res = Application.LoadComponent(new Uri("/LibVLCSharp.WPF;component/Styles/VideoView.xaml", UriKind.RelativeOrAbsolute)) as ResourceDictionary;
+ Style = res["VideoViewStyle"] as Style;
+
+ _foreground = new ForegroundWindow(this);
+
+ Core.Initialize();
+
+ LibVLC = new LibVLC();
+ MediaPlayer = new MediaPlayer(LibVLC);
+
+ SizeChanged += OnSizeChanged;
+
+ _controlHeight = Height;
+ _controlWidth = Width;
+
+ Loaded += VideoView_Loaded;
+ Unloaded += VideoView_Unloaded;
+ }
+
+ void VideoView_Unloaded(object sender, RoutedEventArgs e)
+ {
+ Dispose();
+ }
+
+ void VideoView_Loaded(object sender, RoutedEventArgs e)
+ {
+ MediaPlayer.Hwnd = ((System.Windows.Forms.Panel)Template.FindName("PART_PlayerView", this)).Handle;
+
+ if (Content != null)
+ {
+ var content = Content;
+ Content = null;
+ _foreground.Content = (UIElement)content;
+ }
+ }
+
+ void VLCResize()
+ {
+ uint h = 0, w = 0;
+
+ if (MediaPlayer.Size(0, ref w, ref h))
+ {
+ var scalew = (float)_controlWidth / w;
+
+ var scaleh = (float)_controlHeight / h;
+
+ var scale = scalew < scaleh ? scalew : scaleh;
+ MediaPlayer.Scale = scale;
+ }
+ }
+
+ void OnSizeChanged(object sender, SizeChangedEventArgs e)
+ {
+ _controlWidth = e.NewSize.Width;
+ _controlHeight = e.NewSize.Height;
+
+ if (MediaPlayer.IsPlaying)
+ {
+ VLCResize();
+ }
+ }
+
+ public void Dispose()
+ {
+ if (MediaPlayer.IsPlaying)
+ MediaPlayer.Stop();
+
+ SizeChanged -= OnSizeChanged;
+ Loaded -= VideoView_Loaded;
+ Unloaded -= VideoView_Unloaded;
+
+ MediaPlayer.Hwnd = IntPtr.Zero;
+ MediaPlayer.Dispose();
+ LibVLC.Dispose();
+ }
+
+ public MediaPlayer MediaPlayer { get; }
+ public LibVLC LibVLC { get; }
+ }
+}
\ No newline at end of file
diff --git a/LibVLCSharp.iOS.Sample/LibVLCSharp.iOS.Sample.csproj b/LibVLCSharp.iOS.Sample/LibVLCSharp.iOS.Sample.csproj
index 0a09bcc74..2d3bbdb02 100644
--- a/LibVLCSharp.iOS.Sample/LibVLCSharp.iOS.Sample.csproj
+++ b/LibVLCSharp.iOS.Sample/LibVLCSharp.iOS.Sample.csproj
@@ -83,11 +83,5 @@
-
-
-
- This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
-
-
-
+
\ No newline at end of file
diff --git a/LibVLCSharp.iOS.Sample/packages.config b/LibVLCSharp.iOS.Sample/packages.config
index 39bf017ec..2b949bd30 100644
--- a/LibVLCSharp.iOS.Sample/packages.config
+++ b/LibVLCSharp.iOS.Sample/packages.config
@@ -1,4 +1,4 @@
-
+
\ No newline at end of file
diff --git a/LibVLCSharp.nuspec b/LibVLCSharp.nuspec
index 7850d32e0..a324a57fd 100644
--- a/LibVLCSharp.nuspec
+++ b/LibVLCSharp.nuspec
@@ -3,7 +3,7 @@
LibVLCSharp
LibVLCSharp
- 0.0.1-alpha3
+ 0.0.1-alpha4
VideoLAN
VideoLAN
false
diff --git a/LibVLCSharp.sln b/LibVLCSharp.sln
index 248c7d62d..401eda2ca 100644
--- a/LibVLCSharp.sln
+++ b/LibVLCSharp.sln
@@ -27,13 +27,17 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.iOS.Sample", "L
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Samples", "Samples", "{799A84A2-2161-4676-878B-5610E3586137}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.Forms", "LibVLCSharp.Forms\LibVLCSharp.Forms.csproj", "{656D01BE-FBEA-491A-AB2C-4B6B375B52A9}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LibVLCSharp.Forms", "LibVLCSharp.Forms\LibVLCSharp.Forms.csproj", "{656D01BE-FBEA-491A-AB2C-4B6B375B52A9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.Forms.Sample.Android", "LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample.Android\LibVLCSharp.Forms.Sample.Android.csproj", "{C77C28DD-A2B2-403C-A907-76184BD5D11E}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.Forms.Sample.iOS", "LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample.iOS\LibVLCSharp.Forms.Sample.iOS.csproj", "{D2486BCF-A218-4181-B1F8-E6D46DCADCDC}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.Forms.Sample", "LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample.csproj", "{C6E79ABC-C203-4892-848A-FF99CCE53F8A}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "LibVLCSharp.Forms.Sample", "LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample\LibVLCSharp.Forms.Sample.csproj", "{C6E79ABC-C203-4892-848A-FF99CCE53F8A}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.WPF.Sample", "LibVlcSharp.WPF.Sample\LibVLCSharp.WPF.Sample.csproj", "{01CCB934-B77F-4681-86C5-AE4FEE648238}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LibVLCSharp.WPF", "LibVLCSharp.WPF\LibVLCSharp.WPF.csproj", "{DA7A2677-0944-481F-A59B-9128FC54FD5F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -517,6 +521,86 @@ Global
{C6E79ABC-C203-4892-848A-FF99CCE53F8A}.Release|x64.Build.0 = Release|Any CPU
{C6E79ABC-C203-4892-848A-FF99CCE53F8A}.Release|x86.ActiveCfg = Release|Any CPU
{C6E79ABC-C203-4892-848A-FF99CCE53F8A}.Release|x86.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|Any CPU.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|Any CPU.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|iPhone.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|iPhone.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|iPhoneSimulator.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|x64.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|x64.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|x86.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Ad-Hoc|x86.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|Any CPU.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|Any CPU.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|iPhone.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|iPhone.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|iPhoneSimulator.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|x64.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|x64.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|x86.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.AppStore|x86.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|iPhone.ActiveCfg = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|iPhone.Build.0 = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|x64.Build.0 = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Debug|x86.Build.0 = Debug|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|Any CPU.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|iPhone.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|iPhone.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|x64.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|x64.Build.0 = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|x86.ActiveCfg = Release|Any CPU
+ {01CCB934-B77F-4681-86C5-AE4FEE648238}.Release|x86.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|Any CPU.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|Any CPU.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|iPhone.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|iPhone.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|iPhoneSimulator.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|x64.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|x64.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|x86.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Ad-Hoc|x86.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|Any CPU.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|Any CPU.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|iPhone.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|iPhone.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|iPhoneSimulator.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|x64.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|x64.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|x86.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.AppStore|x86.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|iPhone.ActiveCfg = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|iPhone.Build.0 = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|x64.ActiveCfg = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|x64.Build.0 = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|x86.ActiveCfg = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Debug|x86.Build.0 = Debug|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|Any CPU.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|iPhone.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|iPhone.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|x64.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|x64.Build.0 = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|x86.ActiveCfg = Release|Any CPU
+ {DA7A2677-0944-481F-A59B-9128FC54FD5F}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -528,6 +612,7 @@ Global
{C77C28DD-A2B2-403C-A907-76184BD5D11E} = {799A84A2-2161-4676-878B-5610E3586137}
{D2486BCF-A218-4181-B1F8-E6D46DCADCDC} = {799A84A2-2161-4676-878B-5610E3586137}
{C6E79ABC-C203-4892-848A-FF99CCE53F8A} = {799A84A2-2161-4676-878B-5610E3586137}
+ {01CCB934-B77F-4681-86C5-AE4FEE648238} = {799A84A2-2161-4676-878B-5610E3586137}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {AB1424F9-871B-444A-9278-18227672889C}
diff --git a/LibVLCSharp/Shared/ApiVersion.cs b/LibVLCSharp/Shared/ApiVersion.cs
index 87caf7a69..f34a32569 100644
--- a/LibVLCSharp/Shared/ApiVersion.cs
+++ b/LibVLCSharp/Shared/ApiVersion.cs
@@ -18,7 +18,7 @@ struct Native
/// a string containing the libvlc version
/// Example: "1.1.0-git The Luggage"
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_get_version")]
internal static extern IntPtr LibVLCVersion();
}
diff --git a/LibVLCSharp/Shared/Core.cs b/LibVLCSharp/Shared/Core.cs
index 49a6da54c..bdf9c3bfc 100644
--- a/LibVLCSharp/Shared/Core.cs
+++ b/LibVLCSharp/Shared/Core.cs
@@ -18,7 +18,7 @@ struct Native
[DllImport("kernel32.dll", SetLastError = true)]
internal static extern IntPtr LoadLibrary(string dllToLoad);
#if ANDROID
- [DllImport("libvlc", EntryPoint = "JNI_OnLoad")]
+ [DllImport(Constants.LibraryName, EntryPoint = "JNI_OnLoad")]
internal static extern int JniOnLoad(IntPtr javaVm, IntPtr reserved = default(IntPtr));
#endif
}
@@ -99,4 +99,13 @@ static void LoadLibvlcLibraries(string libvlccorePath, string libvlcPath)
throw new InvalidOperationException("failed to load libvlc with path " + libvlcPath + ". Aborting...");
}
}
+
+ static class Constants
+ {
+#if IOS
+ internal const string LibraryName = "@rpath/DynamicMobileVLCKit.framework/DynamicMobileVLCKit";
+#else
+ internal const string LibraryName = "libvlc";
+#endif
+ }
}
\ No newline at end of file
diff --git a/LibVLCSharp/Shared/Dialog.cs b/LibVLCSharp/Shared/Dialog.cs
index 567d24f0a..58da686c2 100644
--- a/LibVLCSharp/Shared/Dialog.cs
+++ b/LibVLCSharp/Shared/Dialog.cs
@@ -14,17 +14,17 @@ public class Dialog : IDisposable
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_dialog_post_login")]
internal static extern int LibVLCDialogPostLogin(IntPtr dialogId, string username, string password, bool store);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_dialog_post_action")]
internal static extern int LibVLCDialogPostAction(IntPtr dialogId, int actionIndex);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_dialog_dismiss")]
internal static extern int LibVLCDialogDismiss(IntPtr dialogId);
}
diff --git a/LibVLCSharp/Shared/Equalizer.cs b/LibVLCSharp/Shared/Equalizer.cs
index 280d6c515..30cd547c6 100644
--- a/LibVLCSharp/Shared/Equalizer.cs
+++ b/LibVLCSharp/Shared/Equalizer.cs
@@ -9,57 +9,57 @@ public class Equalizer : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_new")]
internal static extern IntPtr LibVLCAudioEqualizerNew();
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_release")]
internal static extern void LibVLCAudioEqualizerRelease(IntPtr equalizer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_new_from_preset")]
internal static extern IntPtr LibVLCAudioEqualizerNewFromPreset(uint index);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_set_preamp")]
internal static extern int LibVLCAudioEqualizerSetPreamp(IntPtr equalizer, float preamp);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_preamp")]
internal static extern float LibVLCAudioEqualizerGetPreamp(IntPtr equalizer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_set_amp_at_index")]
internal static extern int LibVLCAudioEqualizerSetAmpAtIndex(IntPtr equalizer, float amp, uint band);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_amp_at_index")]
internal static extern float LibVLCAudioEqualizerGetAmpAtIndex(IntPtr equalizer, uint band);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_preset_count")]
internal static extern uint LibVLCAudioEqualizerGetPresetCount();
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_preset_name")]
internal static extern IntPtr LibVLCAudioEqualizerGetPresetName(uint index);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_band_count")]
internal static extern uint LibVLCAudioEqualizerGetBandCount();
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_equalizer_get_band_frequency")]
internal static extern float LibVLCAudioEqualizerGetBandFrequency(uint index);
}
diff --git a/LibVLCSharp/Shared/EventManager.cs b/LibVLCSharp/Shared/EventManager.cs
index 64d6e4d33..84e7e9f3d 100644
--- a/LibVLCSharp/Shared/EventManager.cs
+++ b/LibVLCSharp/Shared/EventManager.cs
@@ -1,4 +1,4 @@
-using System;
+using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Security;
@@ -10,12 +10,12 @@ public abstract class EventManager
public struct Internal
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl, EntryPoint = "libvlc_event_attach")]
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl, EntryPoint = "libvlc_event_attach")]
internal static extern int LibVLCEventAttach(IntPtr eventManager, EventType eventType, EventCallback eventCallback,
IntPtr userData);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl, EntryPoint = "libvlc_event_detach")]
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl, EntryPoint = "libvlc_event_detach")]
internal static extern void LibVLCEventDetach(IntPtr eventManager, EventType eventType, EventCallback eventCallback,
IntPtr userData);
}
diff --git a/LibVLCSharp/Shared/LibVLC.cs b/LibVLCSharp/Shared/LibVLC.cs
index b16780441..851340cee 100644
--- a/LibVLCSharp/Shared/LibVLC.cs
+++ b/LibVLCSharp/Shared/LibVLC.cs
@@ -46,120 +46,120 @@ public override int GetHashCode()
internal struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_new")]
internal static extern IntPtr LibVLCNew(int argc, IntPtr[] argv);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_release")]
internal static extern void LibVLCRelease(IntPtr libVLC);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_add_intf")]
internal static extern int LibVLCAddInterface(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string name);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_set_exit_handler")]
internal static extern void LibVLCSetExitHandler(IntPtr libVLC, IntPtr cb, IntPtr opaque);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_set_user_agent")]
internal static extern void LibVLCSetUserAgent(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string name,
[MarshalAs(UnmanagedType.LPStr)] string http);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_set_app_id")]
internal static extern void LibVLCSetAppId(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string id,
[MarshalAs(UnmanagedType.LPStr)] string version, [MarshalAs(UnmanagedType.LPStr)] string icon);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_log_unset")]
internal static extern void LibVLCLogUnset(IntPtr libVLC);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_log_set_file")]
internal static extern void LibVLCLogSetFile(IntPtr libVLC, IntPtr stream);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
CharSet = CharSet.Ansi, EntryPoint = "libvlc_log_get_context")]
internal static extern void LibVLCLogGetContext(IntPtr ctx, out IntPtr module, out IntPtr file, out UIntPtr line);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_log_set")]
internal static extern void LibVLCLogSet(IntPtr libVLC, LogCallback cb, IntPtr data);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_module_description_list_release")]
internal static extern void LibVLCModuleDescriptionListRelease(IntPtr moduleDescriptionList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_filter_list_get")]
internal static extern IntPtr LibVLCAudioFilterListGet(IntPtr libVLC);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_filter_list_get")]
internal static extern IntPtr LibVLCVideoFilterListGet(IntPtr libVLC);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_list_get")]
internal static extern IntPtr LibVLCAudioOutputListGet(IntPtr libVLC);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_list_release")]
internal static extern void LibVLCAudioOutputListRelease(IntPtr list);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_device_list_get")]
internal static extern IntPtr LibVLCAudioOutputDeviceListGet(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string aout);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_device_list_release")]
internal static extern void LibVLCAudioOutputDeviceListRelease(IntPtr list);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_list_get")]
internal static extern ulong LibVLCMediaDiscovererListGet(IntPtr libVLC, MediaDiscoverer.Category category, ref IntPtr pppServices);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_list_release")]
internal static extern void LibVLCMediaDiscovererListRelease(IntPtr ppServices, ulong count);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_dialog_set_callbacks")]
internal static extern void LibVLCDialogSetCallbacks(IntPtr libVLC, IntPtr callbacks, IntPtr data);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_list_get")]
internal static extern ulong LibVLCRendererDiscovererGetList(IntPtr libVLC, ref IntPtr discovererList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_list_release")]
internal static extern void LibVLCRendererDiscovererReleaseList(IntPtr discovererList, ulong count);
#if ANDROID
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_android_context")]
internal static extern void LibVLCMediaPlayerSetAndroidContext(IntPtr mediaPlayer, IntPtr aWindow);
#endif
diff --git a/LibVLCSharp/Shared/Media.cs b/LibVLCSharp/Shared/Media.cs
index b6ac1b335..4d62848db 100644
--- a/LibVLCSharp/Shared/Media.cs
+++ b/LibVLCSharp/Shared/Media.cs
@@ -16,22 +16,22 @@ public class Media : Internal
internal struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_new_location")]
internal static extern IntPtr LibVLCMediaNewLocation(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string mrl);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_new_path")]
internal static extern IntPtr LibVLCMediaNewPath(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string path);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_new_as_node")]
internal static extern IntPtr LibVLCMediaNewAsNode(IntPtr libVLC, [MarshalAs(UnmanagedType.LPStr)] string name);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_new_fd")]
internal static extern IntPtr LibVLCMediaNewFd(IntPtr libVLC, int fd);
@@ -44,162 +44,162 @@ internal struct Native
///
/// the media descriptor
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_release")]
internal static extern void LibVLCMediaRelease(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_media")]
internal static extern IntPtr LibVLCMediaListMedia(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_new_callbacks")]
internal static extern IntPtr LibVLCMediaNewCallbacks(IntPtr libVLC, IntPtr openCb, IntPtr readCb, IntPtr seekCb, IntPtr closeCb, IntPtr opaque);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_add_option")]
internal static extern void LibVLCMediaAddOption(IntPtr media, [MarshalAs(UnmanagedType.LPStr)] string options);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_add_option_flag")]
internal static extern void LibVLCMediaAddOptionFlag(IntPtr media, [MarshalAs(UnmanagedType.LPStr)] string options, uint flags);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_mrl")]
internal static extern IntPtr LibVLCMediaGetMrl(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_duplicate")]
internal static extern IntPtr LibVLCMediaDuplicate(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_meta")]
internal static extern IntPtr LibVLCMediaGetMeta(IntPtr media, MetadataType metadataType);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_set_meta")]
internal static extern void LibVLCMediaSetMeta(IntPtr media, MetadataType metadataType, [MarshalAs(UnmanagedType.LPStr)] string value);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_save_meta")]
internal static extern int LibVLCMediaSaveMeta(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_state")]
internal static extern VLCState LibVLCMediaGetState(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_event_manager")]
internal static extern IntPtr LibVLCMediaEventManager(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_stats")]
internal static extern int LibVLCMediaGetStats(IntPtr media, out MediaStats statistics);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_duration")]
internal static extern long LibVLCMediaGetDuration(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_parse")]
internal static extern void LibVLCMediaParse(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_parse_async")]
internal static extern void LibVLCMediaParseAsync(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_is_parsed")]
internal static extern int LibVLCMediaIsParsed(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_parse_with_options")]
internal static extern int LibVLCMediaParseWithOptions(IntPtr media, MediaParseOptions mediaParseOptions, int timeout);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_parsed_status")]
internal static extern MediaParsedStatus LibVLCMediaGetParsedStatus(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_parse_stop")]
internal static extern void LibVLCMediaParseStop(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_set_user_data")]
internal static extern void LibVLCMediaSetUserData(IntPtr media, IntPtr userData);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_user_data")]
internal static extern IntPtr LibVLCMediaGetUserData(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_tracks_get")]
internal static extern uint LibVLCMediaTracksGet(IntPtr media, ref IntPtr tracksPtr);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_tracks_release")]
internal static extern void LibVLCMediaTracksRelease(IntPtr tracks, uint count);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_subitems")]
internal static extern IntPtr LibVLCMediaSubitems(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_type")]
internal static extern MediaType LibVLCMediaGetType(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_slaves_add")]
internal static extern int LibVLCMediaAddSlaves(IntPtr media, MediaSlaveType slaveType, uint priority, [MarshalAs(UnmanagedType.LPStr)] string uri);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_slaves_clear")]
internal static extern void LibVLCMediaClearSlaves(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_slaves_get")]
internal static extern uint LibVLCMediaGetSlaves(IntPtr media, ref IntPtr slaves);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_slaves_release")]
internal static extern void LibVLCMediaReleaseSlaves(IntPtr slaves, uint count);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_retain")]
internal static extern void LibVLCMediaRetain(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_get_codec_description")]
internal static extern string LibvlcMediaGetCodecDescription(TrackType type, uint codec);
}
diff --git a/LibVLCSharp/Shared/MediaDiscoverer.cs b/LibVLCSharp/Shared/MediaDiscoverer.cs
index 92f61a322..254338c41 100644
--- a/LibVLCSharp/Shared/MediaDiscoverer.cs
+++ b/LibVLCSharp/Shared/MediaDiscoverer.cs
@@ -15,42 +15,42 @@ public class MediaDiscoverer : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_new")]
internal static extern IntPtr LibVLCMediaDiscovererNew(IntPtr libvlc, [MarshalAs(UnmanagedType.LPStr)] string name);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_start")]
internal static extern int LibVLCMediaDiscovererStart(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_stop")]
internal static extern void LibVLCMediaDiscovererStop(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_release")]
internal static extern void LibVLCMediaDiscovererRelease(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_localized_name")]
internal static extern IntPtr LibVLCMediaDiscovererLocalizedName(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_event_manager")]
internal static extern IntPtr LibVLCMediaDiscovererEventManager(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_is_running")]
internal static extern int LibVLCMediaDiscovererIsRunning(IntPtr mediaDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_media_list")]
internal static extern IntPtr LibVLCMediaDiscovererMediaList(IntPtr discovererMediaList);
}
diff --git a/LibVLCSharp/Shared/MediaList.cs b/LibVLCSharp/Shared/MediaList.cs
index f583a9f9c..7eb771720 100644
--- a/LibVLCSharp/Shared/MediaList.cs
+++ b/LibVLCSharp/Shared/MediaList.cs
@@ -13,82 +13,82 @@ public class MediaList : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_subitems")]
internal static extern IntPtr LibVLCMediaSubitems(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_new")]
internal static extern IntPtr LibVLCMediaListNew(IntPtr instance);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_release")]
internal static extern void LibVLCMediaListRelease(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_discoverer_media_list")]
internal static extern IntPtr LibVLCMediaDiscovererMediaList(IntPtr discovererMediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_library_media_list")]
internal static extern IntPtr LibVLCMediaLibraryMediaList(IntPtr libraryMediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_set_media")]
internal static extern void LibVLCMediaListSetMedia(IntPtr mediaList, IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_add_media")]
internal static extern int LibVLCMediaListAddMedia(IntPtr mediaList, IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_insert_media")]
internal static extern int LibVLCMediaListInsertMedia(IntPtr mediaList, IntPtr media, int positionIndex);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_remove_index")]
internal static extern int LibVLCMediaListRemoveIndex(IntPtr mediaList, int positionIndex);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_count")]
internal static extern int LibVLCMediaListCount(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_item_at_index")]
internal static extern IntPtr LibVLCMediaListItemAtIndex(IntPtr mediaList, int positionIndex);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_index_of_item")]
internal static extern int LibVLCMediaListIndexOfItem(IntPtr mediaList, IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_is_readonly")]
internal static extern int LibVLCMediaListIsReadonly(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_lock")]
internal static extern void LibVLCMediaListLock(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_unlock")]
internal static extern void LibVLCMediaListUnlock(IntPtr mediaList);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_list_event_manager")]
internal static extern IntPtr LibVLCMediaListEventManager(IntPtr mediaList);
}
diff --git a/LibVLCSharp/Shared/MediaPlayer.cs b/LibVLCSharp/Shared/MediaPlayer.cs
index 90aad6e5d..5006c5270 100644
--- a/LibVLCSharp/Shared/MediaPlayer.cs
+++ b/LibVLCSharp/Shared/MediaPlayer.cs
@@ -11,626 +11,626 @@ public class MediaPlayer : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_new")]
internal static extern IntPtr LibVLCMediaPlayerNew(IntPtr libvlc);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_release")]
internal static extern void LibVLCMediaPlayerRelease(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_new_from_media")]
internal static extern IntPtr LibVLCMediaPlayerNewFromMedia(IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_media")]
internal static extern void LibVLCMediaPlayerSetMedia(IntPtr mediaPlayer, IntPtr media);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_media")]
internal static extern IntPtr LibVLCMediaPlayerGetMedia(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_event_manager")]
internal static extern IntPtr LibVLCMediaPlayerEventManager(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_is_playing")]
internal static extern int LibVLCMediaPlayerIsPlaying(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_play")]
internal static extern int LibVLCMediaPlayerPlay(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_pause")]
internal static extern void LibVLCMediaPlayerSetPause(IntPtr mediaPlayer, bool pause);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_pause")]
internal static extern void LibVLCMediaPlayerPause(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_stop")]
internal static extern void LibVLCMediaPlayerStop(IntPtr mediaPlayer);
#if COCOA
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_nsobject")]
internal static extern void LibVLCMediaPlayerSetNsobject(IntPtr mediaPlayer, IntPtr drawable);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_nsobject")]
internal static extern IntPtr LibVLCMediaPlayerGetNsobject(IntPtr mediaPlayer);
#endif
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_xwindow")]
internal static extern void LibVLCMediaPlayerSetXwindow(IntPtr mediaPlayer, uint drawable);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_xwindow")]
internal static extern uint LibVLCMediaPlayerGetXwindow(IntPtr mediaPlayer);
#if WINDOWS
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_hwnd")]
internal static extern void LibVLCMediaPlayerSetHwnd(IntPtr mediaPlayer, IntPtr drawable);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_hwnd")]
internal static extern IntPtr LibVLCMediaPlayerGetHwnd(IntPtr mediaPlayer);
#endif
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_length")]
internal static extern long LibVLCMediaPlayerGetLength(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_time")]
internal static extern long LibVLCMediaPlayerGetTime(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_time")]
internal static extern void LibVLCMediaPlayerSetTime(IntPtr mediaPlayer, long time);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_position")]
internal static extern float LibVLCMediaPlayerGetPosition(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_position")]
internal static extern void LibVLCMediaPlayerSetPosition(IntPtr mediaPlayer, float position);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_chapter")]
internal static extern void LibVLCMediaPlayerSetChapter(IntPtr mediaPlayer, int chapter);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_chapter")]
internal static extern int LibVLCMediaPlayerGetChapter(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_chapter_count")]
internal static extern int LibVLCMediaPlayerGetChapterCount(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_will_play")]
internal static extern int LibVLCMediaPlayerWillPlay(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_chapter_count_for_title")]
internal static extern int LibVLCMediaPlayerGetChapterCountForTitle(IntPtr mediaPlayer, int title);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_title")]
internal static extern void LibVLCMediaPlayerSetTitle(IntPtr mediaPlayer, int title);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_title")]
internal static extern int LibVLCMediaPlayerGetTitle(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_title_count")]
internal static extern int LibVLCMediaPlayerGetTitleCount(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_previous_chapter")]
internal static extern void LibVLCMediaPlayerPreviousChapter(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_next_chapter")]
internal static extern void LibVLCMediaPlayerNextChapter(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_rate")]
internal static extern float LibVLCMediaPlayerGetRate(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_rate")]
internal static extern int LibVLCMediaPlayerSetRate(IntPtr mediaPlayer, float rate);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_state")]
internal static extern VLCState LibVLCMediaPlayerGetState(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_fps")]
internal static extern float LibVLCMediaPlayerGetFps(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_has_vout")]
internal static extern uint LibVLCMediaPlayerHasVout(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_is_seekable")]
internal static extern int LibVLCMediaPlayerIsSeekable(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_can_pause")]
internal static extern int LibVLCMediaPlayerCanPause(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_program_scrambled")]
internal static extern int LibVLCMediaPlayerProgramScrambled(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_next_frame")]
internal static extern void LibVLCMediaPlayerNextFrame(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_navigate")]
internal static extern void LibVLCMediaPlayerNavigate(IntPtr mediaPlayer, uint navigate);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_video_title_display")]
internal static extern void LibVLCMediaPlayerSetVideoTitleDisplay(IntPtr mediaPlayer, Position position, uint timeout);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_toggle_fullscreen")]
internal static extern void LibVLCToggleFullscreen(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_set_fullscreen")]
internal static extern void LibVLCSetFullscreen(IntPtr mediaPlayer, int fullscreen);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_get_fullscreen")]
internal static extern int LibVLCGetFullscreen(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_toggle_teletext")]
internal static extern void LibVLCToggleTeletext(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_equalizer")]
internal static extern int LibVLCMediaPlayerSetEqualizer(IntPtr mediaPlayer, IntPtr equalizer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_callbacks")]
internal static extern void LibVLCAudioSetCallbacks(IntPtr mediaPlayer, LibVLCAudioPlayCb play, LibVLCAudioPauseCb pause,
LibVLCAudioResumeCb resume, LibVLCAudioFlushCb flush, LibVLCAudioDrainCb drain, IntPtr opaque);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_volume_callback")]
internal static extern void LibVLCAudioSetVolumeCallback(IntPtr mediaPlayer, LibVLCVolumeCb volumeCallback);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_format_callbacks")]
internal static extern void LibVLCAudioSetFormatCallbacks(IntPtr mediaPlayer, LibVLCAudioSetupCb setup, LibVLCAudioCleanupCb cleanup);
// TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_format")]
internal static extern void LibVLCAudioSetFormat(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string format,
uint rate, uint channels);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_device_enum")]
internal static extern IntPtr LibVLCAudioOutputDeviceEnum(IntPtr mediaPlayer);
// TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_device_set")]
internal static extern void LibVLCAudioOutputDeviceSet(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string module,
[MarshalAs(UnmanagedType.LPStr)] string deviceId);
// TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_set")]
internal static extern int LibVLCAudioOutputSet(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string name);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_toggle_mute")]
internal static extern void LibVLCAudioToggleMute(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_mute")]
internal static extern int LibVLCAudioGetMute(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_mute")]
internal static extern void LibVLCAudioSetMute(IntPtr mediaPlayer, int status);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_volume")]
internal static extern int LibVLCAudioGetVolume(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_volume")]
internal static extern int LibVLCAudioSetVolume(IntPtr mediaPlayer, int volume);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_track_count")]
internal static extern int LibVLCAudioGetTrackCount(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_track_description")]
internal static extern IntPtr LibVLCAudioGetTrackDescription(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_track")]
internal static extern int LibVLCAudioGetTrack(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_track")]
internal static extern int LibVLCAudioSetTrack(IntPtr mediaPlayer, int track);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_channel")]
internal static extern int LibVLCAudioGetChannel(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_channel")]
internal static extern int LibVLCAudioSetChannel(IntPtr mediaPlayer, int channel);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_get_delay")]
internal static extern long LibVLCAudioGetDelay(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_set_delay")]
internal static extern int LibVLCAudioSetDelay(IntPtr mediaPlayer, long delay);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_callbacks")]
internal static extern void LibVLCVideoSetCallbacks(IntPtr mediaPlayer, LibVLCVideoLockCb lockCallback,
LibVLCVideoUnlockCb unlock, LibVLCVideoDisplayCb display, IntPtr opaque);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_format")]
internal static extern void LibVLCVideoSetFormat(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string chroma,
uint width, uint height, uint pitch);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_format_callbacks")]
internal static extern void LibVLCVideoSetFormatCallbacks(IntPtr mediaPlayer, LibVLCVideoFormatCb setup,
LibVLCVideoCleanupCb cleanup);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_key_input")]
internal static extern void LibVLCVideoSetKeyInput(IntPtr mediaPlayer, int enable);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_mouse_input")]
internal static extern void LibVLCVideoSetMouseInput(IntPtr mediaPlayer, int enable);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_size")]
internal static extern unsafe int LibVLCVideoGetSize(IntPtr mediaPlayer, uint num, uint* px, uint* py);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_cursor")]
internal static extern unsafe int LibVLCVideoGetCursor(IntPtr mediaPlayer, uint num, int* px, int* py);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_scale")]
internal static extern float LibVLCVideoGetScale(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_scale")]
internal static extern void LibVLCVideoSetScale(IntPtr mediaPlayer, float factor);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_aspect_ratio")]
internal static extern string LibVLCVideoGetAspectRatio(IntPtr mediaPlayer);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_aspect_ratio")]
internal static extern void LibVLCVideoSetAspectRatio(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string aspect);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_spu")]
internal static extern int LibVLCVideoGetSpu(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_spu_count")]
internal static extern int LibVLCVideoGetSpuCount(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_spu_description")]
internal static extern IntPtr LibVLCVideoGetSpuDescription(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_spu")]
internal static extern int LibVLCVideoSetSpu(IntPtr mediaPlayer, int spu);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_subtitle_file")]
internal static extern int LibVLCVideoSetSubtitleFile(IntPtr mediaPlayer,
[MarshalAs(UnmanagedType.LPStr)] string subtitle);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_spu_delay")]
internal static extern long LibVLCVideoGetSpuDelay(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_spu_delay")]
internal static extern int LibVLCVideoSetSpuDelay(IntPtr mediaPlayer, long delay);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_title_description")]
internal static extern IntPtr LibVLCVideoGetTitleDescription(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_full_title_descriptions")]
internal static extern int LibVLCMediaPlayerGetFullTitleDescriptions(IntPtr mediaPlayer, IntPtr titles);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_chapter_description")]
internal static extern IntPtr LibVLCVideoGetChapterDescription(IntPtr mediaPlayer,
int title);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_title_descriptions_release")]
internal static extern void LibVLCTitleDescriptionsRelease(IntPtr titles, uint count);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_get_full_chapter_descriptions")]
internal static extern int LibVLCMediaPlayerGetFullChapterDescriptions(IntPtr mediaPlayer, int titleIndex, ref IntPtr chapters);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_chapter_descriptions_release")]
internal static extern void LibVLCChapterDescriptionsRelease(IntPtr chapters, uint count);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_crop_geometry")]
internal static extern string LibVLCVideoGetCropGeometry(IntPtr mediaPlayer);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_crop_geometry")]
internal static extern void LibVLCVideoSetCropGeometry(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string geometry);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_teletext")]
internal static extern int LibVLCVideoGetTeletext(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_teletext")]
internal static extern void LibVLCVideoSetTeletext(IntPtr mediaPlayer, int page);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_track_count")]
internal static extern int LibVLCVideoGetTrackCount(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_track_description")]
internal static extern IntPtr LibVLCVideoGetTrackDescription(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_track")]
internal static extern int LibVLCVideoGetTrack(IntPtr mediaPlayer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_track")]
internal static extern int LibVLCVideoSetTrack(IntPtr mediaPlayer, int track);
// TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_take_snapshot")]
internal static extern int LibVLCVideoTakeSnapshot(IntPtr mediaPlayer, uint num,
[MarshalAs(UnmanagedType.LPStr)] string filepath, uint width, uint height);
// TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_deinterlace")]
internal static extern void LibVLCVideoSetDeinterlace(IntPtr mediaPlayer, [MarshalAs(UnmanagedType.LPStr)] string mode);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_marquee_int")]
internal static extern int LibVLCVideoGetMarqueeInt(IntPtr mediaPlayer, VideoMarqueeOption option);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_marquee_string")]
internal static extern string LibVLCVideoGetMarqueeString(IntPtr mediaPlayer, VideoMarqueeOption option);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_marquee_int")]
internal static extern void LibVLCVideoSetMarqueeInt(IntPtr mediaPlayer, VideoMarqueeOption option, int marqueeValue);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_marquee_string")]
internal static extern void LibVLCVideoSetMarqueeString(IntPtr mediaPlayer, VideoMarqueeOption option, [MarshalAs(UnmanagedType.LPStr)] string marqueeValue);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_logo_int")]
internal static extern int LibVLCVideoGetLogoInt(IntPtr mediaPlayer, VideoLogoOption option);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_logo_int")]
internal static extern void LibVLCVideoSetLogoInt(IntPtr mediaPlayer, VideoLogoOption option, int value);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_logo_string")]
internal static extern void LibVLCVideoSetLogoString(IntPtr mediaPlayer, VideoLogoOption option,
[MarshalAs(UnmanagedType.LPStr)] string logoOptionValue);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_adjust_int")]
internal static extern int LibVLCVideoGetAdjustInt(IntPtr mediaPlayer, VideoAdjustOption option);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_adjust_int")]
internal static extern void LibVLCVideoSetAdjustInt(IntPtr mediaPlayer, VideoAdjustOption option, int value);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_get_adjust_float")]
internal static extern float LibVLCVideoGetAdjustFloat(IntPtr mediaPlayer, VideoAdjustOption option);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_set_adjust_float")]
internal static extern void LibVLCVideoSetAdjustFloat(IntPtr mediaPlayer, VideoAdjustOption option, float value);
//TODO: UTF8
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_add_slave")]
internal static extern int LibVLCMediaPlayerAddSlave(IntPtr mediaPlayer, MediaSlaveType mediaSlaveType,
[MarshalAs(UnmanagedType.LPStr)] string uri, bool selectWhenloaded);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_video_update_viewpoint")]
internal static extern int LibVLCVideoUpdateViewpoint(IntPtr mediaPlayer, VideoViewpoint viewpoint, bool absolute);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_track_description_list_release")]
internal static extern void LibVLCTrackDescriptionListRelease(IntPtr trackDescription);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_audio_output_device_list_release")]
internal static extern void LibVLCAudioOutputDeviceListRelease(IntPtr list);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_renderer")]
internal static extern int LibVLCMediaPlayerSetRenderer(IntPtr mediaplayer, IntPtr renderItem);
#if ANDROID
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_media_player_set_android_context")]
internal static extern void LibVLCMediaPlayerSetAndroidContext(IntPtr mediaPlayer, IntPtr aWindow);
#endif
}
-
+
MediaPlayerEventManager _eventManager;
/// Create an empty Media Player object
diff --git a/LibVLCSharp/Shared/RendererDiscoverer.cs b/LibVLCSharp/Shared/RendererDiscoverer.cs
index 497d61ff8..dadc15ead 100644
--- a/LibVLCSharp/Shared/RendererDiscoverer.cs
+++ b/LibVLCSharp/Shared/RendererDiscoverer.cs
@@ -9,27 +9,27 @@ public class RendererDiscoverer : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_new")]
internal static extern IntPtr LibVLCRendererDiscovererNew(IntPtr libvlc, string name);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_release")]
internal static extern void LibVLCRendererDiscovererRelease(IntPtr rendererDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_start")]
internal static extern int LibVLCRendererDiscovererStart(IntPtr rendererDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_stop")]
internal static extern void LibVLCRendererDiscovererStop(IntPtr rendererDiscoverer);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_discoverer_event_manager")]
internal static extern IntPtr LibVLCRendererDiscovererEventManager(IntPtr rendererDiscoverer);
}
@@ -69,32 +69,32 @@ public class RendererItem : Internal
struct Native
{
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_name")]
internal static extern IntPtr LibVLCRendererItemName(IntPtr rendererItem);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_release")]
internal static extern void LibVLCRendererItemRelease(IntPtr rendererItem);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_hold")]
internal static extern IntPtr LibVLCRendererItemHold(IntPtr rendererItem);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_type")]
internal static extern IntPtr LibVLCRendererItemType(IntPtr rendererItem);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_icon_uri")]
internal static extern IntPtr LibVLCRendererItemIconUri(IntPtr rendererItem);
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "libvlc_renderer_item_flags")]
internal static extern int LibVLCRendererItemFlags(IntPtr rendererItem);
}
diff --git a/LibVLCSharp/Shared/Structures/AudioOutputDescription.cs b/LibVLCSharp/Shared/Structures/AudioOutputDescription.cs
index 06bff0ba7..5b50465f2 100644
--- a/LibVLCSharp/Shared/Structures/AudioOutputDescription.cs
+++ b/LibVLCSharp/Shared/Structures/AudioOutputDescription.cs
@@ -20,7 +20,7 @@ public partial struct Internal
internal IntPtr p_next;
[SuppressUnmanagedCodeSecurity]
- [DllImport("libvlc", CallingConvention = CallingConvention.Cdecl,
+ [DllImport(Constants.LibraryName, CallingConvention = CallingConvention.Cdecl,
EntryPoint = "??0libvlc_audio_output_t@@QEAA@AEBU0@@Z")]
internal static extern global::System.IntPtr cctor(global::System.IntPtr instance, global::System.IntPtr _0);
diff --git a/LibVLCSharp/Shared/Structures/ModuleDescription.cs b/LibVLCSharp/Shared/Structures/ModuleDescription.cs
index 33c7ff386..09d6451ad 100644
--- a/LibVLCSharp/Shared/Structures/ModuleDescription.cs
+++ b/LibVLCSharp/Shared/Structures/ModuleDescription.cs
@@ -30,7 +30,7 @@ public struct Internal
internal IntPtr p_next;
//[SuppressUnmanagedCodeSecurity]
- //[DllImport("libvlc", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl,
+ //[DllImport(Constants.LibraryName, CallingConvention = global::System.Runtime.InteropServices.CallingConvention.Cdecl,
// EntryPoint="??0libvlc_module_description_t@@QEAA@AEBU0@@Z")]
//internal static extern global::System.IntPtr cctor(global::System.IntPtr instance, global::System.IntPtr _0);