We need to talk about the Jank!

0 favourites
  • Runner template on a Win10 x64 system with a GTX 1060 card

    Same except I have a 1070. But isn't the CPU playing more of a role than the GPU in this case? Unless I'm confusing something the cpu usage spikes whenever a jank happens, right?

  • In a windowed game, dropping a single frame isn't really unusual - the OS might have just scheduled a background thread or otherwise done something to take CPU time away from the game thread so it misses the 16ms v-sync deadline. Not much to be done about that and affects pretty much everything on the system. So a single missing frame probably isn't anything notable. However some other profiles have shown longer janks, e.g. the 68ms frame in an earlier profile is about 4 frames, which is probably something else, but I've not been able to observe that yet myself.

    For those affected, is it fixed in Canary? If so it's probably best just to wait it out...

  • Some games i've played, mostly older poorly optimized 3d games uses tripple buffering to even out the framerate a bit. Is that something that could help in these cases? and is it worth it for a bit more vram usage, depending on what type of game and platform you're targeting?

    From what I understand Tripple buffer is sometimes used to smooth the experience, similar to v-sync?

    Does the web even offer this feature?

    I mean you can't even take control over default V-sync to for example, simply enable/disable it.

  • I spent a while profiling the Endless Runner template on a Win10 x64 system with a GTX 1060 card and couldn't see anything out of the ordinary. A profile showed it did occasionally skip a single frame.

    > Runner template on a Win10 x64 system with a GTX 1060 card

    Same except I have a 1070. But isn't the CPU playing more of a role than the GPU in this case? Unless I'm confusing something the cpu usage spikes whenever a jank happens, right?

    I can see how those are normal for a GTX 1060 and GTX 1070. But at those level... Guys, mind you we are talking about simple game templates here.

  • Ashley Canary did help a bit for me. I did get the an occasional minor jank similar to what you're describing.

    I would say there are 3 types, in various browsers/platforms.

    1. Minor frame drops that are barely visible, those doesn't really bother me, you need eagle vision to detect them.

    2. Bigger janks, that are clearly visible, that sometimes even cause input like clicks and touch not to be detected.

    3. Several seconds of unstable framerate. Seems to be completely random, don't know where these come from. Goes away after a while but can return.

    They look like this:

  • In my experience jank is most of the times a problem with Intel HD graphics ... besides the time v-sync was broken.

    Laptops and sometimes even desktop PC's don't use the dedicated GPU for browsers, you can add the "rendererDetail" expression to see which GPU is in used.

  • For those affected, is it fixed in Canary? If so it's probably best just to wait it out...

    No I just tried an html export on Version 71.0.3543.0 (Official Build) canary (64-bit)

    Just as bad.

    Try the export here, platform disabled

    https://www.sizzle-games.com/Endless%20runner%20template/

  • In a windowed game, dropping a single frame isn't really unusual - the OS might have just scheduled a background thread or otherwise done something to take CPU time away from the game thread so it misses the 16ms v-sync deadline. Not much to be done about that and affects pretty much everything on the system. So a single missing frame probably isn't anything notable.

    Sorry, this is simply not true. I can have a Construct Classic project run for extended periods without drops as well as a Chowdren demo, or a modern game, running at 120fps mind you, so the window is just 8ms. An OS background thread on an 8 core PC is not gonna stall the whole system.

    Also Vsync has been broken on chrome for 4 years now, you're gonna suffocate if you hold your breath for an update to fix that.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • In my experience jank is most of the times a problem with Intel HD graphics ... besides the time v-sync was broken.

    Laptops and sometimes even desktop PC's don't use the dedicated GPU for browsers, you can add the "rendererDetail" expression to see which GPU is in used.

    Tried that expression to endless runner text object, Was using AMD radeon pro 560 instead of the intel, on Macbook Pro in Chrome 69. Still very janky.

    For me jankyness kan differ greatly from run to run also. Some runs quite smooth with very little jank, some runs completely unplayable even on the same browser, a few previews in between. Have to close preview and try again. Might be a longshot, but can it be that the game starts before everything is ready, before things are loaded properly, causing something to get out of sync? No idea? Very odd though.

    But from todays tests with apk and nw.js export seems way better than preview and html export. Little to no jank in apk and nw.js but some very noticeable janks in preview and html5 export.

  • > In my experience jank is most of the times a problem with Intel HD graphics ... besides the time v-sync was broken.

    >

    > Laptops and sometimes even desktop PC's don't use the dedicated GPU for browsers, you can add the "rendererDetail" expression to see which GPU is in used.

    Tried that expression to endless runner text object, Was using AMD radeon pro 560 instead of the intel, on Macbook Pro in Chrome 69. Still very janky.

    For me jankyness kan differ greatly from run to run also. Some runs quite smooth with very little jank, some runs completely unplayable even on the same browser, a few previews in between. Have to close preview and try again. Might be a longshot, but can it be that the game starts before everything is ready, before things are loaded properly, causing something to get out of sync? No idea? Very odd though.

    But from todays tests with apk and nw.js export seems way better than preview and html export. Little to no jank in apk and nw.js but some very noticeable janks in preview and html5 export.

    So I've trimmed the runner down to two events, 1 Tiled Background and have it scrolling, nothing is created or destroyed at all, all it does is reset its postion to the right., I have reduced the bullet speed to 200.

    My events.

    And the html export

    https://www.sizzle-games.com/Endless%20runner%20template/

    If you wait and observe at least 20 passes for me I can still see the odd jank, and on occasion a big one, which is obviously disappointing.

    Does this 2 event export jank for you, or is it just my imagination ?

    Hope this gets fixed soon by whoever the powers may be.

  • sizcoz Tested your export. These are my results:

    Surface pro 4:

    Firefox: See very noticeable janks.

    Chrome: 69, janky.

    Canary: janky but a bit less.

    Now here comes the twist though!

    I connected the power cable because my surface was getting a bit low on battery. Hmmmmm....janks suddenly decreased quite a lot. Chrome 69 and firefox still had some, but not as frequent, and not as heavy. I thought, that's odd so i tried something else. I clicked the battery icon in the task bar, and changed setting to best performance.

    Result after setting:

    Firefox: no janks

    Chrome: no janks

    Canary: no janks

    Are you testing on a laptop? or using balanced power scheme?

    Results on Sony Xperia XZ1

    Chrome: Some very rare janks far between.

    Edge: Some occasional jank.

    So on windows, power mode setting seems to make a huge difference. In other desktop games(non html5) this usually only lowers framerate when on battery, but does not cause janks.

    I only have laptops, tablets and mobiles to test on. No regular gaming computer, workstation or anything like that.

    I'll test on macbook pro when I'm back at work tomorrow.

  • Does this 2 event export jank for you, or is it just my imagination ?

    No jank on my PC except for a small hiccup in the beginning. No jank on my iPad Pro 10.5". Low amounts of weak jank on my OnePlus3, seems to vanish when being charged.

    Tested on PC with:

    Chrome 69.0.3497.81 and Firefox 62.0

    i7-4770k and GTX 1060

  • sizcoz Tested your export. These are my results:

    Surface pro 4:

    Firefox: See very noticeable janks.

    Chrome: 69, janky.

    Canary: janky but a bit less.

    Now here comes the twist though!

    I connected the power cable because my surface was getting a bit low on battery. Hmmmmm....janks suddenly decreased quite a lot. Chrome 69 and firefox still had some, but not as frequent, and not as heavy. I thought, that's odd so i tried something else. I clicked the battery icon in the task bar, and changed setting to best performance.

    Result after setting:

    Firefox: no janks

    Chrome: no janks

    Canary: no janks

    Are you testing on a laptop? or using balanced power scheme?

    Results on Sony Xperia XZ1

    Chrome: Some very rare janks far between.

    Edge: Some occasional jank.

    So on windows, power mode setting seems to make a huge difference. In other desktop games(non html5) this usually only lowers framerate when on battery, but does not cause janks.

    I only have laptops, tablets and mobiles to test on. No regular gaming computer, workstation or anything like that.

    I'll test on macbook pro when I'm back at work tomorrow.

    I'm on laptop, power cables always plugged in, but guess what, I went to additional power settings, and set up a custom power plan, and set it to High performance, and got very minimal jank.

    Next dilema, persauding your users to ditch their powersaving modes.

  • Created a post on feedback hub. Please upvote or add comments, maybe windows can look in to this as it seems related to your power mode.

    aka.ms/AA2jyqy

    Might be worth it if you are developing for win10/desktop.

    -

    Power mode causing gc to jank, when it shouldn't? The plot thickens.

    Ashley Do you have any suggestions on how to deal with this? Many here are probably targeting casual players on lower spec machines and laptops, with (recommended) power mode set as default. Probably guaranteed jank fest playing a html5 game. You can't tell your players to start messing too much with windows settings to have a decent experience. Simple games like these shouldn't have any issues on recommended power mode.

  • I also create a bug with edge, who might be able to escalate the issue, if it's an OS power saving mode issue.

    developer.microsoft.com/en-us/microsoft-edge/platform/issues/18921895

    Please go there and comment and upvote in case you're having similar stutters and janks.

    Edit: Filed an issue with chrome as well. Just in case.

    bugs.chromium.org/p/chromium/issues/detail

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