History

vulkan: add pNext argument to ff_vk_create_buf()

Lynne committed 4 years ago

Commit b5e333b1 parent a0d47a25 files · +6 −6Browse files

Unified · Split

5 files
  1. libavfilter/vf_gblur_vulkan.c +1 −1
  2. libavfilter/vf_overlay_vulkan.c +1 −1
  3. libavfilter/vf_scale_vulkan.c +1 −1
  4. libavutil/vulkan.c +2 −2
  5. libavutil/vulkan.h +1 −1
libavfilter/vf_gblur_vulkan.c+1−1
@@ -174,7 +174,7 @@ static int init_gblur_pipeline(GBlurVulkanContext *s, FFVulkanPipeline *pl, FFVk · 173 unmodified lines
174174 RET(ff_vk_init_pipeline_layout(&s->vkctx, pl));
175175 RET(ff_vk_init_compute_pipeline(&s->vkctx, pl));
176176
177− RET(ff_vk_create_buf(&s->vkctx, params_buf, sizeof(float) * ksize,
177+ RET(ff_vk_create_buf(&s->vkctx, params_buf, sizeof(float) * ksize, NULL,
178178 VK_BUFFER_USAGE_STORAGE_BUFFER_BIT, VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT));
179179 RET(ff_vk_map_buffers(&s->vkctx, params_buf, &kernel_mapped, 1, 0));
180180
libavfilter/vf_overlay_vulkan.c+1−1
@@ -181,7 +181,7 @@ static av_cold int init_filter(AVFilterContext *ctx) · 180 unmodified lines
181181 } *par;
182182
183183 err = ff_vk_create_buf(vkctx, &s->params_buf,
184− sizeof(*par),
184+ sizeof(*par), NULL,
185185 VK_BUFFER_USAGE_STORAGE_BUFFER_BIT,
186186 VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT);
187187 if (err)
libavfilter/vf_scale_vulkan.c+1−1
@@ -253,7 +253,7 @@ static av_cold int init_filter(AVFilterContext *ctx, AVFrame *in) · 252 unmodified lines
253253 }
254254
255255 RET(ff_vk_create_buf(vkctx, &s->params_buf,
256− sizeof(*par),
256+ sizeof(*par), NULL,
257257 VK_BUFFER_USAGE_STORAGE_BUFFER_BIT,
258258 VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT));
259259
libavutil/vulkan.c+2−2
@@ -205,7 +205,7 @@ static int vk_alloc_mem(FFVulkanContext *s, VkMemoryRequirements *req, · 204 unmodified lines
205205 return 0;
206206 }
207207
208−int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size,
208+int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size, void *pNext,
209209 VkBufferUsageFlags usage, VkMemoryPropertyFlagBits flags)
210210 {
211211 int err;
@@ -215,7 +215,7 @@ int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size, · 3 unmodified lines
215215
216216 VkBufferCreateInfo buf_spawn = {
217217 .sType = VK_STRUCTURE_TYPE_BUFFER_CREATE_INFO,
218− .pNext = NULL,
218+ .pNext = pNext,
219219 .usage = usage,
220220 .sharingMode = VK_SHARING_MODE_EXCLUSIVE,
221221 .size = size, /* Gets FFALIGNED during alloc if host visible
libavutil/vulkan.h+1−1
@@ -397,7 +397,7 @@ int ff_vk_submit_exec_queue(FFVulkanContext *s, FFVkExecContext *e); · 396 unmodified lines
397397 /**
398398 * Create a VkBuffer with the specified parameters.
399399 */
400−int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size,
400+int ff_vk_create_buf(FFVulkanContext *s, FFVkBuffer *buf, size_t size, void *pNext,
401401 VkBufferUsageFlags usage, VkMemoryPropertyFlagBits flags);
402402
403403 /**

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