2020-01-18 19:03 CET

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0006340Spring engineGeneralpublic2019-12-30 14:48
Assigned To 
Product Version104.0 +git 
Target Version105.0Fixed in Version 
Summary0006340: Significant reduction in FPS with scroll/zoom on maps with rough terrain
DescriptionSuspecting some changes in ROAM, that appeared shortly after version 1250 (not sure which version exactly).
While on powerful PC it might not be very noticeable, on a laptop it renders game unbearable.
Steps To ReproduceSelect a map with significant roughness, e.g. Stronghold.
Additional InformationSame issue was addressed by Zero-K players.
TagsNo tags attached.
Checked infolog.txt for ErrorsIrrelevant
Attached Files

has duplicate 0006348closed There's camera stuttering on larger maps 



Krogoth (reporter)

To avoid misunderstanding:
v 1250 works fine, no lag.


Anarchid (reporter)

There was some investigation WRT this around ZK.

This is quite definitely ROAM.

Moving the camera while viewing the cliffy borders on the map Onyx Cauldron with the ROAM mesh drawer ON results in a massive FPS drop.

Panning with the legacy mesh drawer results in a very slightly lower FPS when camera is static, but completely smooth panning - an overall massive increase in quality.

The ZK investigation has not resulted in an engine issue because there's a user-side workaround in the form of the "/mapmeshdrawer" command. If the issues are truly unbearable, a game may include a widget to automatically switch to the legacy setting when on a map that is known to perform badly with ROAM.


Krogoth (reporter)

From my experience, all maps perform badly with new ROAM.
Switching to legacy could be a last resort, but I really like how ROAM looks, more than legacy.
I didn't investigate the difference between new and old, but the old one worked well, correct?


Krogoth (reporter)

*between new and old ENGINE code


Anarchid (reporter)

I don't know if 1250 works correct.

These statements are making me confused:

> v 1250 works fine, no lag.
> I didn't investigate the difference between new and old, but the old one worked well, correct?


Krogoth (reporter)

it does.
meant difference in code.
bug maybe anywhere, theoretically not in ROAM code, so I can't 100% say that ROAM code is bad.


Kloot (developer)

I got tired of seeing 0006220 pop up over and over again and disabled threaded mesh tessellation in ROAM to get rid of it.

Anyone here is free to volunteer to fix the actual bug and restore performance.


Krogoth (reporter)

Ill try


Krogoth (reporter)

While trying to reproduce the crash..
How normal is "cannot recreate persistent storage buffer", VBO error?


Krogoth (reporter)



Krogoth (reporter)

Found it!
Look at the middle diamond (right quarter of left patch, left quarter of right patch)
If left triangle of it is getting split and when it tries to split base neighbour and goes out of nodes, it leaves childs hanging with unset neighbours to the right side.
Then, if in the next iteration right triangle (of the center diamond) goes out of nodes right away, it doesn't connect hanging pointers.
Finally, if tesselation from bottom or top causes left triangle to split (via multiple splits such that ultimately cause Patch:line 240 executed), then splitting left triangle's child nodes will use unset neighbours,
thus access violation.
Obviously, it doesn't happen like this if single thread.


Krogoth (reporter)

Principally: the problem is leaving pointers hanging between splits of triangle and its base neighbour.


IceXuick (reporter)



Kloot (developer)

thanks for the legwork, I'll see what I can do soon.


IceXuick (reporter)

Any news on this bug and or possible fix?


Krogoth (reporter)

Just in case if Kloot was busy and to ease things up for him,
position in code:
Setting tlc->RightNeighbour and trc->RightNeighbour only when branch, thus leaving them hanging if both branch this and next iter go out of nodes.
One of solutions could be eliminating childs of empty base neighbour (in addition to own), but there can be many solutions.


Krogoth (reporter)



Krogoth (reporter)

*not empty base neighbour, but one with not valid childs
Where is My EDIT Button? :X


IceXuick (reporter)

Latest 1455 release made this problem even worse...

-Issue History
Date Modified Username Field Change
2019-11-15 15:09 Krogoth New Issue
2019-11-15 15:13 Krogoth Note Added: 0020220
2019-11-15 15:17 Anarchid Note Added: 0020221
2019-11-15 16:04 Krogoth Note Added: 0020222
2019-11-15 16:05 Krogoth Note Added: 0020223
2019-11-15 16:09 Anarchid Note Added: 0020224
2019-11-15 16:12 Krogoth Note Added: 0020225
2019-11-15 16:36 Kloot Note Added: 0020226
2019-11-15 16:51 Krogoth Note Added: 0020227
2019-11-18 11:04 Krogoth Note Added: 0020240
2019-11-18 11:15 Krogoth Note Added: 0020241
2019-11-20 08:48 Kloot Relationship added has duplicate 0006348
2019-11-20 15:19 Krogoth Note Added: 0020251
2019-11-20 15:20 Krogoth Note Added: 0020252
2019-11-20 17:32 IceXuick Note Added: 0020253
2019-11-20 22:51 Kloot Note Added: 0020254
2019-11-28 15:23 IceXuick Note Added: 0020263
2019-11-29 06:29 Krogoth Note Added: 0020264
2019-11-29 06:30 Krogoth Note Added: 0020265
2019-11-29 06:37 Krogoth Note Added: 0020266
2019-12-03 22:54 IceXuick Note Added: 0020272
2019-12-30 14:48 abma Target Version => 105.0
2019-12-30 14:48 abma Checked infolog.txt for Errors Irrelevant => Irrelevant
+Issue History