Page 1 of 2

love-native-android: bugs

Posted: Tue Mar 27, 2012 5:13 pm
by T-Bone
In order to keep some kind of structure to the forums, try to post bug reports here.

I'll start with some things I've noticed. Some of these are things I have mentioned before in other places, but having everything in one place seems like a good idea.

1. love.audio crashes, and when it doesn't crash the entire app, it may still simply stop playing sounds at random.
2. love.graphics.setLineWidth() does not seem to work, lines are always one pixel wide.
3. love.event.push('q') does not seem to work.
4. If the phone's screen is turned off, things crash.
5. Writing/reading files (with love.filesystem) does not seem to work. I'm not sure if files are written or not; if they are, you can't read them with "require".

If you guys post bugs here, I'll try to add them to this list. And as bugs get fixed, I'll remove them.

Re: love-native-android: bugs

Posted: Sun Apr 01, 2012 3:28 pm
by rokit boy
love.event.push('q') doesn't seem to work
NOOOOOO!!!!

Re: love-native-android: bugs

Posted: Sun Apr 01, 2012 4:18 pm
by T-Bone
rokit boy wrote:
love.event.push('q') doesn't seem to work
NOOOOOO!!!!
It's not fatal at this point, as pressing the "back" button takes you out of the game. And when you work with love-native-android as it is now, you really need to create a shortcut to force close apps by holding the back button down for a second, because it crashes quite often.

Re: love-native-android: bugs

Posted: Wed Apr 18, 2012 2:46 pm
by T-Bone
I noticed some wierd behaviour today, I will try to isolate the issue more, but still. It seems that if you use love.graphics.setMode to change the resolution, my game drops from around 40 FPS to 7-10 FPS. Even if you change the resolution back, it doesn't help; a full reboot of love-native-android is required to get the performance back. This does not seem to apply if you change the resolution to the same one you had from the beginning. However, changing to a higher resolution and then changing it back to the lower one does not cure the lag.

EDIT: There seems to be issues with love.graphics.getModes too. For example, this doesn't work:

Re: love-native-android: bugs

Posted: Thu Apr 19, 2012 9:01 pm
by Moe
seems to me like some clean up is going wrong and the system falls back to a software renderer instead of hardware acceleration. Don't spend more time on it, this is normal Android behaviour.

Re: love-native-android: bugs

Posted: Fri Apr 20, 2012 6:05 am
by T-Bone
Moe wrote:seems to me like some clean up is going wrong and the system falls back to a software renderer instead of hardware acceleration. Don't spend more time on it, this is normal Android behaviour.
Okay, but it is actually critically important to be able to get the screen's resolution at runtime. The alternative is having a menu where the user has to manually select the resolution of the device. And that would suck. Some kind of solution is needed here.

Re: love-native-android: bugs

Posted: Sun Apr 22, 2012 3:32 pm
by Moe
Actually we give the device resolution to love. If you do not use this resolution, the display manager of Android will either rescale the output or fill the screen with black. If you do not want that the graphics are rescaled, you will have to dynamically fit your application to the screen size.

Re: love-native-android: bugs

Posted: Sun Apr 22, 2012 6:28 pm
by T-Bone
Moe wrote:Actually we give the device resolution to love. If you do not use this resolution, the display manager of Android will either rescale the output or fill the screen with black. If you do not want that the graphics are rescaled, you will have to dynamically fit your application to the screen size.
Then how do you get the resolution at runtime? love.graphics.getWidth()/getHeight()? And also, the whole scaling thing does not seem to be the case: When I set my game to 720p (1280*720) on my 800*480 screen, I simply see the top left 800*480 pixels.

Also, when you give the resolution of the device, does it respect orientation? Proper landscape support is pretty important for pretty much all games.

Re: love-native-android: bugs

Posted: Sun Apr 22, 2012 7:49 pm
by Moe
T-Bone wrote:
Moe wrote:Actually we give the device resolution to love. If you do not use this resolution, the display manager of Android will either rescale the output or fill the screen with black. If you do not want that the graphics are rescaled, you will have to dynamically fit your application to the screen size.
Then how do you get the resolution at runtime? love.graphics.getWidth()/getHeight()? And also, the whole scaling thing does not seem to be the case: When I set my game to 720p (1280*720) on my 800*480 screen, I simply see the top left 800*480 pixels.
Yes, this seems to be the right way to get it.
Maybe I should have been clearer. There are two possible modes for different resolutions: panning and scaling. Panning takes a subimage (if the output is larger) or adds a border (if the output is smaller), scaling shrinks or extends the image to fit the screen. In newer versions of Android (I think starting with 3.1 or 3.2) you can select which mode is used. Before that, I think that panning was always used - which is exactly what you describe.
Also, when you give the resolution of the device, does it respect orientation? Proper landscape support is pretty important for pretty much all games.
Yes.

Re: love-native-android: bugs

Posted: Tue Apr 24, 2012 6:18 am
by T-Bone
Tried it out, works great! :neko:

By the way, are any of the bugs mentioned in the first post here solved yet?