aboutsummaryrefslogtreecommitdiffstats
path: root/libavutil/vulkan.c
Commit message (Collapse)AuthorAgeFilesLines
...
* avutil/common: Don't auto-include mem.hAndreas Rheinhardt2024-03-311-0/+1
| | | | | | | | | | | There are lots of files that don't need it: The number of object files that actually need it went down from 2011 to 884 here. Keep it for external users in order to not cause breakages. Also improve the other headers a bit while just at it. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avutil/vulkan: Remove unused ff_vk_set_descriptor_sampler()Andreas Rheinhardt2024-03-031-27/+0
| | | | | Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avutil/vulkan: Make ff_vk_set_descriptor_image() staticAndreas Rheinhardt2024-03-031-5/+6
| | | | | | | Only used in vulkan.c. Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avutil/vulkan: Avoid shadowingAndreas Rheinhardt2024-03-031-4/+6
| | | | | Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* avutil/vulkan: Don't autoinclude vulkan_loader.hAndreas Rheinhardt2024-03-031-1/+0
| | | | | | | Only include it where necessary. Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
* vulkan: return VK_NOT_READY when no queries are availableLynne2023-10-281-0/+5
| | | | | | | | | Fixes a validation issue. The issue is that the function gets called before we've sumitted a frame for decoding to that context. However, we cannot run queries before they've been reset, which happens at submission time. As we'd need to otherwise run a command queue at init-time, just check if submissions have happened.
* vulkan: do not leak bound_buffer_indicesLynne2023-08-281-0/+1
|
* vulkan: check for extension rather than function pointerLynne2023-08-281-1/+1
| | | | | | | | | The loader ensures only that functions with tagged supported extensions exist, rather than ensuring only those with supported extensions are loaded. As the init function uses Vulkan functions, whose loading requires them to have the extension flags set, the extension flags are guaranteed to also exist at this point.
* vulkan: do not leak cooperative matrix propertiesLynne2023-08-281-0/+1
|
* vulkan: enable VK_KHR_cooperative_matrixLynne2023-08-261-1/+24
| | | | | It's of interest to API users, and of interest to us, as a DCT/DST can be implemented via matrix multiplies.
* lavu/vulkan: remove threadsafe buffer index load and fix a signed overflowLynne2023-07-211-3/+1
| | | | It's not needed anymore.
* vulkan: discard dependencies when explicitly waiting for executionLynne2023-06-071-0/+3
| | | | | | | | | | This reduces memory needed dramatically, as unneeded resources can be immediately returned to the pool. Although waitforfences is threadsafe, we add a mutex wait around it, as the mutex fence in combination with waitforfences assures us that no other thread will reset the fence in the meanwhile whilst the mutex is locked. This allows is to call ff_vk_exec_discard_deps.
* vulkan: synchronize access to execution pool fencesLynne2023-06-071-3/+13
| | | | | vkResetFences is specified as being user-synchronized (yet vkWaitFences, is not).
* vulkan: replace usage of %lu with %"SIZE_SPECIFIER"Lynne2023-05-291-1/+1
|
* vulkan: add support for the atomic float ops extensionLynne2023-05-291-0/+13
|
* vulkan: enable forcing of full subgroupsLynne2023-05-291-2/+13
|
* vulkan: rewrite to support all necessary featuresLynne2023-05-291-1039/+1124
| | | | | | | | | | | | | | | This commit rewrites the majority of vulkan.c to enable its use as a general-purpose high-level utility code, usable for decoding, encoding, and filtering of video frames. The dependency system was rewritten to simplify management of execution. The image handling system was rewritten to accomodate multiplane images. Due to how related all the new features were, this is a single commit.
* vulkan: return current queue index from ff_vk_qf_rotate()Lynne2023-05-291-1/+2
|
* vulkan: add support for retrieving queue, query and video propertiesLynne2023-05-291-14/+73
|
* vulkan: add support for queriesLynne2023-05-291-0/+118
|
* vulkan: minor indent fix, add support for synchronous submission/waitingLynne2023-05-291-2/+18
|
* vulkan: use device properties 2 and add a convenience loader functionLynne2023-05-291-1/+17
|
* vulkan: add size tracking to buffer structsLynne2023-05-291-0/+2
|
* vulkan: do not wait for device idle when destroying buffersLynne2023-05-291-2/+0
| | | | This should be done explicitly.
* vulkan: allow alloc pNext in ff_vk_create_bufLynne2023-05-291-2/+3
|
* vulkan: support ignoring memory properties when allocatingLynne2023-05-291-3/+4
|
* vulkan: expose ff_vk_alloc_mem()Lynne2023-05-291-7/+8
|
* vulkan: add ff_vk_image_create()Lynne2023-05-291-0/+89
|
* vulkan: add ff_vk_qf_fill()Lynne2023-05-291-0/+25
|
* vulkan: add pNext argument to ff_vk_create_buf()Lynne2023-05-291-2/+2
|
* vulkan: add additional error codesLynne2023-05-291-0/+13
|
* vulkan: lock queues before submitting operationsLynne2023-05-291-0/+7
|
* hwcontext_vulkan: add functions for video decodingLynne2023-05-291-3/+5
|
* lavu/vulkan: avoid using strlen as a loop conditionLynne2022-02-221-1/+2
| | | | Whatever.
* lavu/vulkan: check for initialization when freeing buffersLynne2021-11-201-1/+1
| | | | | | | | | What happens on startup is that ffmpeg.c initializes the filter, then frees it without feeding a single frame through. With no input frame, the filter lacks a hardware device. The rest of the uninit code checks if Vulkan objects exist, which they must if there's a hardware device, but vk->DeviceWaitIdle does not require an object. So, add a check for it.
* lavu/vulkan: add support for using libshaderc as a GLSL compilerLynne2021-11-191-0/+4
| | | | | | | It's got a much better API that's actually maintained, it eliminates race conditions, it comes with a pkg-config file by default, and unfortunately isn't currently packaged by Debian or other large distributions.
* lavfi/vulkan: split off lavfi-specific code into vulkan_filter.cLynne2021-11-191-2/+2
| | | | | | | | | | | | | | | | | The issue is that libavfilter depends on libavcodec, and when doing a static build, if libavcodec also includes "libavfilter/vulkan.c", then during link-time, compiling programs will fail as there would be multiple definitions of the same symbols in both libavfilter and libavcodec's object files. Linkers are, however, more permitting if both files that include a common file that's used as a template are one-to-one identical. Hence, to make both files the same in the future, export all avfilter specific functions to a separate file. There is some work in progress to make templated files like this be compiled only once, so this is not a long-term solution. This also removes a macro that could be used to toggle SPIRV compilation capability on #include-time, as this could cause the files to be different.
* lavu/vulkan: add option to switch between shader compilers and cleanup glslangLynne2021-11-191-12/+21
|
* lavu/vulkan: move common Vulkan code from libavfilter to libavutilLynne2021-11-191-0/+1392