324 Commits

Author SHA1 Message Date
Themaister
a058c78fd0 Attempt to fix validation errors with HDR swapchain.
Always use final render pass type equal to swapchain format. Use more
direct logic to expose if filter chain emits HDR10 color space or not.
2022-08-31 21:59:25 +02:00
Themaister
3a25b53175 Fix more validation errors. 2022-08-31 21:03:07 +02:00
Themaister
f508a6a87f Fix some potential validation errors in HDR code. 2022-08-31 19:57:54 +02:00
Themaister
f9eda02a74 Fix leak of HDR UBO buffer. 2022-08-31 19:46:11 +02:00
Themaister
d6413f2a43 Automatically mark buffer/images/memory with names. 2022-08-31 19:46:11 +02:00
libretroadmin
9dd1fb895b - Turn rotation arrows static where possible
- Don't call matrix_4x4_rotate_z - inline the code instead
2022-07-04 15:28:54 +02:00
Ophidon
4c934e66d5
Fix BFI Regression 2022-05-29 00:51:28 -04:00
libretroadmin
66a2a12766 (Vulkan) Move functions to proper place where they're used
and turn them static
2022-05-21 01:40:23 +02:00
libretroadmin
af89df2b82 (Vulkan) Some C89_BUILD fixes 2022-05-19 15:47:45 +02:00
libretroadmin
493b8fdef8 (Vulkan) Style nits/cleanups 2022-05-19 15:43:51 +02:00
libretroadmin
eaabfefcb0 (Vulkan) Cleanups 2022-05-19 15:28:26 +02:00
libretroadmin
6f156d064e (Vulkan) vulkan_transition_texture - get rid of early return 2022-05-18 16:48:23 +02:00
libretroadmin
bfa627737e (D3D/Vulkan) Try to prevent implicit memsets 2022-05-16 21:37:02 +02:00
twinaphex
3873af37c6 (Vulkan) Turn this code into a switch instead of several conditionals 2022-04-02 19:10:56 +02:00
twinaphex
65b8ec4cef (Vulkan) Fix crashes 2022-04-02 19:02:54 +02:00
twinaphex
a7569b5712 More CXX_BUILD buildfixes 2022-03-30 15:45:48 +02:00
twinaphex
c8d57fe667 (CXX_BUILD) Some CXX_BUILD fixes 2022-03-30 15:13:28 +02:00
MajorPainTheCactus
f3bda542d6 Fixed crash when using stock shader and HDR and previous optimisation 2022-03-15 05:44:07 +01:00
MajorPainTheCactus
32b8560858 Removed redundant copy of buffer in HDR mode if the shader has already a HDR format i.e R10G10B10A2 2022-03-15 05:44:07 +01:00
Colin Kinloch
3e3cf904ca
(Vulkan) Double combined image sampler descriptor pool size (#13467) 2022-01-10 09:10:11 +01:00
MajorPainTheCactus
ad4f6176ff
Vulkan driver fixes for HDR (#13468)
* Fixed crash on boot with xmb and vulkan driver Fixed wrong blend state affecting the ribbon shader Fixed up C++ style comments with C style

* Fixed compilation issue - I made a last minute change and thought I had compiled it but obviously hadn't! No wonder it worked.
2022-01-10 06:26:02 +01:00
MajorPainTheCactus
1a228a4e78
Added HDR support to Vulkan driver (#13456) 2022-01-08 13:22:34 +01:00
Nikos Chantziaras
be650a790c
Add option for showing the overlay behind the menu (#13360)
* Add option for showing the overlay behind the menu

This commit lays the groundwork for this option. Support for this option
in the video drivers themselves is going to be added in later commits.

* gl1: Add overlay behind menu support

* gl2: Add overlay behind menu support

* gl3: Add overlay behind menu support

* vulkan: Add overlay behind menu support

* ctr: Add overlay behind menu support

* d3d9: Add overlay behind menu support

* d3d10: Add overlay behind menu support

* d3d11: Add overlay behind menu support

* d3d12: Add overlay behind menu support

* CHANGES.md: overlay behind menu

Co-authored-by: MrHuu <MrHuu@users.noreply.github.com>
Co-authored-by: Tony <45124675+sonninnos@users.noreply.github.com>
2021-12-26 04:56:44 +01:00
Tony
09880e92d2
Logging cleanups (#13320) 2021-12-04 14:21:12 +01:00
Hans-Kristian Arntzen
ce8a3db4dc
Avoid hard crash when capturing screenshot in emulating mailbox. (#13315)
The emulating mailbox infrastructure is very hacky and needs a rethink
to be able to properly support screenshots. emulating mailbox is pretty
nasty to begin with and should be considered a hack.
2021-12-03 16:19:49 +01:00
twinaphex
0b768d0460 Split up recording code 2021-11-10 02:34:04 +01:00
Francisco Javier Trujillo Mata
3bbfcf7b39 Adding to get_video_output_size 2 parameters for additional info 2021-10-04 23:53:55 +02:00
Autechre
7b9cbc08d7
Add HDR support for D3D12 (rebased PR from MajorPainTheCactus) (#12917)
* Add HDR support

* Attempt to fix Mingw build and Metal builds

* (D3D12) Fix relative header includes

* Add missing hdr_sm5.hlsl.h

* (d3d12_common.c) Some C89 build fixes

* Fix MSVC build

* - Attempt to fix build on mingw/msys unix with dirty hack
- Fix shader compilation of hdr_sm5.hlsl.h on MSVC/Visual Studio -
the define was seen as an error and was causing the first pipeline
to error out
- Make sure we manually set handle of backBuffer to NULL

* Moving the release of the texture above the freeing of desc.srv_heap
and desc.rtv_heap solves the hard crashes on teardown/setup in RA -
it was crashing hard in d3d12_release_texture before

* Add HAVE_D3D12_HDR ifdef - needs to be disabled for WinRT for now
because of several things that are Windows desktop-specific right now
(GetWindowRect)

* Add dirty GUID hack - should work for both mingw/msys on Windows/Linux
as well as MSVC/Visual Studio (hopefully)

* Change HAVE_D3D12_HDR to HAVE_DXGI_HDR

* Move away from camelcase named variables

* Fix RARCH_ERR logs - they need a newline at the end

* d3d12_check_display_hdr_support - make it return a bool on return
and set d3d12->hdr.support and d3d12->hdr.enable outside of the
function

* (DXGI) Remove D3D12 dependencies from dxgi_check_display_hdr_support and
move it to dxgi_common.c instead

* (DXGI) move d3d12_swapchain_color_space over to dxgi_common.c and
rename it dxgi_swapchain_color_space

* (DXGI) move d3d12_set_hdr_metadata to dxgi_common.c and
rename it dxgi_set_hdr_metadata

* (DXGI) dxgi_check_display_hdr_support - better error handling?

* Fix typo

* Remove video_force_resolution

* (D3D12) Address TODO/FIXME

* (D3D12) Backport
c1b6c0bff2
- Fixed resource transition for present when HDR is off
Fixed cel shader displaying all black as blending was enabled when the hdr shader was being applied - turned off blending during this shader

* Move d3d12_hdr_uniform_t to dxgi_common.h and
rename it dxgi_hdr_uniform_t

* (D3D11) Add HDR support

* Add TODO/FIXME notes

* Cache hdr_enable in video_frame_info_t

* Update comment
2021-09-03 06:15:25 +02:00
twinaphex
bf2e7b93f0 (Vulkan) Fix Vulkan validation layer - fix thanks to flyinghead -
see comments
2021-08-29 20:39:22 +02:00
Autechre
a04fe66032
Merge pull request #12380 from stenzek/vulkan-software-fb
(video/vulkan) Avoid caching stale mapped GPU texture as frame data
2021-05-18 18:01:47 +02:00
jdgleaver
484c4ad51e Add API extension for cores to override frontend fast-forward state 2021-05-13 13:16:37 +01:00
Stenzek
c9aaf598bb (video/vulkan) Avoid caching stale mapped GPU texture as frame data
At best, this results in junk on screen, at worst we could crash.

It's not a perfect fix, there's still a scenario where this breaks: when
fast forwarding is enabled, and we swap from vsync-off to vsync-on when
pausing/rendering the menu, the swap chain (and textures) gets
recreated, and the frame data is completely lost.

There isn't much we can do about this without more intrusive changes,
such as preserving the textures inbetween swap chain reinits.
2021-05-11 09:49:39 -07:00
twinaphex
32a6bd021c Prevent 'may be used uninitialized' warning 2021-03-22 15:46:34 +01:00
sonninnos
6c3c2bea5f Logging cleanups 2021-02-18 18:35:31 +02:00
twinaphex
d55ca599e0 Replace with macros 2020-12-15 07:28:39 +01:00
twinaphex
cdca5d0afc Turn vulkan_copy_staging_to_dynamic into macro 2020-12-15 07:20:33 +01:00
twinaphex
d70420a12d vulkan_copy_staging_to_dynamic - put sync texture to GPU
outside of the function
2020-12-15 07:01:00 +01:00
twinaphex
6b38a7916a (Vulkan) Simplify code 2020-12-15 06:19:48 +01:00
twinaphex
44b7234756 Move cheat_manager and state_manager to root folder 2020-10-15 05:29:20 +02:00
twinaphex
a11a0eae77 (Vulkan) Style nits 2020-10-12 01:36:50 +02:00
twinaphex
5c76ccbe4a Cleanups 2020-10-12 01:26:51 +02:00
Ophidon
05c5bdf587 C89 Compliance
For loop iterators updated for C89 compliance.
2020-09-19 13:28:21 -04:00
Ophidon
2f36c94f3f Variable BFI
BFI support added for 180hz / 240hz / etc. Solves issue with image retention from voltage issues at 120hz BFI. Also disabled BFI while in menu, as if set to an incorrect value for the current refresh rate, could cause severe flickering and difficulty reverting to the correct value.
2020-09-18 11:57:32 -04:00
jdgleaver
55b6d8ba15 Miscellaneous overlay fixes 2020-09-11 17:00:44 +01:00
twinaphex
bb58b0d6e3 (GLSLANG) Move more common code out of shader_gl_core and shader_vulkan
and into glslang_util.h
2020-08-16 02:05:38 +02:00
twinaphex
72afa2f932 Cleanups 2020-08-03 16:33:54 +02:00
twinaphex
85e5c783af Backport getting rid of video_context_driver_input_driver 2020-08-03 00:47:58 +02:00
twinaphex
deee393dfb Backport video_context_driver_free changes 2020-08-03 00:35:07 +02:00
twinaphex
3e41cbc381 Revert "Add get_metrics to poke interface"
This reverts commit 119689c9405b5e4a321fafc340f6f0294b0338c3.
2020-08-02 23:44:28 +02:00
twinaphex
da5806a810 Revert "Cleanups"
This reverts commit a01a2375a18bdabba2ead7de693e94cddb2622db.
2020-08-02 23:43:56 +02:00