Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for loss of GLTF override data due to objects eviction from the rendered scene #2063

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

vldevel
Copy link
Contributor

@vldevel vldevel commented Jul 18, 2024

Commit 64c541f introduced a bug causing the indue removal of GLTF override data whenever an object is 'killed' when not rendered any more (e.g. an object in a connected neighbour region finding itself out of draw distance when the user moves or cams around).

Since this data is not resent by the sim server until the next reconnection of the said sim, the object may re-rez later with missing overrides.

This commit simply comments out the culprit line.

…endered scene

Commit 64c541f introduced a bug causing the indue removal
of GLTF override data whenever an object is 'killed' when not rendered any
more (e.g. an object in a connected neighbour region finding itself out of
draw distance when the user moves or cams around).

Since this data is not resent by the sim server until the next reconnection
of the said sim, the object may re-rez later with missing overrides.

This commit simply comments out the culprit line.
@github-actions github-actions bot added the c/cpp label Jul 18, 2024
@vldevel
Copy link
Contributor Author

vldevel commented Jul 19, 2024

Just a note that, after the code is fixed and when you are ready to run the fixed viewer, you need to clear the objects cache to see the fix working in already visited regions (else you pick up corrupted/missing cache object data); maybe an object cache version increment would be a good thing to do, so that users running the future fixed viewer will automatically have their old corrupted cache wiped out...

@marchcat
Copy link
Contributor

Thank you for the contribution!

@brad-linden brad-linden self-requested a review July 24, 2024 19:51
// session (e.g. for neighbour region objects, depending on draw
// distance, while moving or caming around) and its override may
// not be re-sent by the simulator, causing a loss in the override
// data ! HB
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I need to test this more to fully understand these cases, but the object cache probably needs a larger redesign to properly handle the neighbor region object cases. the main correctness criteria after cache eviction should be that if the overrides get evicted from the cache then the object itself will also be evicted from the cache, and when the viewer sends the cache miss message to the simulator the full object update and overrides will be re-sent.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fix, which has been in place in my viewer for weeks, resulted from the direct observation and reliable reproduction of the problem by me. Since the bug I observed happened just after the inclusion of that line in my code base, I could easily identify it as the culprit (the benefit of weekly releases is that such bugs are quickly identified and easy to trace back to a culprit code change).

However, I did not try and diagnose what happened at the cache level, but could also see issues with this line active, after relogs and missing overrides.

Copy link

This pull request is stale because it has been open 30 days with no activity. Remove stale label or comment or it will be closed in 7 days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants