0

I am using libGDX v 1.2.0 and have roboVM plugin 0.0.14 installed in eclipse. I have created an app that works as expected on the desktop and iOS Simulator (iOS 7.1), however when i set it to run on my iPhone 4s running iOS 7.1, it installs and shows the libGDX splash screen and then crashes and the console shows this error

com.badlogic.gdx.utils.GdxRuntimeException: Couldn't load file: noodle.png
at com.badlogic.gdx.graphics.Pixmap.<init>(Pixmap.java)
at com.badlogic.gdx.graphics.glutils.FileTextureData.prepare(FileTextureData.java)
at com.badlogic.gdx.graphics.Texture.load(Texture.java)
at com.badlogic.gdx.graphics.Texture.<init>(Texture.java)
at com.badlogic.gdx.graphics.Texture.<init>(Texture.java)
at com.badlogic.gdx.graphics.Texture.<init>(Texture.java)
at com.badlogic.gdx.graphics.Texture.<init>(Texture.java)
at com.chiefpeanut.noodle.Assets.load(Assets.java)
at com.chiefpeanut.noodle.MyGame.create(MyGame.java)
at com.badlogic.gdx.backends.iosrobovm.IOSGraphics.draw(IOSGraphics.java)
at com.badlogic.gdx.backends.iosrobovm.IOSGraphics$1.draw(IOSGraphics.java)
at org.robovm.apple.uikit.UIView.$cb$drawRect$(UIView.java)
at org.robovm.apple.uikit.UIApplication.main(Native Method)
at org.robovm.apple.uikit.UIApplication.main(UIApplication.java)
at com.chiefpeanut.noodle.IOSLauncher.main(IOSLauncher.java)

Caused by: java.io.IOException: couldn't load pixmap bad zlib header
at com.badlogic.gdx.graphics.g2d.Gdx2DPixmap.<init>(Gdx2DPixmap.java)
... 15 more

What on earth is causing this error and why does it only occur on my phone, not the simulator.

Thanks in advanced for any help!!!

  • I figured it out! I will post an answer soon – user3773207 Jul 08 '14 at 01:06
  • Could be a filename issue. The filesystem when running in the simulator is case-insensitive while the filesystem on an iOS device is case-sensitive. Check that you use the right casing in your code and in the filesystem. – ntherning Jul 08 '14 at 11:28

1 Answers1

0

Ok took me a while but i figured it out. I had copied evrything from my assets in the android folder into the data folder of my ios project (as according to some stupid tutorial). It seemed to be unable to read the correct image or something so to fix it I just deleted everything from my data folder except for the stuff like the icon and the splash screen and it worked