Hi all,
First of all, as I’m new to Corona Forum, I would thanks all the Corona team for their great job.
Just a quick introduction about myself before posting here my issue:
I’m not new in game development, I’ve got a high degree in computer science, I started studying electronic long time ago and quickly became a fan of microprocessors and later programming language. I’ve worked a lot on Palm OS (fast 2D library, 3D rendering engines for science and games written in C - PACE Native Object - and other software), iOS (games) and started 10 months ago on Android.
I first decided to make my own 3D library that took me about 4 months of works to go on, I’ve published some 3D live wallpapers using it, and then I decided to add other stuff to my lib in order to create 2D and 3D games.
Well, after 2 months of work I’ve fallen in trouble with stable frame rate on Android (for both render modes: RENDERMODE_CONTINUOUSLY and RENDERMODE_WHEN_DIRTY, using delta time with or without averaging and so on…) and I was unable to ensure smooth scrolling of my game (a kind of Run) .
So, I’ve thought my lib was not so good like that and I decided to move to another one that could help me to create smooth animations easier without headaches :D , and I started using Corona SDK.
After “playing” with the sample JungleScene (that uses objects scrolling, suitable for my needs), I can see the same problem (with the simulator and on a real device: Galaxy Note 2)…
The provided code uses also a delta time correction (like I did with my lib) but the scrolling (that use Translate()) is not smooth.
Printing into the console the delta time let me see that the average FPS is about 30 (between 31ms and 34ms) but I often see some values around 16ms and after that 51ms and I assume that the delta time is not accurate and/or the difference is too big to ensure a visual smooth translation. May be the GC is working and “eats” a big part of time ?
As I don’t know the way are internally handled the events, the DrawFrame of the GLSurfaceView, and so on,
I would love to hear about someone that has got the same issue and the way to correct it (if it is possible)?
Once again, I’m new about Corona SDK, but before posting here I’ve read many posts related to this kind of issue without success.
Can someone help me or point me in the good direction?
Many thanks,
Good dev,
Eric.