I am trying to play a music from the phone song collection.
Does the sound effect properties support playing from the song collection?
Previously i used the media player to play the song but i want to set the music to not pause-able.
Code for sound effect : SoundEffect effect; SoundEffectInstance instance;
effect = SoundEffect.FromStream(ml.Songs[songSelectedIndex]);
instance = effect.CreateInstance();
instance.IsLooped = true;
instance.Volume = 1.0f;
instance.Pitch = 1.0f;
instance.Play();
Code for media library :
using (var ml = new MediaLibrary())
{
FrameworkDispatcher.Update();
MediaPlayer.Play(ml.Songs[songSelectedIndex]);
MediaPlayer.IsRepeating = true;
}