History

vulkan_decode: add STORAGE flag to output images

In filtering, and SDR encoding, we use storage images. This fixes using Vulkan filters on Intel. Tested not to break anything on the three major vendors.

Lynne committed 1 year ago

Commit ec3f3451 parent ca6392e1 file · +2 −3Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/vulkan_decode.c+2−3
@@ -1070,7 +1070,8 @@ int ff_vk_frame_params(AVCodecContext *avctx, AVBufferRef *hw_frames_ctx) · 1069 unmodified lines
10701070
10711071 hwfc->format[0] = vkfmt;
10721072 hwfc->tiling = VK_IMAGE_TILING_OPTIMAL;
1073− hwfc->usage = VK_IMAGE_USAGE_TRANSFER_SRC_BIT |
1073+ hwfc->usage = VK_IMAGE_USAGE_TRANSFER_SRC_BIT |
1074+ VK_IMAGE_USAGE_STORAGE_BIT |
10741075 VK_IMAGE_USAGE_SAMPLED_BIT;
10751076
10761077 if (prof) {
@@ -1084,8 +1085,6 @@ int ff_vk_frame_params(AVCodecContext *avctx, AVBufferRef *hw_frames_ctx) · 7 unmodified lines
10841085 if (ctx->s.extensions & (FF_VK_EXT_VIDEO_ENCODE_QUEUE |
10851086 FF_VK_EXT_VIDEO_MAINTENANCE_1))
10861087 hwfc->usage |= VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR;
1087− } else if (DECODER_IS_SDR(avctx->codec_id)) {
1088− hwfc->usage |= VK_IMAGE_USAGE_STORAGE_BIT;
10891088 }
10901089
10911090 return err;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t