Commit Graph

134 Commits

Author SHA1 Message Date
flyinghead c889bfa6d4 dx9: copy to vram. clipping. fix depth/stencil size. better reset
Coordinate device reset with dxcontext. Keep compiled shaders.
Don't use automatic depth/stencil on backbuffer. Manually handle it.
Implement scissoring/clipping
multipass translucent depth
Render-to-texture copy to vram
2021-04-15 15:17:32 +02:00
flyinghead f107d380b9 WIP directx9 renderer 2021-04-12 22:49:04 +02:00
Flyinghead 4a8ce39bfd vk: use a single command buffer for all texture updates 2021-04-08 10:38:26 +02:00
Flyinghead 1e6874c5eb SDL2/SDL.h -> SDL.h 2021-03-21 20:07:53 +01:00
Flyinghead 06be0d927b screen stretching always in final horiz direction. lightgun coords fix
gl: strech direct fb texture based on stretching and rotation
Fix lighgun coords when stretching and/or rotating
Dimension render size based on stretching and rotation
vk: lightgun crosshair disappears near 0-edge -> scissoring x and y must
be >= 0
always stretch horizontally even when rotating
2021-03-21 18:03:22 +01:00
Flyinghead 1abfa19636 set rendering resolution in discrete steps instead of scaling 2021-03-21 18:03:22 +01:00
scribam 913fbef952 clang-tidy: run readability-inconsistent-declaration-parameter-name and improve parameter names 2021-03-15 19:52:54 +01:00
scribam 26ebcdf9f5 clang-tidy: run modernize-use-equals-default 2021-03-14 21:52:42 +01:00
scribam fe17d79e8d clang-tidy: run performance-unnecessary-value-param 2021-03-13 17:28:33 +01:00
scribam af0c267d96 clang-tidy: run modernize-use-emplace 2021-03-13 17:28:32 +01:00
scribam d715836c40 clang-tidy: run modernize-use-override 2021-03-13 17:28:32 +01:00
flyinghead 99e37500e9 vk: renderer wasn't always resized when window is
Issue #199
2021-03-08 21:04:51 +01:00
flyinghead 0e20d5976b vram texture locks race condition 2021-03-05 18:22:42 +01:00
flyinghead 8259b8ba02 x86 msvc build fix. Build 32bit SDL. Force renderer type at startup 2021-03-01 12:49:41 +01:00
Flyinghead c3a95594f9 New option system
Fix per-game settings (Issue #115)
Automatic load/save state (Issue #173)
Reload Naomi/AW BIOS after per-game settings are loaded to allow
per-game BIOS region. (Issue #96)
Restrict Soul Reaver widescreen cheat to the EU version (Issue #188)
Disable UI elements for overridden settings
Clean up/simplify legacy Naomi ROM loading
2021-03-01 10:13:40 +01:00
Flyinghead 859a8dc8fb vulkan: wrong viewport with widescreen and SSAA x2
Issue #172
2021-02-21 08:33:31 +01:00
Flyinghead 1a8b25cc34 vk: bump sampler pool size. use swap chain size 3. no mailbox on AMD
Increase descriptor set pool size for combined image sampler to
accomodate for games using a stupidly large number of textures.
Don't use mailbox mode on AMD as it needs 5(!) swap chain images on
linux.
Return to a swap chain size of 3 since it's the min for AMD.
2021-02-01 12:04:55 +01:00
Flyinghead a71c897d56 vk oit: crash when rendering to texture 2021-01-31 17:30:34 +01:00
flyinghead 562660134e vulkan: fix resize crash with overlay 2021-01-26 18:12:37 +01:00
flyinghead 7697d37ec6 lightgun crosshair support 2021-01-23 15:59:57 +01:00
flyinghead d217f5232a win32 and macOS fixes 2021-01-21 22:44:51 +01:00
flyinghead 16dec49e08 windows: use utf8 internally. Support latin2, cyrillic, etc. pathnames
upgrade libzip to 1.7
imgui: use all glyphs from font including latin2, cyrillic, greek, etc.
2021-01-19 11:11:01 +01:00
flyinghead 417b470cbb sdl: fall back to open gl if vulkan init fails 2021-01-16 19:09:22 +01:00
flyinghead 49627eaf53 vk: first framebuffer wasn't cleared 2021-01-16 18:50:54 +01:00
Flyinghead 1727413247 vulkan: fix crash on minimize and resize. clear framebuffer on resize
many vulkan fixes related to init/term/reset
2021-01-09 18:16:39 +01:00
Flyinghead 2c8b5aa7f8 vs2019 build tentative fix 2021-01-04 18:56:15 +01:00
Flyinghead 1a59f8bade vk: reset lastFrameView to nil when switching renderer
fix crash when switching per-tri/per-pix
2020-12-21 20:09:23 +01:00
Flyinghead 190ab6690a vk: create staging buffer for texture if null
Fixes SF3 double impact crash
better texture cache cleanup
2020-12-16 14:37:28 +01:00
Flyinghead c03cf8eb45 rend: multi-render, delay swap, refactor main ui loop
move ui loop out of hw/pvr
vk: implement multi-rendering, delay swap. Load fb before render pass
fps counter now counts frames, not renders
vk: force ignoreTexAlpha for 565 texture in case the supporting texture
has an alpha channel (RTT). Fixes Alone in the Dark cinematic scenes.
pvr: better detection of frame swapping (FB_R_SOF/FB_W_SOF)
pvr: synchronous rendering now always waits for render in progress
(speed measurement not reliable, render skipped when multi-rendering)
vk: limit swap chain size to 2
2020-12-15 15:09:42 +01:00
Flyinghead b147f71ffa fix crash with vulkan an android
compiler bug?
2020-12-08 15:45:39 +01:00
Flyinghead 8f77a5482a config/data folders improvements
linux: look for legacy ~/.reicast and ~/.reicast/data
else look for ~/.config/flycast and ~/.local/share/flycast
and ~/.config/reicast and ~/.local/share/reicast
(defaults to flycast)

look for bios files in home folder and data folders (android, windows
,macos), then in game folder.
on linux, search in /usr/share/flycast and /usr/local/share/flycast and
legacy locations
2020-11-26 16:45:57 +01:00
Flyinghead 7744e1a262 vk: use-after-free if inFlight texture is deleted or cache cleared 2020-11-24 18:01:09 +01:00
Flyinghead ee66afb7f6 vk: recreate swap chain if presentation failed. retry creation if fails 2020-11-20 21:13:18 +01:00
Flyinghead 47f262a2c6 vk: use normal pipeline for raw fb display
raw fb also needs to be rotated/scaled
oit: draw opaque polys on first frame
2020-11-19 22:29:06 +01:00
Flyinghead 4ecf43a08d vulkan: revert to using 3 swap images. fix crash when switching gl/vk
Fix Hello Kitty crash with empty first TR polygon
Fix Test Drive Le Mans crash on invalid textures
Fix wldkickspw crash with invalid TA data
2020-07-11 17:38:41 +02:00
Flyinghead 1713124711 vulkan: linear tiling for small texs. don't track in-flight texs
Linear tiling is faster for small, frequently updated textures
When lots of textures are updated each frame, a skipped frame will
destroy/recreate all textures, causing another skipped frame, etc. So
in-flight texture tracking is disabled, except for RTT textures
Limit swap chain to 2 images
Refactor base and oit renderers to avoid code dup
2020-07-10 18:50:53 +02:00
Flyinghead 7449230af8 handle some palette textures on the GPU
get rid of PixerPacker templates
no need for GLSL precision qualifier in GL4
2020-07-08 18:17:15 +02:00
Flyinghead fec79624df gl/gl4: simplify clipping. share code with vulkan 2020-05-11 16:11:31 +02:00
Flyinghead b907aa2d98 fix GLES2 build 2020-05-09 12:07:49 +02:00
Flyinghead 34575d577c fix sdl+egl build. get rid of USES_HOMEDIR. thread deadlock at exit
fix odroid xu3 build
sdl: use left or right alt+enter to maximize window
deadlock at exit if dc_exit called from emu thread
2020-05-08 18:41:36 +02:00
scribam 6ee4b6de85 Replace OS_DARWIN by __APPLE__ 2020-04-26 14:19:21 +02:00
Flyinghead 17a2c3644f ui: add loading screen with cancel button. don't freeze ui on load 2020-04-20 18:52:02 +02:00
Flyinghead 98b2a32eae naomi: auto-rotate screen, no widescreen when rot, lightgun as analog
rotate screen for naomi games that need it
disable widescreen when rotating screen
detect lightgun games and enable proper settings
disable model 3 comm board for atomiswave
2020-04-17 22:11:11 +02:00
Flyinghead 786c8e7744 get rid of libpng and use stb_image_write instead. OSX: static link SDL 2020-04-08 15:34:21 +02:00
Flyinghead d1b29a59d2 vulkan: re-enable vulkan 1.1 on Android. Fix TEST_AUTOMATION
disable vmem32 for Heroes of Might and Magic III
support no vmem in _vmem.cpp
2020-04-03 16:32:53 +02:00
scribam 769770ab81 Replace cMutex by std::mutex 2020-03-30 23:00:43 +02:00
scribam a155282fd0 Cleanup compiler warnings (mostly sign-compare) 2020-03-30 23:00:43 +02:00
scribam 4bf6802855 Cleanup include headers 2020-03-29 14:26:21 +02:00
scribam c731cbcaf8 deps/vulkan: Update vk_mem_alloc.h to version 2.3 2020-03-29 13:28:06 +02:00
scribam 0035871422 Replace RELEASE by NDEBUG 2020-03-29 10:12:32 +02:00