struct vk_swapchain_tpl {
tpl_display_t *tpl_display;
tpl_surface_t *tpl_surface;
- tbm_surface_h *buffers;
};
struct swap_region
if (swapchain_tpl->tpl_display)
tpl_object_unreference((tpl_object_t *)swapchain_tpl->tpl_display);
- if (swapchain_tpl->buffers)
- free(swapchain_tpl->buffers);
vk_free(chain->allocator, swapchain_tpl);
}
}
/* Initialize swapchain buffers. */
res = tpl_surface_get_swapchain_buffers(swapchain_tpl->tpl_surface,
- &swapchain_tpl->buffers, &buffer_cnt);
+ buffers, &buffer_cnt);
VK_CHECK(res == TPL_ERROR_NONE, goto done, "tpl_surface_get_swapchain_buffers() failed.\n");
- *buffers = swapchain_tpl->buffers;
*buffer_count = buffer_cnt;
done: