I updated Xamarin, Xcode and MG to latest versions this weekend and tried to make a new build of my game. But an error keeps showing up on both emulators and test iOS devices:
In MonoGame.Framework/Graphics/DxtUtil.cs, line 339:
byte alpha0 = imageReader.ReadByte();
“System.IO.EndOfStreamException has been thrown
Failed to read past end of stream.”
Below is the call stack:
System.IO.BinaryReader.ReadByte () in /Users/builder/data/lanes/2077/d230615b/source/maccore/_build/Library/Frameworks/Xamarin.iOS.framework/Versions/git/src/mono/mcs/class/corlib/System.IO/BinaryReader.cs:313
Microsoft.Xna.Framework.Graphics.DxtUtil.DecompressDxt5Block (imageReader={System.IO.BinaryReader}, x=0, y=256, blockCountX=512, width=2048, height=2048, imageData={byte[16777216]}) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Graphics/DxtUtil.cs:339
Microsoft.Xna.Framework.Graphics.DxtUtil.DecompressDxt5 (imageStream={System.IO.MemoryStream}, width=2048, height=2048) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Graphics/DxtUtil.cs:329
Microsoft.Xna.Framework.Graphics.DxtUtil.DecompressDxt5 (imageData={byte[2097152]}, width=2048, height=2048) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Graphics/DxtUtil.cs:313
Microsoft.Xna.Framework.Content.Texture2DReader.Read (reader={Microsoft.Xna.Framework.Content.ContentReader}, existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReaders/Texture2DReader.cs:133
Microsoft.Xna.Framework.Content.ContentTypeReader<Microsoft.Xna.Framework.Graphics.Texture2D>.Read (input={Microsoft.Xna.Framework.Content.ContentReader}, existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentTypeReader.cs:181
Microsoft.Xna.Framework.Content.ContentReader.InnerReadObject<Microsoft.Xna.Framework.Graphics.Texture2D> (existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:175
Microsoft.Xna.Framework.Content.ContentReader.ReadObject<Microsoft.Xna.Framework.Graphics.Texture2D> (existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:162
Microsoft.Xna.Framework.Content.ContentReader.ReadObject<Microsoft.Xna.Framework.Graphics.Texture2D> () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:150
Microsoft.Xna.Framework.Content.SpriteFontReader.Read (input={Microsoft.Xna.Framework.Content.ContentReader}, existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReaders/SpriteFontReader.cs:74
Microsoft.Xna.Framework.Content.ContentTypeReader<Microsoft.Xna.Framework.Graphics.SpriteFont>.Read (input={Microsoft.Xna.Framework.Content.ContentReader}, existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentTypeReader.cs:181
Microsoft.Xna.Framework.Content.ContentReader.InnerReadObject<Microsoft.Xna.Framework.Graphics.SpriteFont> (existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:175
Microsoft.Xna.Framework.Content.ContentReader.ReadObject<Microsoft.Xna.Framework.Graphics.SpriteFont> (existingInstance=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:162
Microsoft.Xna.Framework.Content.ContentReader.ReadObject<Microsoft.Xna.Framework.Graphics.SpriteFont> () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:150
Microsoft.Xna.Framework.Content.ContentReader.ReadAsset<Microsoft.Xna.Framework.Graphics.SpriteFont> () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentReader.cs:72
Microsoft.Xna.Framework.Content.ContentManager.ReadAsset<Microsoft.Xna.Framework.Graphics.SpriteFont> (assetName="Fonts/titleFont", recordDisposableObject=(null)) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentManager.cs:294
Microsoft.Xna.Framework.Content.ContentManager.Load<Microsoft.Xna.Framework.Graphics.SpriteFont> (assetName="Fonts/titleFont") in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Content/ContentManager.cs:209
MyGame.ScreenManager.LoadContent () in /Users/Greyp/Desktop/MyGame/Game/ScreenManager/ScreenManager.cs:610
Microsoft.Xna.Framework.DrawableGameComponent.Initialize () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/DrawableGameComponent.cs:63
MyGame.ScreenManager.Initialize () in /Users/Greyp/Desktop/MyGame/Game/ScreenManager/ScreenManager.cs:594
Microsoft.Xna.Framework.Game.InitializeExistingComponents () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Game.cs:727
Microsoft.Xna.Framework.Game.Initialize () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Game.cs:532
MyGame.GameStateManagementGame.Initialize () in /Users/Greyp/Desktop/MyGame/Game/Program.cs:136
Microsoft.Xna.Framework.Game.DoInitialize () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Game.cs:679
Microsoft.Xna.Framework.Game.Run (runBehavior=Microsoft.Xna.Framework.GameRunBehavior.Asynchronous) in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Game.cs:384
Microsoft.Xna.Framework.Game.Run () in /Users/Greyp/Desktop/MonoGame/MonoGame.Framework/Game.cs:370
MyGame.Program.FinishedLaunching (app={<UIApplication: 0x79777140>}) in /Users/Greyp/Desktop/MyGame/Game/Main.cs:32
UIKit.UIApplication.UIApplicationMain () in
UIKit.UIApplication.Main (args={string[0]}, principal=0x0, delegate=0x79623150) in /Users/builder/data/lanes/2077/d230615b/source/maccore/src/UIKit/UIApplication.cs:74
UIKit.UIApplication.Main (args={string[0]}, principalClassName=(null), delegateClassName="AppDelegate") in /Users/builder/data/lanes/2077/d230615b/source/maccore/src/UIKit/UIApplication.cs:58
MyGame.Program.Main (args={string[0]}) in /Users/Greyp/Desktop/MyGame/Game/Main.cs:40
Can someone please help with this problem? Thanks very much in advance! =)