Browse Source
[vulkan, android] Mediacodec implementation + Vulkan fixes (#4191)
[vulkan, android] Mediacodec implementation + Vulkan fixes (#4191)
This is the first step into the conversion on full GPU video decoding for Android; currently due to the VIC structure, I couldn't set it on surface mode to prevent the latency when sending video decoded (which is processed by GPU now), because currently we convert YUV420 into the Nvidia's format each frame constantly on CPU, aside the requirements from other extensions to work + VIC rewrite, which is a work currently not planned to happen on this PR; the actual configuration for video decoding is ByteBuffer, using GPU to decode NVDEC data (all codecs supported, h264, vp8 and vp9) and send it to CPU for display purposes, which is more faster than relying purely on CPU for any drawing task, saving devices resources/ heating, the downside on this will be the slight latency when a new frame is displayed, which is gonna be a black frame for less than a second, nothing major to harm the experience rather than actually trying our best to take advantage on hardware accelerated. Aside this, I also added a bunch of minor Vulkan fixes to grant drivers less thinkering when receiving spir-v instructions, meaning this has new bans for extensions on QCOM (following reported issues on other projects working around Adreno driver behavior), this more than providing performance aims to enhance the stability on the driver, performance it's gonna likely to be hit based on the UBO's (StorageBufferAccess) operations and SSBO (uniformStorageBufferAccess), there was an already existing path for the emulation which forces to wide them into 32bit packed operations. I also included some smaller changes/ bugs + VUID's fixes from earlier changes on my work. Special Thanks: -> Mr. Smoly Gidolard (@gidoly) Sources: 1.- https://github.com/microsoft/DirectXShaderCompiler/issues/2842 2.- https://github.com/mlc-ai/web-llm/issues/836 3.- https://github.com/ggml-org/llama.cpp/issues/5186 4.- https://github.com/encounter/aurora/pull/202 Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/4191lizzie/bitfield-fix-wawawa-msvc
committed by
crueter
No known key found for this signature in database
GPG Key ID: 425ACD2D4830EBC6
33 changed files with 495 additions and 92 deletions
-
5externals/ffmpeg/CMakeLists.txt
-
2src/android/app/src/main/jni/CMakeLists.txt
-
11src/android/app/src/main/jni/native.cpp
-
3src/common/android/id_cache.cpp
-
2src/common/android/id_cache.h
-
2src/shader_recompiler/backend/spirv/emit_spirv.cpp
-
23src/shader_recompiler/backend/spirv/emit_spirv_memory.cpp
-
3src/shader_recompiler/backend/spirv/emit_spirv_shared_memory.cpp
-
42src/shader_recompiler/backend/spirv/emit_spirv_warp.cpp
-
15src/shader_recompiler/backend/spirv/spirv_emit_context.cpp
-
7src/shader_recompiler/profile.h
-
66src/video_core/host1x/codecs/decoder.cpp
-
8src/video_core/host1x/codecs/decoder.h
-
4src/video_core/host1x/codecs/h264.cpp
-
1src/video_core/host1x/codecs/vp8.cpp
-
1src/video_core/host1x/codecs/vp9.cpp
-
169src/video_core/host1x/ffmpeg.cpp
-
29src/video_core/host1x/ffmpeg.h
-
1src/video_core/host1x/nvdec.cpp
-
9src/video_core/host1x/vic.cpp
-
1src/video_core/host1x/vic.h
-
4src/video_core/renderer_vulkan/pipeline_helper.h
-
6src/video_core/renderer_vulkan/vk_compute_pass.cpp
-
25src/video_core/renderer_vulkan/vk_compute_pipeline.cpp
-
3src/video_core/renderer_vulkan/vk_compute_pipeline.h
-
18src/video_core/renderer_vulkan/vk_pipeline_cache.cpp
-
5src/video_core/renderer_vulkan/vk_query_cache.cpp
-
53src/video_core/renderer_vulkan/vk_texture_cache.cpp
-
17src/video_core/renderer_vulkan/vk_texture_cache.h
-
17src/video_core/vulkan_common/vulkan_device.cpp
-
14src/video_core/vulkan_common/vulkan_device.h
-
18src/video_core/vulkan_common/vulkan_wrapper.cpp
-
3src/video_core/vulkan_common/vulkan_wrapper.h
Write
Preview
Loading…
Cancel
Save
Reference in new issue