Request for feedback: front-to-back renderer performance

Discussion and feedback on Construct 2

Post » Mon Jun 22, 2015 12:09 pm

Hi all,

I'm looking for feedback on the performance of the new front-to-back renderer introduced in r207. (See the r207 release notes for a brief overview of how it works if you missed it.) r208 fixed some bugs in the new rendering mode so it should be working reasonably well now.

I don't have many real-world games to test with. Artificial benchmarks are good to show the maximum difference it can make, but this is often much higher than would be the case for real games. For example the WebGL renderer can benchmark up to a whole 20 times faster than canvas2d in one artificial test we use, but for real games it's only up to 2 times faster - which is still great, but a long way off the artificial test result.

So if you're using r207+ could you give the front-to-back renderer a go and report back how it works for you? You just need to set 'Front-to-back renderer' to 'Enabled' in Project Properties (by default it is disabled).

The most important information to include is:

- the framerate in FPS both with and without the front-to-back renderer enabled
- the browser and OS version (e.g. Chrome on Android 5.1.1)
- the device model if mobile (e.g. iPad Air 2) or system spec if a PC
- the device GPU if you know it - use C2's rendererDetail expression to check this if you don't know (although only Chrome and IE currently support it)
- a brief overview of the kind of game

If you have multiple systems/devices, testing all of them would be much appreciated!

Note we're aware that some GPUs are actually slower in front-to-back mode. We'll probably have a front-to-back mode blacklist where it falls back to back-to-front mode only on certain GPUs. Adreno GPUs will probably be on this list, but your feedback may help identify others.

This information should help us decide whether to have front-to-back mode enabled by default in the next stable release. Thanks for your help!

Note: please don't report bugs with the front-to-back renderer here. I'm only looking for performance information. If you have a bug with the front-to-back renderer please report it to the Bugs forum following all the guidelines.
Scirra Founder
B
399
S
236
G
89
Posts: 24,519
Reputation: 195,351

Post » Mon Jun 22, 2015 12:31 pm

Decided to try it out with the last game I made (Dreaming Sarah) and here's a comparison.
Front-to-back renderer off
Image

Front-to-back renderer on
Image

My whole game uses a "effect" layer in which I have a single image (usually a fog) with a warp WebGL effect.

- Framerate was the same on/off
- Tried on NW.js and Chrome
- PC is Athlon II X4 630 2.80GHz 64bit , 6GB ram, GPU is Nvidia GeForce 750
- rendererDetail shows this ANGLE (NVIDIA GeForce GTX 750 Direct3D11 vs_5_0 ps_5_0) [Google Inc.] [front-to-back enabled]
- It's a 2D platform game
B
125
S
43
G
41
Posts: 849
Reputation: 28,260

Post » Mon Jun 22, 2015 1:05 pm

@andreyin - if you have a bug with the front-to-back renderer please report it to the Bugs forum following all the guidelines. If it doesn't appear correctly the performance numbers are probably not useful either.
Scirra Founder
B
399
S
236
G
89
Posts: 24,519
Reputation: 195,351

Post » Mon Jun 22, 2015 2:54 pm

What if both are 60 fps, do you want the cpuutilisation %?
B
70
S
24
G
19
Posts: 1,757
Reputation: 17,616

Post » Mon Jun 22, 2015 2:59 pm

I use inspector to see what change, o dont see anything better
B
111
S
28
G
48
Posts: 1,882
Reputation: 36,426

Post » Mon Jun 22, 2015 3:47 pm

i just added a bug report on this related to extreme dropdown in fps and glitched view.

As far as i can see, in PC the fronttoback have a small difference with normal render, in my pc PhenomIIX4 with Radeon 6790 and W7. The difference is between 2-5 fps with normal games, and weird changes between 1-10 fps in heavy test (create 6000 objects with always jumping behaviour), the backtofront freezes in the jump instance, while fronttoback had 3 fps, so it's 3 frames better...
B
22
S
4
Posts: 106
Reputation: 1,360

Post » Mon Jun 22, 2015 4:32 pm

Did a quick test on a project and it was in the 20 to 30 fps range.
The game usually ran 55 fps, but really shouldn't be expected to benefit from front to back.
Its basically a bunch of tilemaps on a bunch of parallax layers set up like a starfield.
A few pixels overlapping other pixels rather than textures overlapping other textures.
More of a worst scenario basically.
Image ImageImage
B
170
S
50
G
179
Posts: 8,378
Reputation: 113,425

Post » Mon Jun 22, 2015 9:14 pm

I decided to run a test in three varying areas of my game to get a feel for how it handles. So for three sections of Courier:

Overworld section:
Back to Front:
~11,890 Objects, 60FPS, 70-85% CPU load depending on what I'm doing
Front to Back:
~11,800 Objects, 45-55FPS, 90-96% CPU load depending on what I'm doing
Effects range from low to medium-high depending on location, many objects but not always a lot moving, medium characters in one area.

Small Town Section:
Back to Front:
~1,335 Objects, 60FPS, 25-27% CPU load
Front to Back:
~1,335 Objects: 60 FPS, 30% CPU load
Effects-light, little movement, medium amount of characters

Dungeon with a lot of water and effects:
Back to Front:
~1850 Objects, 60 FPS, 68-75% CPU load
Front to Back:
~1850 Objects, 60 FPS, 70-80% CPU load
Effects-heavy, lots of moving objects, low amount of characters

Core i7 4770 @ 3.4 GHz, 16 GB ram, GeForce GT 640 4GB

My game is typically composed of a lot of overlapping objects, so I would think it would be good candidate for Front to Back. I do have effects in some locations which may be negating gains. I also have layout-wide HSL and Exposure shaders for color correction, so that may be a problem with it too. I do get some rendering differences between them, but that's beyond the scope of this post.
B
103
S
38
G
19
Posts: 962
Reputation: 17,996

Post » Tue Jun 23, 2015 10:35 am

Hmm... the browser capping the framerate at 60 FPS makes it hard to tell any difference. Maybe try closing all instances of Chrome and run again from the Start -> Run dialog as:

chrome --disable-gpu-vsync

Then you should get an uncapped framerate which makes for an easier comparison.
Scirra Founder
B
399
S
236
G
89
Posts: 24,519
Reputation: 195,351

Post » Tue Jun 23, 2015 5:15 pm

Fatal Crash (restarts the entire phone) on Huawei Honor2 when turning the cellphone (from landscape to portrait or viceversa), only happends if Front To back is on, never had this problem before in any kind of game...
B
22
S
4
Posts: 106
Reputation: 1,360

Next

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 5 guests