History

avutil/vulkan: Remove unused ff_vk_create_avbuf()

Unused since aea4d4b423c62aecf326ef3ae1578710faa3eca6.

Andreas Rheinhardt committed 1 year ago

Commit 27c82af1 parent e499c852 files · +0 −38Browse files

Unified · Split

2 files
  1. libavutil/vulkan.c +0 −35
  2. libavutil/vulkan.h +0 −3
libavutil/vulkan.c+0−35
@@ -1025,41 +1025,6 @@ int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size, · 1024 unmodified lines
10251025 return 0;
10261026 }
10271027
1028−static void destroy_avvkbuf(void *opaque, uint8_t *data)
1029−{
1030− FFVulkanContext *s = opaque;
1031− FFVkBuffer *buf = (FFVkBuffer *)data;
1032− ff_vk_free_buf(s, buf);
1033− av_free(buf);
1034−}
1035−
1036−int ff_vk_create_avbuf(FFVulkanContext *s, AVBufferRef **ref, size_t size,
1037− void *pNext, void *alloc_pNext,
1038− VkBufferUsageFlags usage, VkMemoryPropertyFlagBits flags)
1039−{
1040− int err;
1041− AVBufferRef *buf;
1042− FFVkBuffer *vkb = av_mallocz(sizeof(*vkb));
1043− if (!vkb)
1044− return AVERROR(ENOMEM);
1045−
1046− err = ff_vk_create_buf(s, vkb, size, pNext, alloc_pNext, usage, flags);
1047− if (err < 0) {
1048− av_free(vkb);
1049− return err;
1050− }
1051−
1052− buf = av_buffer_create((uint8_t *)vkb, sizeof(*vkb), destroy_avvkbuf, s, 0);
1053− if (!buf) {
1054− destroy_avvkbuf(s, (uint8_t *)vkb);
1055− return AVERROR(ENOMEM);
1056− }
1057−
1058− *ref = buf;
1059−
1060− return 0;
1061−}
1062−
10631028 int ff_vk_map_buffers(FFVulkanContext *s, FFVkBuffer **buf, uint8_t *mem[],
10641029 int nb_buffers, int invalidate)
10651030 {
libavutil/vulkan.h+0−3
@@ -481,9 +481,6 @@ int ff_vk_alloc_mem(FFVulkanContext *s, VkMemoryRequirements *req, · 480 unmodified lines
481481 int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size,
482482 void *pNext, void *alloc_pNext,
483483 VkBufferUsageFlags usage, VkMemoryPropertyFlagBits flags);
484−int ff_vk_create_avbuf(FFVulkanContext *s, AVBufferRef **ref, size_t size,
485− void *pNext, void *alloc_pNext,
486− VkBufferUsageFlags usage, VkMemoryPropertyFlagBits flags);
487484
488485 /**
489486 * Buffer management code.

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