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

Mitigate depth offset precision issues on web #2187

Merged
merged 5 commits into from
May 24, 2023
Merged

Conversation

Wumpf
Copy link
Member

@Wumpf Wumpf commented May 23, 2023

Adds a new re_renderer example to make it easier to look at depth offset and general depth precision issue. Example description in the comments.

Mitigates depth offset issues by blowing up the depth offset by a large value and moving the near plane closer. Tested this with:

  • objectron, 3d points added to 2d scene
  • arkit, all objects added to 3d scene and step wise removed
  • native api_demo to check on depth offset example (this failed before!)

Independently, did a fix for cargo run-wasm --build-only to have it not spawn a browser window.

Checklist

PR Build Summary: https://build.rerun.io/pr/2187

@Wumpf Wumpf added 🪳 bug Something isn't working 🕸️ web regarding running the viewer in a browser 🦟 regression A thing that used to work in an earlier release labels May 23, 2023
@Wumpf
Copy link
Member Author

Wumpf commented May 23, 2023

... just noticed that zooming in in the api_demo depth offset demo still causes flickering 🤦

@Wumpf Wumpf marked this pull request as draft May 23, 2023 17:51
@Wumpf
Copy link
Member Author

Wumpf commented May 23, 2023

given that the hover preview also flickers this might have a different reason though!

@Wumpf
Copy link
Member Author

Wumpf commented May 23, 2023

it is for a different reason. doing this in a separate pr!

@Wumpf Wumpf marked this pull request as ready for review May 23, 2023 21:00
run_wasm/src/main.rs Outdated Show resolved Hide resolved
@Wumpf Wumpf merged commit 043b7a3 into main May 24, 2023
@Wumpf Wumpf deleted the andreas/fix-depth-offset2 branch May 24, 2023 09:19
emilk pushed a commit that referenced this pull request May 25, 2023
* run-wasm no longer pops up browser when running with --build-only

* add depth offset example

* mitigate depth issues on web

* deterministic order of depth offset determination

* inverte negative if
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🪳 bug Something isn't working 🦟 regression A thing that used to work in an earlier release 🕸️ web regarding running the viewer in a browser
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants