Table of Contents

Class MediaLibrary

Namespace
Microsoft.Xna.Framework.Media
Assembly
MonoGame.Framework.dll
public class MediaLibrary : IDisposable
Inheritance
MediaLibrary
Implements
Inherited Members

Constructors

MediaLibrary()

public MediaLibrary()

MediaLibrary(MediaSource)

public MediaLibrary(MediaSource mediaSource)

Parameters

mediaSource MediaSource

Properties

Albums

public AlbumCollection Albums { get; }

Property Value

AlbumCollection

IsDisposed

public bool IsDisposed { get; }

Property Value

bool

MediaSource

public MediaSource MediaSource { get; }

Property Value

MediaSource

Songs

public SongCollection Songs { get; }

Property Value

SongCollection

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public void Dispose()

Load(Action<int>)

Load the contents of MediaLibrary. This blocking call might take up to a few minutes depending on the platform and the size of the user's music library.

public void Load(Action<int> progressCallback = null)

Parameters

progressCallback Action<int>

Callback that reports back the progress of the music library loading in percents (0-100).