45 Commits

Author SHA1 Message Date
libretroadmin
51d238875e Get rid of obsolete HAVE_VIDEO_LAYOUT - obsolete spec, was only
ever implemented for OpenGL2 driver, lots of code debt, best to
instead just keep improving the overlay system instead which is
already available for most video drivers
2023-02-23 21:03:41 +01:00
libretroadmin
7ebab640d7 Cleanups/style nits 2023-02-23 13:15:14 +01: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
5166eebcaf for loop cleanups - use space after 'for' 2020-08-19 03:06:22 +02:00
twinaphex
72afa2f932 Cleanups 2020-08-03 16:33:54 +02:00
twinaphex
3e41cbc381 Revert "Add get_metrics to poke interface"
This reverts commit 119689c9405b5e4a321fafc340f6f0294b0338c3.
2020-08-02 23:44:28 +02:00
twinaphex
119689c940 Add get_metrics to poke interface 2020-08-02 19:25:45 +02:00
twinaphex
60f3265017 Cleanups 2020-07-27 13:16:14 +02:00
twinaphex
9ace693ec0 Refactor menu_driver_frame 2020-05-19 16:20:43 +02:00
twinaphex
f4c5036c3c Get rid of video_frame_info dep for fonts 2020-03-10 03:24:59 +01:00
twinaphex
3aa8afd60d (gfx/drivers) Further cleanups 2020-03-07 18:05:50 +01:00
twinaphex
ec302bc4fc video_set_nonblock_state - remove settings dependency 2020-02-16 22:26:07 +01:00
twinaphex
f0e889b552 Change prototype of video_driver_set_size 2020-01-31 15:06:50 +01:00
twinaphex
f92a507a9b Change function signature of font_driver_render_msg 2020-01-04 16:24:14 +01:00
twinaphex
65b4c2595e Update set keyboard mapping code for input driver 2019-07-27 02:21:24 +02:00
twinaphex
6aed230930 Reimplement 'Take Screenshot' - if GPU-accelerated viewport screenshots
are not available, resort to raw screenshots instead
2019-05-22 07:08:11 +02:00
Huw Pascoe
2c56011f84 video_layout interface 2019-05-11 09:58:48 +01:00
twinaphex
f67bfa24ef Get rid of video_poke_interface set_mvp 2019-03-18 15:19:11 +01:00
twinaphex
fe1255094f Get rid of now unused set_coords in video_driver_poke_interface 2019-03-18 05:04:23 +01:00
orbea
28ff4b391a Clean up white space. 2019-02-03 16:00:50 -08:00
twinaphex
f21493947d vim - add RetroArch style conventions 2018-09-15 17:43:34 +02:00
misson20000
abd86058c6 fix attribution (it's a common mistake) 2018-09-15 03:28:08 -07:00
twinaphex
0158bbe4aa Add switch_nx_gfx.c 2018-09-12 21:44:53 +02:00
misson20000
1404b63219 fix for tearing (depends on libtransistor commit cf5d0403 in v2.0.0, which is yet to be released) 2018-05-30 18:04:58 -07:00
twinaphex
c4c8699ee3 Only show max swapchain images if supported by video driver and/or
context driver
2018-04-23 13:34:30 +02:00
Brandon Wright
7a00534378 Add poke interface for get_refresh_rate. 2018-04-15 17:56:11 -05:00
twinaphex
9b8713aebd Fix Coverity defects 2018-03-24 11:59:01 +01:00
twinaphex
4d1b4f905f Start adding OSD statistics - doesn't work yet for SDL2/SDL 2018-03-23 17:43:49 +01:00
misson20000
e934f11065 NSW: skip frames if we can't acquire a buffer (newer libtransistors use three buffers, making this very unlikely to happen) 2018-03-06 20:55:40 -08:00
misson20000
4a4de74518 NSW(gfx): clear image row-by row for better caching (it's seriously a LOT faster), do pixel format conversion in scalers, and remove timing debug messages 2018-03-06 19:52:03 -08:00
misson20000
90c36c52ce NSW: fix graphics driver colors for rgb32 and don't break aspect ratio when scaling menu texture 2018-03-05 23:45:28 -08:00
misson20000
7487d938b3 NSW: remove global state in graphics driver, as it is no longer necessary 2018-03-05 20:14:52 -08:00
twinaphex
7dcd46a20f Get rid of HAVE_MENU ifdefs for video_driver_poke interface 2018-01-30 22:14:47 +01:00
twinaphex
bb1fdad0d9 (Switch) Replace malloc() with calloc() in switch_gfx.c 2018-01-23 06:48:10 +01:00
misson20000
5f8c888e0f [NSW] remove checks for running under Mephisto, since not only do they prevent us from running under Yuzu, but we don't have libtransistor_context anymore 2018-01-22 20:36:32 -08:00
twinaphex
7e9945cde9 Buildfix 2018-01-09 23:47:13 +01:00
SaltyFist
ad695a8b72 (switch) Add support for RETRO_PIXEL_FORMAT_XRGB8888 2018-01-04 07:28:17 +01:00
misson20000
a039e6c41e (NSW) temporary fix for graphic buffer dequeue failure 2018-01-04 07:28:12 +01:00
twinaphex
cf3a010ead Remove some HAVE_MENU ifdefs 2017-12-31 17:42:07 +01:00
misson20000
be5ebbc039 (NSW) since we haven't yet gotten the OS graphics driver, upon calling display_finalize, to release some of the (currently global) resouces we give it when we initialized it, we need to maintain a little bit of global state in the graphics driver so it can be freed and reinitialized when we load a core. this should be able to be reverted when we implement alloc_pages in libtransistor. see https://github.com/reswitched/libtransistor/issues/74 and https://github.com/reswitched/libtransistor/issues/69 2017-12-31 03:04:15 +01:00
misson20000
6254ddecf2 (NSW) initial support for menu 2017-12-30 11:14:45 +01:00
twinaphex
893cd2b472 Make this C89-compatible 2017-12-29 04:46:13 +01:00
misson20000
3101ee8036 (NSW) fix compilation errors and warnings for switch drivers 2017-12-29 04:45:25 +01:00
twinaphex
5c876647ed (NSW) Small cleanups 2017-12-29 00:45:00 +01:00
misson20000
6d2a7b1f26 Nintendo Switch (libtransistor) port 2017-12-29 00:10:01 +01:00