hello,
I am checking out LOVE and LUA in general and I seem to have some trouble with my png explosion sprites. Some of them work, some only display a black/white image with nothing in it. Am I missing something here? Is my libpng support broken or what? How can I fix this? If I do a release for windows (I'm developing in Archlinux), the problem is the same. Here is how that looks:
Here is the .love (too big for uploading here)
png support broken?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: png support broken?
Huh, it displays normally for me.
Welcome, by the way!
Welcome, by the way!
Help us help you: attach a .love.
Re: png support broken?
I believe this is a graphics card issue, probably a power-of-2 problem. Love pads images with empty space, so that they have an po2-size. This might be too large for your graphics card. Try making the image more squarish (by wrapping the long line of images into multiple lines).
Check out my blog on gamedev
-
- Prole
- Posts: 4
- Joined: Mon Mar 16, 2015 11:43 am
Re: png support broken?
ah, ok my machine is a laptop with intel graphics and 256M vram. I'll try that squaring and report back.
thanks!Robin wrote:Welcome, by the way!
-
- Prole
- Posts: 4
- Joined: Mon Mar 16, 2015 11:43 am
Re: png support broken?
a-ha! that worked like a charm, thanks for clearing that up. now how do I get these lines played in order ... but thats another topic.
cheers
cheers
Re: png support broken?
What lines? If you're trying to draw an image that contains thin lines, you should try the various combinations of filtermodes and integer coordinates (linear and drawing at floor(x), linear and drawing at floor(x)+0.5, nearest and drawing at floor(x)...)JohnnyTheBoy wrote:a-ha! that worked like a charm, thanks for clearing that up. now how do I get these lines played in order ... but thats another topic.
cheers
- slime
- Solid Snayke
- Posts: 3163
- Joined: Mon Aug 23, 2010 6:45 am
- Location: Nova Scotia, Canada
- Contact:
Re: png support broken?
The image dimensions are too large for your GPU - you can check at runtime via love.graphics.getSystemLimit("texturesize"). If either the width or height of the image is larger than the maximum texture size, your GPU won't be able to use it.
For very low-end GPUs, the max texture size is usually 2048x2048 or 4096x4096.
For very low-end GPUs, the max texture size is usually 2048x2048 or 4096x4096.
-
- Prole
- Posts: 4
- Joined: Mon Mar 16, 2015 11:43 am
Who is online
Users browsing this forum: Bing [Bot], Semrush [Bot] and 6 guests