• Home
  • Raw
  • Download

Lines Matching refs:hwfc

1604     AVHWFramesContext       *hwfc = opaque;  in opencl_pool_free()  local
1612 av_log(hwfc, AV_LOG_ERROR, "Failed to release plane %d: " in opencl_pool_free()
1622 AVHWFramesContext *hwfc = opaque; in opencl_pool_alloc() local
1623 AVOpenCLDeviceContext *hwctx = hwfc->device_ctx->hwctx; in opencl_pool_alloc()
1637 err = opencl_get_plane_format(hwfc->sw_format, p, in opencl_pool_alloc()
1638 hwfc->width, hwfc->height, in opencl_pool_alloc()
1652 av_log(hwfc, AV_LOG_ERROR, "Failed to create image for " in opencl_pool_alloc()
1663 &opencl_pool_free, hwfc, 0); in opencl_pool_alloc()
1676 static int opencl_frames_init_command_queue(AVHWFramesContext *hwfc) in opencl_frames_init_command_queue() argument
1678 AVOpenCLFramesContext *hwctx = hwfc->hwctx; in opencl_frames_init_command_queue()
1679 OpenCLDeviceContext *devpriv = hwfc->device_ctx->internal->priv; in opencl_frames_init_command_queue()
1680 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_frames_init_command_queue()
1687 av_log(hwfc, AV_LOG_ERROR, "Failed to retain frame " in opencl_frames_init_command_queue()
1695 static int opencl_frames_init(AVHWFramesContext *hwfc) in opencl_frames_init() argument
1697 if (!hwfc->pool) { in opencl_frames_init()
1698 hwfc->internal->pool_internal = in opencl_frames_init()
1699 av_buffer_pool_init2(sizeof(cl_mem), hwfc, in opencl_frames_init()
1701 if (!hwfc->internal->pool_internal) in opencl_frames_init()
1705 return opencl_frames_init_command_queue(hwfc); in opencl_frames_init()
1708 static void opencl_frames_uninit(AVHWFramesContext *hwfc) in opencl_frames_uninit() argument
1710 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_frames_uninit()
1720 av_log(hwfc, AV_LOG_ERROR, "Failed to release mapped " in opencl_frames_uninit()
1732 av_log(hwfc, AV_LOG_ERROR, "Failed to release frame " in opencl_frames_uninit()
1739 static int opencl_get_buffer(AVHWFramesContext *hwfc, AVFrame *frame) in opencl_get_buffer() argument
1744 frame->buf[0] = av_buffer_pool_get(hwfc->pool); in opencl_get_buffer()
1754 frame->width = hwfc->width; in opencl_get_buffer()
1755 frame->height = hwfc->height; in opencl_get_buffer()
1760 static int opencl_transfer_get_formats(AVHWFramesContext *hwfc, in opencl_transfer_get_formats() argument
1770 fmts[0] = hwfc->sw_format; in opencl_transfer_get_formats()
1777 static int opencl_wait_events(AVHWFramesContext *hwfc, in opencl_wait_events() argument
1785 av_log(hwfc, AV_LOG_ERROR, "Failed to wait for event " in opencl_wait_events()
1793 av_log(hwfc, AV_LOG_ERROR, "Failed to release " in opencl_wait_events()
1801 static int opencl_transfer_data_from(AVHWFramesContext *hwfc, in opencl_transfer_data_from() argument
1804 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_transfer_data_from()
1813 if (dst->format != hwfc->sw_format) in opencl_transfer_data_from()
1817 err = opencl_get_plane_format(hwfc->sw_format, p, in opencl_transfer_data_from()
1827 av_log(hwfc, AV_LOG_ERROR, "Plane %d missing on " in opencl_transfer_data_from()
1844 av_log(hwfc, AV_LOG_ERROR, "Failed to enqueue read of " in opencl_transfer_data_from()
1851 opencl_wait_events(hwfc, events, p); in opencl_transfer_data_from()
1856 static int opencl_transfer_data_to(AVHWFramesContext *hwfc, in opencl_transfer_data_to() argument
1859 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_transfer_data_to()
1868 if (src->format != hwfc->sw_format) in opencl_transfer_data_to()
1872 err = opencl_get_plane_format(hwfc->sw_format, p, in opencl_transfer_data_to()
1882 av_log(hwfc, AV_LOG_ERROR, "Plane %d missing on " in opencl_transfer_data_to()
1899 av_log(hwfc, AV_LOG_ERROR, "Failed to enqueue write of " in opencl_transfer_data_to()
1906 opencl_wait_events(hwfc, events, p); in opencl_transfer_data_to()
1918 static void opencl_unmap_frame(AVHWFramesContext *hwfc, in opencl_unmap_frame() argument
1921 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_unmap_frame()
1936 av_log(hwfc, AV_LOG_ERROR, "Failed to unmap OpenCL " in opencl_unmap_frame()
1942 opencl_wait_events(hwfc, events, e); in opencl_unmap_frame()
1947 static int opencl_map_frame(AVHWFramesContext *hwfc, AVFrame *dst, in opencl_map_frame() argument
1950 OpenCLFramesContext *priv = hwfc->internal->priv; in opencl_map_frame()
1962 av_assert0(hwfc->sw_format == dst->format); in opencl_map_frame()
1982 err = opencl_get_plane_format(hwfc->sw_format, p, in opencl_map_frame()
2001 av_log(hwfc, AV_LOG_ERROR, "Failed to map OpenCL " in opencl_map_frame()
2009 av_log(hwfc, AV_LOG_DEBUG, "Map plane %d (%p -> %p).\n", in opencl_map_frame()
2013 err = opencl_wait_events(hwfc, events, p); in opencl_map_frame()
2037 opencl_wait_events(hwfc, events, p); in opencl_map_frame()
2801 static int opencl_map_from(AVHWFramesContext *hwfc, AVFrame *dst, in opencl_map_from() argument
2805 if (hwfc->sw_format != dst->format) in opencl_map_from()
2807 return opencl_map_frame(hwfc, dst, src, flags); in opencl_map_from()
2810 static int opencl_map_to(AVHWFramesContext *hwfc, AVFrame *dst, in opencl_map_to() argument
2813 av_unused OpenCLDeviceContext *priv = hwfc->device_ctx->internal->priv; in opencl_map_to()
2819 return opencl_map_from_drm_beignet(hwfc, dst, src, flags); in opencl_map_to()
2824 return opencl_map_from_vaapi(hwfc, dst, src, flags); in opencl_map_to()
2830 return opencl_map_from_qsv(hwfc, dst, src, flags); in opencl_map_to()
2835 return opencl_map_from_dxva2(hwfc, dst, src, flags); in opencl_map_to()
2840 return opencl_map_from_d3d11(hwfc, dst, src, flags); in opencl_map_to()
2845 return opencl_map_from_drm_arm(hwfc, dst, src, flags); in opencl_map_to()