Performance Issues Across Different Systems

Hey all, anyone else experiencing performance issues with different browsers/systems?

I have sent my project to several people to try out the mechanics, and I have received reports of between 10-60 FPS depending on what system/browser it’s running on.

I personally average around 55-60 FPS via browser or preview with a 3080 gpu. Another buddy gets 59-60 FPS. Another one gets 45 FPS with a 3080ti. And then a few buddy’s get around 10 FPS regardless of whether or not hardware acceleration is turned ON in the browser.

I have no clue why this stuff is happening, my coding is optimized right now.

Could it be the layer effects? I have several a few layers with different effects going on.

Could it be the 15 mp3 songs I have that randomly play after one stops?

I’m trying to at least find a happy medium and I’m not sure what to do lol.

Could be browser addons/extensions. I also notice a difference between Chrome and Firefox. I would suggest you have them run your game in incognito mode/ private mode. That will turn off the addons.

1 Like

From personal experience, browser performance is extremely variable. Your friend who is getting 45 fps, I suspect the refresh rate of their monitor might not be 60 hertz. I have a 144 hertz monitor, and when playing a gdevelop game that is locked to 60 fps, i can only achieve a maximum of 48 frames per second due to v-sync being on for all gdevelop games. If I uncap the framerate (by setting it to 0) in the properties this fixes the issue (but usually causes other issues like physics jittering). For myself I cap framerate at 72, which works for a 144 hertz monitor (will play 72 fps) while still allowing 60 hertz monitors to play at 60.

Another thing is that for some reason, even with gpu enabled on my browsers, I get extremely poor performance when using layer effects. Sometimes 1 or 2 layers can decrease performance by half on my machine i7 with nvidia 2070 when on a browser. Exporting to a desktop build can improve this, but if your computer has dedicated gpu and intergrated graphics, you may need to manually set the game to use the gpu in windows or nvidia settings.

Also, with regards to mp3, you might want to consider using a program like audacity to change the format to .ogg instead as the engine appears to handle them better.

1 Like

I will have them try this, thank you very much!

Interesting! If I am not using physics, I wonder if it will affect the game?

I will try the 72 FPS setting and see what happens!

I did some research and I saw that the high-end mp3 (320kbs) is good for the engine. I have used ogg as well with no real difference.

Thank you for the advice!

if you are not hitting a steady 60 on a 3080, the issue is general low performance and optimization is in order.

Gonna have to disagree there. My buddy doesn’t have a 3080 and had higher FPS than I do. It is all over the place.

What exactly is all over the place? Rendering, sound. physics? How have you established that the engine is the problem and not your code?

Overalll, I’d agree with Convictedweirdo. Most likely the variability in framerate you’re seeing is due to refresh rate differences. With Vsync on, if you can’t hit the refresh rate of the game (max FPS of the game is not an even divisor of the monitor refresh rate), Vsync will bump the game FPS down to the next common denominator.

So a 60 fps game on a 144hz monitor will bump down to 48fps. a 72 max fps game on a 60hz monitor will be fine other than not running at max framerate, mostly.

The biggest thing to watch out for is to ensure you’re not basing any of your event logic off framerate (adding 1 per frame will increase faster at 72fps than 60fps, for example) and instead need to be using behaviors that work of timedelta, or use timedelta in your math (adding 1*TimeDelta() instead of just 1, etc). It’s also for this reason it’s generally recommended to not set max FPS to 0 (infinite), but instead something like 240, which should cover the widest range of monitors out there.

Just for some detail on this, it doesn’t matter if you have hardware acceleration enabled in the browser settings at all. That just means “use hardware acceleration if the browser detects a device that it can use.” not “Always use hardware acceleration”, and chromium is constantly changing what it considers as supported for hardware acceleration. If for some reason this buddy(s) have dedicated GPUs and integrated GPUs, and their browser is deciding to use the integrated one, it doesn’t matter that hardware acceleration is enabled.

Keep in mind that while it may seem optimized, you cannot really be a judge of your own code in general unless you can see under the hood of the engine and understand how it operates. (Not saying you’re doing this, just giving an example) A pretty common mistake is people using 2 conditions thinking they’re optimized, but not realizing that due to the order of those conditions, it’s infinitely less optimized than reversing the order, etc.

1 Like

Thank you for the reply!

I did researched these forums for old topics on what COULD be the issues, that’s where I came up with the hardware acceleration thing. I will boost the FPS to 240 and see if that helps.

For sure about the coding. I have restarted this project 10 different times because I didn’t like the organization and whatnot of the coding. This time around I have been very meticulous in regards to the tutorials and everything that I watch in which orders that they are placing the codes. I generally try to use only GDEVELOP tutorials when possible, but I will try to further optimize where I can.

Any tips on how to order events for better optimization?

The FPS is all over the place depending on the systems upon which the game is being ran. Holding steady at those numbers, but still anywhere from 10 FPS to 60 FPS (before I increased the max). Just seems weird that it would work on lesser machines better than beefier machines. Haven’t tried exporting the standalone yet, not sure if it would matter?

Hey!!! Setting the FPS to 240 did the trick, thank you so much!

1 Like