audio - How to play amr file in Windows Phone 8? -


from read, wp8 support amr

however, don't know how play it.

  1. when using soundeffect, can't hear anything, maybe it's because soundeffect supports wav only. asked here.
  2. i don't want use backgroundaudioplayer or mediaplayerlauncher, overkill

is there workaround play amr soundeffect, or there better api play ?

p/s: amr file record using wp8 api

you can play them using mediaelement. add mediaelement xaml file. set source opened file. like:

using(isolatedstoragefilestream stream = appstorage.openfile(mfilename, filemode.open)) {      mmediaplayer.setsource(stream); } 

then when want play audio call:

mmediaplayer.play(); 

Comments