C# Class ManagedBass.MediaPlayer

A Reusable Channel which can Load files like a Player.

MediaPlayer is perfect for UIs, as it implements INotifyPropertyChanged.

Also, unlike normal, Properties/Effects/DSP set on a MediaPlayer persist through subsequent loads.

Inheritance: INotifyPropertyChanged, IDisposable
Afficher le fichier Open project: ManagedBass/ManagedBass Class Usage Examples

Private Properties

Свойство Type Description
GetSyncProcedure SyncProcedure
MediaPlayer ManagedBass.Tags
OnStateChanged void

Méthodes publiques

Méthode Description
Dispose ( ) : void

Frees all resources used by the player.

Load ( string FileName ) : bool

Loads a file into the player.

Pause ( ) : bool

Pauses the Channel Playback.

Play ( ) : bool

Starts the Channel Playback.

Stop ( ) : bool

Stops the Channel Playback.

Difference from Bass.ChannelStop: Playback is restarted when Play is called.

Méthodes protégées

Méthode Description
InitProperties ( ) : void

Initializes Properties on every call to Load.

OnLoad ( string FileName ) : int

Override this method for custom loading procedure.

OnPropertyChanged ( [ PropertyName = null ) : void

Fires the PropertyChanged event.

Private Methods

Méthode Description
GetSyncProcedure ( System.Action Handler ) : SyncProcedure
MediaPlayer ( ) : ManagedBass.Tags
OnStateChanged ( ) : void

Method Details

Dispose() public méthode

Frees all resources used by the player.
public Dispose ( ) : void
Résultat void

InitProperties() protected méthode

Initializes Properties on every call to Load.
protected InitProperties ( ) : void
Résultat void

Load() public méthode

Loads a file into the player.
public Load ( string FileName ) : bool
FileName string Path to the file to Load.
Résultat bool

OnLoad() protected méthode

Override this method for custom loading procedure.
protected OnLoad ( string FileName ) : int
FileName string Path to the File to Load.
Résultat int

OnPropertyChanged() protected méthode

Fires the PropertyChanged event.
protected OnPropertyChanged ( [ PropertyName = null ) : void
PropertyName [
Résultat void

Pause() public méthode

Pauses the Channel Playback.
public Pause ( ) : bool
Résultat bool

Play() public méthode

Starts the Channel Playback.
public Play ( ) : bool
Résultat bool

Stop() public méthode

Stops the Channel Playback.
Difference from Bass.ChannelStop: Playback is restarted when Play is called.
public Stop ( ) : bool
Résultat bool