Commit graph

126 commits

Author SHA1 Message Date
Henrik Rydgård
7c4b9bac90 Cache textures created by MakePixelsTexture and reuse where appropriate. 2023-05-30 14:07:44 +02:00
Henrik Rydgård
ad8827ae70 Cleanup, address feedback 2023-05-26 10:28:10 +02:00
Henrik Rydgård
6cee08c74f Post-processing: Fix using limited UV ranges when there's a single upscaling filter in the chain.
Fixes #17499
2023-05-26 09:48:51 +02:00
Henrik Rydgård
02880d7d7d Less broken behavior with integer scale factor + auto render resolution
Unfortunately these don't make the same decision (integer scale factor
tries to make sure the whole image can fit in the window, while auto
render resolution is glad to step up a level), but at least the user is
not faces with a black screen.

Not sure what's actually the best thing here, possibly this case should
be disallowed somehow.
2023-04-30 10:18:47 +02:00
Henrik Rydgård
88899984e3 Correctly pass un-rotated width/height to presentation pipeline. 2023-04-11 22:27:26 +02:00
Henrik Rydgård
652612cf15 Fix issue in present where we applied the UV range at the wrong place when post-processing.
Fixes #17249
2023-04-11 22:27:26 +02:00
Henrik Rydgård
4f6e5e73a6 PresentationCommon: Simplify Y flip handling.
Don't manipulate the UVs, manipulate the vertex coordinates instead.

This will simplify the next change that will fix the pixel accuracy
problems in post-processing.
2023-04-10 21:58:34 +02:00
Henrik Rydgård
d26700820c Minor buildfix/cleanup 2023-04-09 22:47:34 +02:00
Henrik Rydgård
d630d3c751 Presentation: Switch from indexed trilist to plain tristrip
Insignificant performance difference, but nice to get rid of the index
buffer.
2023-04-08 13:02:18 +02:00
Henrik Rydgård
cf28556d6d When integer scaling, take the internal render resolution into account. 2023-04-05 09:48:28 +02:00
Henrik Rydgård
c08c711006 Fix portrait mode integer scaling 2023-04-02 22:35:51 +02:00
Henrik Rydgård
d223d3c316 Rename CenterDisplayOutputRect to CalculateDisplayOutputRect 2023-04-02 22:29:08 +02:00
Henrik Rydgård
2fa93982ea Add support for integer scale factor for display
This is mainly useful if you want an authentic pixellated look with 1x
rendering (or software) and nearest display filter. It'll simply round
down the auto-scaled sized to the nearest integer scale factor,
configuring exactly which one isn't that interesting since they all are
gonna look good.

Fixes #17093
2023-04-02 22:29:08 +02:00
Henrik Rydgård
d586ec0d5e Don't create Host objects except in headless/unittest 2023-03-25 10:47:01 +01:00
Henrik Rydgård
9e125eeba7 Remove NotifyUserMessage from Host 2023-03-25 10:32:09 +01:00
Henrik Rydgård
3b39e9e068 Turn the VFS into a class, to be able to reuse it for other purposes. 2023-03-06 16:42:47 +01:00
Henrik Rydgård
8b431b39ba
Wrap the display globals in a struct (#16998)
* Wrap the display globals in a struct

Makes it easier to search/replace these, for future refactorings.

* Some renaming

* Qt buildfix, also fix the Qt build on Mac (got broken with battery changes)

* Attempt at buildfixing ios

* UWP buildfix
2023-02-25 13:09:44 +01:00
Henrik Rydgård
49e5460c9c Remove count parameter from SetViewports. No use foreseen. 2023-02-25 07:12:53 +01:00
Unknown W. Brackets
fe470c790e Postshader: Reset ini keys for defaults.
Should fix the Vignette shader defaults, see #16562.
2022-12-12 19:11:20 -08:00
Unknown W. Brackets
f202029d0b Postshader: Don't save default setting values.
This way the defaults can change in the future without problems.
2022-12-12 19:09:14 -08:00
Lubos
df01f18aa6 Merge branch 'master' into config_openxr_update 2022-12-10 10:20:29 +01:00
Henrik Rydgård
4280a9f51c Force postshaders with the usePreviousFrame flag to the end of the order 2022-12-09 17:19:08 +01:00
Henrik Rydgård
70ce76a8d5 Delete the builtin Grayscale shader. Also make unknown shaders go away from list. 2022-12-07 22:28:55 +01:00
Lubos
d0e6f480a9 Merge branch 'master' into config_openxr_update 2022-12-04 18:04:08 +01:00
Lubos
0060a14fa7 OpenXR - Adjust the render resolution for VR 2022-12-02 20:48:35 +01:00
Henrik Rydgård
e3679df6cf Fix switching between MSAA levels 2022-12-01 22:49:00 +01:00
Henrik Rydgård
06af304c8d Multisampling groundwork 2022-12-01 22:49:00 +01:00
Henrik Rydgård
331d024a8c Add a flags parameter to InvalidateCachedState and rename it Invalidate.
Also rename the old InvalidationFlags enum to InvalidateCallbackFlags.
2022-12-01 19:15:38 +01:00
Lubos
164c27f5ec OpenXR - Screen stretching fixed 2022-11-28 19:25:13 +01:00
Henrik Rydgård
200e2f26c4 OffsetY fix for non-vulkan backends 2022-11-27 22:58:49 +01:00
Henrik Rydgård
d667bd84a3 Add back the old stretch-if-close-to-16:9 hack 2022-11-27 16:16:18 +01:00
Henrik Rydgård
bdfde4cbac Implement the new screen sizing parameters 2022-11-27 16:16:04 +01:00
Lubos
db8b159d9e OpenXR - Force PSP menu aspect ratio 2022-11-17 17:30:29 +01:00
Henrik Rydgård
b4507cd5cc Make a lot more code VR build for all platforms 2022-11-06 14:36:51 +01:00
Henrik Rydgård
8e0b82f92e Address feedback 2022-10-28 17:42:21 +02:00
Henrik Rydgård
10eb21d3b3 Add some extra checking for valid stereo shader. 2022-10-28 10:17:29 +02:00
Henrik Rydgård
763afd4a8e Improve compatibility checks for stereo rendering. 2022-10-27 11:05:59 +02:00
Henrik Rydgård
524e92374f Use arrays more consistently. 2022-10-27 11:05:59 +02:00
Henrik Rydgård
6af4644ab2 Stereo on mobile fixes 2022-10-27 11:05:58 +02:00
Henrik Rydgård
0de12f5ca9 Some refactoring of framebuffer views, layer issues, more work. 2022-10-27 11:05:58 +02:00
Henrik Rydgård
2e87f0bc0b More work. Things are starting to work now. 2022-10-27 11:05:58 +02:00
Henrik Rydgård
c668736924 Add a couple of stereo display shaders, add infrastructure, compile stereo pipelines 2022-10-27 11:05:58 +02:00
Henrik Rydgård
fb250c4b29 More multiview work 2022-10-27 11:05:58 +02:00
Henrik Rydgård
6aa3e4b242 Minor refactoring in PresentationCommon
Broken out from stereo work
2022-10-21 15:53:09 +02:00
Henrik Rydgård
f2193814ee PresentationCommon: Use refcounts to simplify shader module management 2022-10-21 14:18:29 +02:00
Henrik Rydgård
90d395a10d Remove "attachment" parameter from BindFramebufferAsTexture everywhere.
Not actually useful since our framebuffer objects don't support multiple
color images, and probably won't ever need to.
2022-10-20 10:15:19 +02:00
Henrik Rydgård
aa51bfd1ef Use GPU "use" flags to replace IsVRBuild in the renderer. It remains elsewhere. 2022-10-17 19:57:11 +02:00
Henrik Rydgård
347f7c4e5a Vulkan: Improve tagging of pipelines for debugging purposes 2022-09-08 00:47:22 +02:00
Lubos
c2c0561be2 OpenXR - OPENXR ifdef removal 2022-08-27 17:33:37 +02:00
Henrik Rydgård
416d8b403b
Merge pull request #15768 from lvonasek/feature_openxr_6dof
OpenXR - 6DoF support
2022-08-24 18:49:41 +02:00