Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Android / Extremely Slow Playback Speed on Android

Author
Message
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 2nd Feb 2012 06:22 Edited at: 2nd Feb 2012 07:06
I got my application built and deployed to my tablet. However, it runs incredibly slow! It takes about 5 real-time seconds to perform 1 second of action in-game.

When I broadcasted and played the game with the App Player on the same tablet, it ran faster than on my iPhone 3GS! I don't know what the problem would be :/

EDIT: Uploaded and included the application's APK for anyone to try and test out on their device.

Hi there. My name is Dug. I have just met you, and I love you.

Attachments

Login to view attachments
The Zoq2
14
Years of Service
User Offline
Joined: 4th Nov 2009
Location: Linköping, Sweden
Posted: 2nd Feb 2012 09:04
I tried it (Great game BTW) and it ran fine on my galaxy note...
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 2nd Feb 2012 09:27 Edited at: 2nd Feb 2012 10:12
Thanks Zoq,
I find your praise of my app to be reassuring, however it still unnerves me to think that my app runs perfectly when it's broadcasted over wifi to the AppGameKit Player app, but runs at 1/5 speed when compiled and installed as a standalone app.

Perhaps it's my device, but I think there is something wrong with the AppGameKit Player/build process that is causing it to happen.

EDIT: Two videos showing what happens
Android device, compiled and installed, against PC version

Android device, app being transferred over wifi broadcast in AppGameKit Player, against PC version

Hi there. My name is Dug. I have just met you, and I love you.
Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 2nd Feb 2012 15:51
Is the FPS lower or just the timing functions? Are your Android.mk and Application.mk different from the ones in the interpreter folder?
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 2nd Feb 2012 18:59 Edited at: 2nd Feb 2012 19:47
I would wager the FPS is lower. If I rotate my tablet around - to force AppGameKit to rotate the display - it takes about four to five seconds for the display to do the default transition. When I rotate on iOS or using the AppGameKit Player, it's done instantly Why it takes this long, I am not sure. As for the two mk files, I can check to see if they're different. I didn't edit them myself :/

Here is a link demonstrating the slow rotation;
http://www.youtube.com/watch?v=H9wv72DP1Ac

Hi there. My name is Dug. I have just met you, and I love you.
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 3rd Feb 2012 06:15 Edited at: 3rd Feb 2012 06:20
Hey Paul!
For giggles, I compiled the AppGameKit Player app for myself - and that is as slow as molasses when ran as well. So, there is something wrong with the build process on my machine, because both the AppGameKit Player and my app run slowly.

This is the only thing I can think of, as the normal AppGameKit Player that I didn't compile runs fantastic, whereas the one I built runs really slowly.

EDIT: The only "android.mk" and "application.mk" files I can find are in the "interpreter_android/jni" folder. They're not at all in the "interpreter" folder

Hi there. My name is Dug. I have just met you, and I love you.
Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 3rd Feb 2012 17:39
Quote: "The only "android.mk" and "application.mk" files I can find are in the "interpreter_android/jni" folder."


Those are the ones I meant, the application.mk contains values such as "release" instead of debug, and armeabi-v7a which, if your device supports it, is faster than armeabi, both should be present to make it compatible with old devices whilst being faster on new devices.

Are you using ndk 6b?
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 4th Feb 2012 00:18
I'll double check to make sure none of the values are messed up . In addition, I've compiled with ndk 6, 6b, and 7 all with the same end result. I might try to install all of the tools onto a different PC to see it there are any issues.

Hi there. My name is Dug. I have just met you, and I love you.
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 4th Feb 2012 23:05 Edited at: 5th Feb 2012 00:15
I just installed all of the tools onto a new PC, and it still compiles and runs incredibly slow. :/ I downloaded and installed an older version of the Java SDK (6 instead of 7) and it still isn't working

EDIT: This could be due to my device, as the Android simulator (with ARM instead of ARM7) does the exact same thing. However, how does the externally built AppGameKit Player run my app at full speed, but my own build process causes the exact same player to be crippled?

Hi there. My name is Dug. I have just met you, and I love you.
Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 5th Feb 2012 01:06
The only thing I can think of is that the version of the the files you are using to compile are not up to date. I've attached my version of the interpreter files that were used to compile the Android interpreter.

Attachments

Login to view attachments
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 5th Feb 2012 01:22 Edited at: 5th Feb 2012 01:25
YUP! IT RUNS SMOOTH, LIKE MELTED BUTTER!
Now, you should probably update the AppGameKit Installer to include those new Android files....

Thank you much Paul! I just got in the last level from my artist tonight, so I'll be able to compile and release for Android now too!

EDIT: Audio isn't working. Will restart device now to see if it was a fluke... :/
EDIT2: Audio works =)

Hi there. My name is Dug. I have just met you, and I love you.
victordavion
12
Years of Service
User Offline
Joined: 3rd Jan 2012
Location:
Posted: 11th Apr 2012 22:32 Edited at: 12th Apr 2012 04:29
What exactly are the differences in the files? I'm wondering if it could help the performance of my Tier 2 project which seems to be capping at about 45 FPS or so and I don't want to experiment too much with the Core/main.c since I don't know what I'm doing with those haha.

Edit:
I'd also like to add that just by adding sprites I seem to be getting a drop of 15 FPS (from the synced 60 to 45). I'm using virtual resolution and when I rotate to portrait mode (and it adds the bars to the top/bottom) I see an improvement of 3-4 FPS.
By removing my update loop (sprites will be added but they don't do anything) I see an improvement of 5 (will average to 50 fps). So I'm kind of curious how slow these agk functions are and tips on improving performance.
victordavion
12
Years of Service
User Offline
Joined: 3rd Jan 2012
Location:
Posted: 14th Apr 2012 06:08
Update to my last:

So I'm running the App on my phone (Nexus One) and getting 45/48 FPS in Landscape/Portrait orientation.
I run it on my Asus Transformer and I get 40/50 FPS in Landscape/Portrait mode. Quite a discrepancy. Might this have anything to do with the faux landscape mode AppGameKit uses? It's just taking coordinates from portrait and translating them into equivalent landscape coordinates.

Will we at any time see true landscape supported? Because it kind of sucks that I can't show off my App using my HDMI out on a larger screen since it will show up sideways on the television (since the hardware detects landscape mode, but the software is portrait simulating landscape).

Login to post a reply

Server time is: 2024-04-19 13:05:38
Your offset time is: 2024-04-19 13:05:38