從GitHub使用最新的Monogame源碼06/03/13,我的遊戲在ipad/iPhone模擬器(在VMWare OSX上)中運行時播放聲音效果很好,但是當我將它部署/調試到iPad 4時,根本沒有聲音。在應用程序輸出窗口中,偶爾會看到無法獲取緩衝區屬性:執行應播放聲音的遊戲操作時。當聲音在模擬器中播放時,我假設我已經使用monogame聲音處理器正確編譯了xnbs。 fwiw我編譯這些使用Visual Studio 2012 Windows Phone遊戲庫項目。繼承人如何在遊戲加載時播放我的介紹音。聲音沒有在iOS設備上播放,但在iOS模擬器中工作
public override void Activate(bool instancePreserved)
{
if (!instancePreserved)
{
if (content == null)
content = new ContentManager(ScreenManager.Game.Services, "Content");
backgroundTexture = content.Load<Texture2D>(MyGame.Settings.Assets.SplashBackground);
introSound = content.Load<SoundEffect>(MyGame.Settings.Assets.IntroSound);
}
introSound.CreateInstance().Play();
}
任何人都知道會導致這種情況以及如何解決它?
是文件.wav的格式? – 2013-03-08 21:00:44
是的,它在它被內容管道轉換爲xnb之前。我對xnb中的內容知之甚少。 – mdev 2013-03-09 18:23:30