Wunkolo
89f3eb3a87
Add simple graphics pipeline creation
...
This will eventually need to move into a cache, but this is introducing
some foundational patterns so that we know how to properly design a
pipeline cache. Currently does not provide a `DescriptorSetLayout`
argument. Causing validation errors. This will be a general-case cache
right from the get-go.
2023-08-20 23:01:43 -07:00
Wunkolo
13e52ac047
Add shader-module loading
...
Loads spirv files from the embedded virtual file system and loads them
into vulkan shader-modules.
2023-08-20 23:01:43 -07:00
Wunkolo
4b193c8d6b
Add general purpose vulkan render cache
...
Takes in a general `vk::Format` rather than PICA-types
2023-08-20 23:01:43 -07:00
Wunkolo
d4b75deaf8
Remove separate presentation/graphics command buffers
...
Now there is just one primary command buffer where all work is enqueued
into. At the end of the frame, the next frame's CPU-side fence is waited
on before resetting and beginning its command buffer again for
recording. This command buffer must always be in the RECORDING state.
2023-08-20 23:01:43 -07:00
Wunkolo
6052abe551
Fix swapchain synchronization issues
...
While we wait on the CPU-side fence for these command buffers, we must
also wait on the GPU-side semaphore to be compliant to validation
layers synchronization. We still get an error on the very first frame
since it will wait for a semaphore that has nothing signaling it.
2023-08-20 23:01:43 -07:00
Wunkolo
52ddaae221
Add getCurrentCommandBuffer
for all frame workloads
...
Rather than allocating new command buffers for each small task, schedule
all work onto the frame's main command buffer to be dispatched at
display-time. Fixes all layout transition and synchronization issues.
2023-08-20 23:01:43 -07:00
Wunkolo
cb8c53e0b8
Map RGB8 to RGBA8
...
RGB8 is not supported by drivers like RADV. Instead, we map it to RGBA8.
RGBA8 is mandated to be supported by the vulkan spec.
2023-08-20 23:01:43 -07:00
Wunkolo
9e2781e874
Refactor render-texture cache
...
Implement `displayTransfer` in parity with the OpenGL renderer. Allow
arguments to `get{Color,Depth}RenderTexture`.
2023-08-20 23:01:43 -07:00
Wunkolo
97b6b7f122
Add Vulkan Host-Shader compilation
...
Compiles Vulkan Host shaders into spirv binary files and embeds them
into the application's virtual file-system.
2023-08-20 23:01:43 -07:00
Wunkolo
f62f1bf9b2
Fix ambiguous extension name conversion
2023-08-20 23:01:43 -07:00
Wunkolo
cb64c52d2f
Use inline rotl
/ror
...
Fixes apple-clang builds, which do not implement a lot of the `bit`
header.
2023-08-20 23:01:43 -07:00
Wunkolo
c778c34433
Separate present/graphics workloads
...
Separate the "Display" texture from the cache of framebuffer textures,
move present/graphics into separate command buffers.
2023-08-20 23:01:43 -07:00
Wunkolo
50029e1333
Avoid usage of D24-S8 format
...
This support is not supported on `radv`. Vulkan mandates D16 only and a
combination of Depth and Depth-Stencil types only.
2023-08-20 23:01:43 -07:00
Wunkolo
27268f86d3
Fix instance-extension iteration
...
Add the extensions when they are available rather than statically
including them.
2023-08-20 23:01:43 -07:00
Wunkolo
6dcd09af3e
Implement basic color/depth render-texture cache
2023-08-20 23:01:43 -07:00
Wunkolo
a36ee0025f
Disable present queue when present unavailable.
2023-08-20 23:01:43 -07:00
Wunkolo
bf3917f074
Add subpass dependencies, optional depth attachment
2023-08-20 23:01:43 -07:00
Wunkolo
37902cd9d6
Implement a renderpass cache.
...
Technically we can generate every possible render-pass up-front based on
the possible combinations of ColorFmt and DepthFmt, but we should only
allocate what the game asks for. Save that pattern for pipelines.
2023-08-20 23:01:43 -07:00
Wunkolo
bf8bb5d459
Add vk_pica
translation unit
...
Intended for conversions and utils between PICA definitions and Vulkan.
2023-08-20 23:01:43 -07:00
Wunkolo
d19b8cf364
Separate frame-work from presentation
2023-08-20 23:01:43 -07:00
Wunkolo
4976671ef0
Rename vulkan_api.hpp
to vk_api.hpp
...
Consistant with other vulkan header patterns.
This header in particular is to configure our Vulkan API usage.
2023-08-20 23:01:43 -07:00
Wunkolo
ac1f7bc521
Remove dependency on C++20 ranges
...
AppleClang does not support this unfortunately
2023-08-20 23:01:43 -07:00
Wunkolo
e87db99a97
Remove ownership of SDL's vulkan-surface
...
This surface is managed by SDL itself, so there is no need to keep it in
a Unique handle for us to delete. Fixes the bug where vulkan crashes
during shutdown.
2023-08-20 23:01:43 -07:00
Wunkolo
e3699fe8f8
Allocate and present separate top/bottom screen framebuffer images
...
Instead of operating directly on the swapchain images, we have our own
top/bottom framebuffer images that will be rendered to independent of
having an available swapchain. The images are blitted into the swapchain
images, allowing for resizing too!
2023-08-20 23:01:43 -07:00
Wunkolo
d0832ca558
Fix support for headless vulkan context
2023-08-20 23:01:43 -07:00
Wunkolo
17101e9bb9
Fix graphics queue assignment
...
Copy-paste error
2023-08-20 23:01:43 -07:00
wheremyfoodat
d26789571c
Merge pull request #225 from wheremyfoodat/tsc
...
[Touchscreen] Properly handle "dragging" stylus across screen
2023-08-21 00:02:25 +03:00
wheremyfoodat
706503974c
[Touchscreen] Properly handle "dragging" stylus across screen
2023-08-20 23:42:55 +03:00
wheremyfoodat
9e0f590b79
Trying to switch to MacOS 10.15
2023-08-20 22:46:44 +03:00
wheremyfoodat
b26a801042
More complete PList
2023-08-20 22:41:24 +03:00
wheremyfoodat
d70a1ca7a8
Merge pull request #223 from wheremyfoodat/wheremyfoodat-patch-3
...
Add resource limit for threads to getResourceLimitLimitValues
2023-08-20 18:44:38 +03:00
wheremyfoodat
8796440ae9
Add resource limit for threads to getResourceLimitLimitValues
2023-08-20 18:27:23 +03:00
wheremyfoodat
bc47fe8f83
Merge pull request #222 from wheremyfoodat/wheremyfoodat-patch-4
...
Make SendSyncRequest warn instead of panic on invalid handles
2023-08-20 18:04:47 +03:00
wheremyfoodat
cce796ec0c
Make SendSyncRequest warn instead of panic on invalid handles
...
Some games like Arc Baseball use invalid handles...
2023-08-20 18:03:42 +03:00
wheremyfoodat
2669f80db7
Merge pull request #221 from wheremyfoodat/boss-getErrorCode
...
Add BOSS::GetErrorCode
2023-08-20 15:39:45 +03:00
wheremyfoodat
197bc93eec
Add BOSS:GetErrorCode
2023-08-20 15:07:19 +03:00
wheremyfoodat
73b9a909cd
Merge pull request #219 from wheremyfoodat/services
...
Implement HID::GetSoundVolume
2023-08-20 14:39:07 +03:00
wheremyfoodat
8aa35d2099
Implement HID::GetSoundVolume
2023-08-20 14:18:30 +03:00
wheremyfoodat
d4f074b231
Merge pull request #217 from wheremyfoodat/services
...
Add the GetThreadIdealProcessor SVC and fix UB
2023-08-20 03:58:07 +03:00
wheremyfoodat
3292b051be
[SDMH] Fix function not returning a value
2023-08-20 03:45:24 +03:00
wheremyfoodat
434827e11e
Add svcGetThreadIdealProcessor
2023-08-20 03:43:26 +03:00
wheremyfoodat
37667708e7
Merge pull request #216 from wheremyfoodat/services
...
Stub DLC::GetPatchTitleInfo to fail
2023-08-20 03:28:23 +03:00
wheremyfoodat
415a5bb8de
Add AM::RegisterDisconnectEvent
2023-08-20 03:27:10 +03:00
wheremyfoodat
977cb0403c
Stub DLC::GetPatchTitleInfo to fail
2023-08-20 03:08:34 +03:00
wheremyfoodat
bb64bbab40
Merge pull request #215 from wheremyfoodat/services
...
Stub update RomFS
2023-08-20 02:58:17 +03:00
wheremyfoodat
e5f96b7298
Stub update RomFS
2023-08-20 02:38:25 +03:00
wheremyfoodat
497ff5b96b
Merge pull request #214 from wheremyfoodat/wheremyfoodat-patch-3
...
Add missing log
2023-08-20 02:21:22 +03:00
wheremyfoodat
574fe95bca
Add missing log
2023-08-20 02:21:05 +03:00
wheremyfoodat
4fc94298a7
Merge pull request #213 from wheremyfoodat/services
...
Implement the GetCurrentProcessorNumber SVC
2023-08-20 02:13:46 +03:00
wheremyfoodat
8a435cc36b
Add note about default processor ID
2023-08-20 01:55:41 +03:00