Stutterring but reads 60fps

1 favourites
  • Hi, on device my FPS counter reads almost 60fps constantly but I can visibly see objects stuttering as they move across the screen...Scrolling right to left. These objects all use DT to control movement.

    What is going on and how should i fix this? Thanks

    Tagged:

  • A shot in the dark. Is it a Pixel-Art Game and has low resolution with pixel rounding enabled? Then try try disable pixel rounding.

  • Unfortunately no, it's a side scroller with hi res graphics.

  • Could I ask if you test your project with your projects "vsync" setting set to "unlimited"?

    I have this issue sometimes too, but I've found that disabling vsync fixed the stuttering and made it buttery smooth. I don't know why and I haven't been able to reproduce this in a minimal project yet.

    If disabling vsync DOES help, then don't expect to continue like this, but perhaps there's a bug with vsync, or, we would need to ask Scirra for a "max FPS" cap so that's we can disable vsync without having your CPU at 99%.

  • I set it to unlimited (ticks only) and the fps averages around 90 fps on a device build however the jittering is still exactly the same. There is no notable difference to the eye.

    With framerate mode set to Unlimited (full frames) I get around 55-60fps but again the jittering is still present.

    As as side note, I also tried exporting without using dt and using VSynced FPS mode, but I still see the same issues even though its running at 60fps.

    For example, instead of:

    Self.X-(train_speed*(Self.speed_adjust))*dt

    I use:

    Self.X-(train_speed*(Self.speed_adjust))/70

    On PC it runs at 60 fps as well, but everything is buttery smooth to the eye.

    Same issues with Worker mode on or off..makes no difference.

    Im using 293.3 stable and the tablet is a Samsung A7 Lite

    If Im already at 60fps on device but there is this random jittering everywhere, then there's no way I can even optimize to improve things. What use is an fps reading if there is janking all the time regardless? This is a big roadblock for me.

  • I'd also like to say that I've been working on the project for over a year now and this issue is so serious that I'll need to switch engines if I can't resolve it. Something I really don't want to do.

    I've been happily and confidently going by (the 60 fps) )readings on the fps counter until now and even decided to update the minimum device specs to something more modern to overcome the fps issues I previously was encountering, but for the kind of work I'm just now doing on the project, the janking issues are so glaringly obvious, its just not feasible to release in this kind of state.

    If the scirra team can offer any advice that would be great :)

  • Got a minimal example project or video? It would be useful to troubleshoot your issue, or for the devs to look into. I've seen jank and jitter mean different things to different people.

    For example, your sprites could be jittering back and forth position wise at 60 fps if there is a positioning issue such as the previously mentioned pixel rounding. It can happen when your camera and object are moving at the same speed but with slightly offset timing. There can also be pinning issues if you're using a pinned camera where the camera position updates one tick later. This can happen no matter how high your fps is.

    One time in discord someone was complaining about their game recordings showing "jank" when running at 60 fps, but it was because their videos were recorded at 19fps or something silly like that.

    It's highly likely your stuttering/jank/jitter has nothing to do with fps at all.

  • You can see a video here:

    https://www.dropbox.com/s/jxibr9uhy5egnur/TrainJank1.mp4?dl=0

    The level runs at close to 60fps but you can noticeably see the plants in the foreground janking. Its less noticeable on the video than in real life but hopefully you can see that its not 60fps buttery smooth.

    I don't use any pinning, only scene graph hierarchies, but these aren't present on the janking foreground plants.

    My camera is fixed and isn't moving or being updated at this point in the game.

  • It really is hard to tell from the video, it looks mostly fine/smooth to me. Probably doesn't help that the video is recording at 30fps. I don't think it's a big deal on something that the user normally wouldn't be focused on, especially at high speeds. The wheels and train and tracks look great (from the video at least, I don't doubt that it's worse in person as you mentioned).

    I have a minor suspicion you may be nearing the limits of your device, as the fps as shown was at the low 50s and even dips below 50 at the beginning, and you said it looks fine on PC. I wouldn't normally call that a stable fps. I do note that it gets back to around 60 in the latter half, but I'm also not clearly seeing your jank/jitter either.

    If I were to pursue this I would try taking everything out except the foreground plants (especially any physics actors), and seeing if it makes a difference on the device.

    Edit: Any parallax on the layer? Or just varying speeds between foreground and background objects?

    Another long shot to consider - are you updating your debug text every tick? Try disabling the text updates to see if it makes a difference. I've had issues with this before where my debug text was slowing everything down, although mine was significantly more text objects to display the contents of a data array.

  • That's not really true:

    Not sure if you really forget on purpose or ????

    as on the videos, they clearly showed you the settings before recording at 60 FPS please do not invent false accusations.

    Yes, It was one of the tests at 19FPS trying different crazy configurations as they told you just for testing but all the rest of the videos were at 60PFS as they show you clearly on that video.

    https://www.dropbox.com/s/sj84pw9ffdmy1w4/Stutters%20Recording.mp4?dl=0

    Settings: https://www.dropbox.com/s/ta2r9376yuqwu4f/c22.png?dl=0

    I never saw this follow up video at 60 fps, just the one you posted at low fps. I have no idea why your cacti are jumping like that.

    I find it funny that you still going on with the same subject where you clearly couldn't make even one video smooth without stuttering after a whole night of trying.

    This is the best you could do:

    https://www.dropbox.com/s/bbmrvggjkoapinv/framerate.mp4?dl=0

    Your video with the blue objects is clearing stuttering and this is one demo with just two events and a few objects on the screen so really it should have been very easy for you to make but you couldn't, though you still carry on with the same thing.

    If I was you I would definitely not bring back the topic after that night lamo ))

    If you consider the blue bars stuttering, we have decidedly different definitions of what stuttering is. Looking back at it, I do see some stuttering on the blue bars now, but only right after hitting play from stop, but not when I rewind/scrub back to the beginning after it's already playing. I'd chalk that up to my computer being a potato as it loads the video into memory. Regardless point was to show the difference between recording at a low fps and high fps. Which has nothing to do with the OP's topic at all.

    Though not sure what has to do that topic with the OP's topic as the topic you mentioned was for recording videos for trailers etc... and the OP has stutters at the Gameplay not recording.

    I understand that the OP has stutters for gameplay, I was saying that it is harder to see the problem from a video when the recording framerate doesn't match the game framerate.

  • No parallax on any layer.

    I switched off all layers except from the front plants.

    The frame rate in this case starts at solid 61 and doesn't move under 60.

    I still see the jank although it is slightly less. Every few (4-7) seconds there is quite a big jump in the position of the plants.

  • Ran some tests to try to reproduce. It's much more noticeable for me when my estimated cpu usage gets high, according to the debug preview, at about 70%+. FPS stays above 55, but it's when it changes that jank is noticeable, especially for linearly motion. Lowering the number of objects/cpu load to under 50% made the FPS much more consistent.

    Turning off Vsync actually made it worse for me, as it drove the CPU use (and fps) up, causing significantly more jank, even though the fps was high.

    If the source is actually a CPU limitation, see if there's anything you can do to lower CPU utilization. If it happens in an empty project with low CPU utilization, I'm going to guess that some background software is possibly taking CPU time away from the game, like for example how some antivirus softwares can potentially slow a system to a crawl when running a scan at high priority. Not sure if that's a thing that can happen on a mobile device though, depending on how the device prioritizes it's CPU. Maybe some sort of power saving throttling? I doubt that would happen when actively using the device though.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thanks for testing with vsync disabled, it's interesting that noone else is getting similar results to me.

    Perhaps the jittery issue I experience is a different jittery issue to what others are experiencing, but for me I do get perfect results with vsync off, but when vsync is on, even if my monitor refresh rate is set to 60hz,144hz,or 240hz, I can see jittery issues every few seconds. Very unusual.

  • I am specifically testing on Android. I am seeing cpu readings of around 50%-70%, fps is now a solid 61 but I still get the Jank all the time which just hurts my eyes.

    Honestly I don't think I can release it like this, its almost like the fps reading is saying one thing but the reality is that the game is jerky.

    It's just not what I expect of a 60fps experience.

    I don't think I should first have to optimize to try to reach 60fps and then STILL see problems with the framerate even when Im at 60fps.

    I just tried the same test on a Huwai Mate Pro device. Its a much more powerful device than the A7 Tablet . It uses around 20% CPU on this device, the janking is far less, but the fact is that it still happens.

    Why should this janking happen at all if the device easily can run the game at a high frame rate and low CPU count?

    For me this is a bug in C3. If it can't run completely smoothly while reading 60fps+ then there is something wrong surely.?!?

  • That smoke/steam looks really smooth ...

    Did you try a test without it?

Jump to:
Active Users
There are 2 visitors browsing this topic (0 users and 2 guests)