Slick Forums

Discuss the Slick 2D Library
It is currently Sat Dec 14, 2019 6:41 pm

All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Tue Sep 11, 2012 10:27 pm 
Offline

Joined: Tue Sep 11, 2012 10:19 pm
Posts: 2
Here's the error:
Code:
    Exception in thread "main" java.lang.IllegalArgumentException: Buffer size <= 0
            at java.io.BufferedInputStream.<init>(BufferedInputStream.java:193)
            at org.newdawn.slick.opengl.CompositeImageData.loadImage(CompositeImageData.java:53)
            at org.newdawn.slick.opengl.CompositeImageData.loadImage(CompositeImageData.java:43)
            at org.newdawn.slick.opengl.InternalTextureLoader.getTexture(InternalTextureLoader.java:277)
            at org.newdawn.slick.opengl.InternalTextureLoader.getTexture(InternalTextureLoader.java:231)
            at org.newdawn.slick.opengl.InternalTextureLoader.getTexture(InternalTextureLoader.java:184)
            at org.newdawn.slick.opengl.TextureLoader.getTexture(TextureLoader.java:64)
            at org.newdawn.slick.opengl.TextureLoader.getTexture(TextureLoader.java:37)
            at LetterList.letterSearch(LetterList.java:284)


It is called from a Texture object using TextureLoader:
Code:
letterTex = TextureLoader.getTexture("PNG",letterFile,true);


Apparently someone in the irc channel I was in pointed out that is.available() is used as a buffered size. Perhaps this can be changed?


Top
 Profile  
 
PostPosted: Thu Feb 28, 2013 6:32 pm 
Offline

Joined: Thu Feb 28, 2013 2:23 pm
Posts: 3
I had the same problem when I sent my game to a friend with Windows. It worked for me on Linux though...
I am still trying to find why it happened.


Top
 Profile  
 
PostPosted: Thu Feb 28, 2013 9:20 pm 
Offline

Joined: Thu Feb 28, 2013 2:23 pm
Posts: 3
Now I sent it to him again, and it worked.
Apparently there was some problem with the loaded texture file, although I would expect it to throw IOException instead... this crash remains a mystery to me.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group