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 the option to force symmetric projections in games with shader issues. #163

Closed
kuby29 opened this issue Jan 23, 2024 · 4 comments
Closed
Labels
enhancement New feature or request rendering

Comments

@kuby29
Copy link

kuby29 commented Jan 23, 2024

certain shaders don't support the off-axis rendering that is necessary to display on certain VR headsets. this causes many weird visual issues on affected headsets (notably the clouds in ace combat 7, but there must be others.)

This could be addressed by forcing the renderer to render symmetrical projections, and adjusting the finished image after to compensate. This would have the drawback of cropping parts of the screens, a potential workaround for that would be to render beyond the visible area with a wider FOV, and zoom in the image to compensate. This would make it possible to work around the shader issues at the cost of some performance from the extra resolution.

@praydog
Copy link
Owner

praydog commented Jan 24, 2024

@fholger has given some advice on this subject in the past, and some of his mods make use of this. So I'll probably look into that

@praydog praydog added enhancement New feature or request rendering labels Jan 25, 2024
@mrbelowski
Copy link
Contributor

this is quite easy to do with OpenVR - you can override the projection matrix with a symmetrical one that uses the greater of each eye's left / right / top / bottom values then populate the existing VRTextureBounds_t left & right objects with the appropriate values to tell the compositor to use only a section of the eye texture.

This 'works' in so far as the projection looks correct and when toggling this on and off, you can see a slight difference in resolution (because it's submitting only part of the rendered scene).

There are 2 major issues. In the game I tried (Vampyr) it doesn't appear to make any difference - the fog is still only rendered in the left eye so I guess there's some other issue with that shader. It's also much less straightforward to do this with OpenXR. I don't think the submit process gives the same level of control but I'm no expert

@mrbelowski
Copy link
Contributor

#196

@praydog
Copy link
Owner

praydog commented Mar 20, 2024

Added in 9074c01

under Compatibility options.

@praydog praydog closed this as completed Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request rendering
Projects
None yet
Development

No branches or pull requests

3 participants