Difference
between MediaPlayer and MediaElement
- S.NoMediaPlayerMediaElement
1 MediaPlayer has no visual interface and not suitable to display videos. MediaElement has got visual interface and can easily display videos using its built in properties. 2It cannot be placed on the XAML designer.It is designed for XAML use and can be placed on the XAML designer.3It provides Media PlayBack for drawings.It does not provide Media PlayBack for drawings.
MediaPlayer
player = new MediaPlayer();
player.Open(new Uri("c:\\intro.wmv", UriKind.Relative));
VideoDrawing aVideoDrawing = new VideoDrawing();
aVideoDrawing.Rect = new Rect(0, 0, 100, 100);
aVideoDrawing.Player = player;
splayer.Play();
player.Open(new Uri("c:\\intro.wmv", UriKind.Relative));
VideoDrawing aVideoDrawing = new VideoDrawing();
aVideoDrawing.Rect = new Rect(0, 0, 100, 100);
aVideoDrawing.Player = player;
splayer.Play();
No comments:
Post a Comment