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

Add dynamic VRS option that generates VRS density map with a shader #99916

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

BastiaanOlij
Copy link
Contributor

This PR adds a VRS mode that builds the density map fully in our shader. No data needs to be calculated on the CPU and transferred to the GPU. This removes a lot of overhead and will allow us to more easily adjust the density map based on performance metrics.

Ideally we deprecate VRS_XR in favour of this once its completed.

Still todo:

  • Detect changes and skip drawing if nothing changed from previous update.
  • Add settings that allow control by the developer (ranges for mix/max radii).
  • Figure out a way to vary the radii based on current performance metrics.

Note: Build on top of #99551

Co-Authored-By: Bastiaan Olij <mux213@gmail.com>
@BastiaanOlij
Copy link
Contributor Author

Still working on this but @DarioSamo @dsnopek , could love some early feedback.

PackedVector2Array eye_centers = interface->get_vrs_eye_foci(aspect_ratio);

// Need to vary these based on performance:
float min_radius = 0.1;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note, these are hardcoded for now and the values are, uhm. not very well chosen. We'll need to experiment with values that work well and then see how we can vary them based on performance metrics.

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

Successfully merging this pull request may close these issues.

2 participants