[Proposal] MediaElement
See original GitHub issueMediaElement
- Proposed
- Prototype: Not Started
- Implementation: Not Started
- iOS Support
- Android Support
- macOS Support
- Windows Support
- Unit Tests: Not Started
- Sample: Not Started
- Documentation: Not Started
Summary
MediaElement is a view for playing video and audio. Media that’s supported by the underlying platform can be played from the following sources:
- The web, using a URI (HTTP or HTTPS).
- A resource embedded in the platform application, using the ms-appx:/// URI scheme.
- Files that come from the app’s local and temporary data folders, using the ms-appdata:/// URI scheme. The device’s library.
Detailed Design
MediaElement.shared.cs
public class MediaElement : View, IMediaElementController
{
public static readonly BindableProperty AspectProperty;
public static readonly BindableProperty AutoPlayProperty;
public static readonly BindableProperty BufferingProgressProperty;
public static readonly BindableProperty CurrentStateProperty;
public static readonly BindableProperty DurationProperty;
public static readonly BindableProperty IsLoopingProperty;
public static readonly BindableProperty KeepScreenOnProperty;
public static readonly BindableProperty PositionProperty;
public static readonly BindableProperty ShowsPlaybackControlsProperty;
public static readonly BindableProperty SourceProperty;
public static readonly BindableProperty VideoHeightProperty;
public static readonly BindableProperty VideoWidthProperty;
public static readonly BindableProperty VolumeProperty;
public static readonly BindableProperty SpeedProperty;
public double BufferingProgress { get; }
public bool CanSeek { get; }
public MediaElementState CurrentState { get; }
public TimeSpan? Duration { get; }
public int VideoHeight { get; }
public int VideoWidth { get;}
public Aspect Aspect { get; set; }
public bool AutoPlay { get; set; }
public bool IsLooping { get; set; }
public bool KeepScreenOn { get; set; }
public bool ShowsPlaybackControls { get; set; }
public TimeSpan Position { get; set; }
[Forms.TypeConverter(typeof(MediaSourceConverter))]
public MediaSource? Source { get; set; }
public double Volume { get; set; }
public double Speed { get; set; }
public event EventHandler? MediaEnded;
public event EventHandler? MediaFailed;
public event EventHandler? MediaOpened;
public event EventHandler? SeekCompleted;
public void Play() ;
public void Pause();
public void Stop();
}
Usage Syntax
Issue Analytics
- State:
- Created 2 years ago
- Reactions:14
- Comments:52 (18 by maintainers)
Top Results From Across the Web
MediaElement proposal for animation & interactive video
MediaElement proposal for animation & interactive video · IDLE Champions - visual formations and effects guide · TuneMingo Review & Demo - A.I...
Read more >Media Multitrack Change Proposal - HTML accessibility ...
Synchronize separate media elements through attributes. SUMMARY. This is a change proposal for ISSUE-152, introducing markup, an API, and rendering ...
Read more >MediaElement Class (System.Windows.Controls)
Represents a control that contains audio and/or video.
Read more >Blog | Liqvid
MediaElement is a proposed interface for general-purpose imperative animation, patterned after HTMLMediaElement .
Read more >MediaElement Player style breaks for logged in users
MediaElement Video/Audio player breaks when logged in as a user or admin. It breaks for both ... Proposed resolution. Remaining tasks.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The
MediaElement
needs some love, I think what is there now is pretty stable, lots of room for improvement though. But I think a control to play media should actually be part of .NET MAUI in-the-box. While it’s not that, I think we should definitely have it in the Toolkit to provide something, hopefully build it out and move it over to .NET MAUI as a mature control.Removing the
blocked
label now that Xam.Plugins.Android.ExoPlayer has added support fornet6.0-android