lavu: add Vulkan hwcontext code
This commit adds the necessary code to initialize and use a Vulkan device within the hwcontext libavutil framework. Currently direct mapping to VAAPI and DRM frames is functional, and transfers to CUDA and native frames are supported. Lets hope the future Vulkan video decode extension fits well within this framework.
This commit is contained in:
@@ -58,6 +58,9 @@ static const HWContextType * const hw_table[] = {
|
||||
#endif
|
||||
#if CONFIG_MEDIACODEC
|
||||
&ff_hwcontext_type_mediacodec,
|
||||
#endif
|
||||
#if CONFIG_VULKAN
|
||||
&ff_hwcontext_type_vulkan,
|
||||
#endif
|
||||
NULL,
|
||||
};
|
||||
@@ -73,6 +76,7 @@ static const char *const hw_type_names[] = {
|
||||
[AV_HWDEVICE_TYPE_VDPAU] = "vdpau",
|
||||
[AV_HWDEVICE_TYPE_VIDEOTOOLBOX] = "videotoolbox",
|
||||
[AV_HWDEVICE_TYPE_MEDIACODEC] = "mediacodec",
|
||||
[AV_HWDEVICE_TYPE_VULKAN] = "vulkan",
|
||||
};
|
||||
|
||||
enum AVHWDeviceType av_hwdevice_find_type_by_name(const char *name)
|
||||
|
||||
Reference in New Issue
Block a user