Closed boxerab closed 3 years ago
For 4. on your first reply, there is currently no maintainer for amfenc.c, amfenc.h, amfenc_h264.c, amfenc_h265.c listed in the maintainers file. That means that merging of patches takes significantly longer, unless a maintainer steps up to verify each patch for backwards incompatibility and similar changes. I was told this in reply to my own submission of a patch, which is also waiting for verification.
Few topic to cover:
1. AMF on Linux is only in Pro driver because it uses closed source Vulkan extensions.
Which is a problem.
We have a person who can be a maintainer by we need to introduce AMF context to share instance of AMF between encoder, decoder and converter but it is UTIL area not AMFENC.
Once Khronos finishes Vulkan extensions for encoder and decoder and Vulkan open source driver implements them we plan to make an open source version of AMF for amdgpu driver.
MikhailAMD what is the benefit of AMF rather than VAAPI? Is either the performance or quality better?
Performance is defined by HW. AMF and VAAPI just two APIs accessing the same. One important difference though that on Linux AMF works via Vulkan and can be tightly integrated with Vulkan app. And AMF exists on Windows and on Linux while VAAPI is Linux only
Once Khronos finishes Vulkan extensions for encoder and decoder and Vulkan open source driver implements them we plan to make an open source version of AMF for amdgpu driver.
@MikhailAMD , any idea when vulkan extension for encoder and decoder would be available?
Is Pro driver available for ARM platform?
Only x86 or x86-64 :)
I don't know Khronos timeline.
Eagerly looking for Pro driver support for ARM platform or Vulkan extension for Encoder :)
So 4 months later, what are the news ? I'm interested to see coming this OBS because actually I use VAAPI but it's not really using the GPU and I can't reach 1080p60fps smooth video
OBS can integrate AMF via Vulkan on Linux with Radeon Pro driver. I cannot comment here on VAAPI integration/implementation. Khronos didn't release spec for video encoder yet.
According to Tom Olson, the target release date for the Vulkan standards is first half of 2020.
According to Tom Olson, the target release date for the Vulkan standards is first half of 2020.
2020, I think I have to wait :cry:
@MikhailAMD Oh ? So now if I install AMDGPU-PRO driver it will work ? Also, I know that AMD didn't provide an official release for Arch Linux but we can find AUR packages of that drivers
PRO driver has AMF runtime for optional install and AMF SDK supports this. But I guess OBS still needs to do some work for Linux-specific integration.
The prerequisites in the Readme file still refer to Windows as the only supported operating system: https://github.com/GPUOpen-LibrariesAndSDKs/AMF/blob/master/README.md
@MikhailAMD I'm a little confused here - are you able to summarize current linux support for HW decode on AMD hardware ? For example, with ROCm installed, and Polaris card. Thank you :)
ROCm is not relevant to AMF. On Linux you will need Pro driver + Vulkan + AMF package. Download: https://www.amd.com/en/support/kb/release-notes/rn-rad-lin-19-50-unified Pro installation: https://amdgpu-install.readthedocs.io/en/latest/install-installing.html#installing-the-pro-variant Install AMF: sudo apt install amf-amdgpu-pro
Thanks - can the Pro driver be installed on a machine that already has ROCm installed ?
Not an expert in the ROCm but according to what I read so far it should work.
Thanks. Gonna close this after 3+ years :)
running rocm 3 and tried to install amdgpu-pro. It is impossible. Please test on your own. It is very bad for Deep Learning, this way noone can run the ffmpeg h264 in the AMD GPU. Please test and fix it. With NVIDIA its been always possible to run Deep Learning Object Detection and h264 encoding in the same GPU. With AMD, never. Why not just add the AMF and VAAPI, ffmpeg support to rocm if rocm and amdgpu cant work on the same machine? 2020 mid January..
I've tried to launch it with Ubuntu 18.04 Kernel: x86_64 Linux 5.3.0-28-generi CPU: Intel Xeon E3-1225 v3 @ 4x 3.6GHz GPU: AMD/ATI Ellesmere [Radeon RX 470/480/570/570X/580/580X], Pilot
How can I find proper combination?
Error! Bad return status for module build on kernel: 5.3.0-28-generic (x86_64) Consult /var/lib/dkms/amdgpu/19.50-967956/build/make.log for more information.
Here it is
DKMS make.log for amdgpu-19.50-967956 for kernel 5.3.0-28-generic (x86_64) Вт фев 11 11:06:42 MSK 2020 make: Entering directory '/usr/src/linux-headers-5.3.0-28-generic' CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_main.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_drm.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_memory.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/main.o In file included from /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../include/../backport/backport.h:8:0, from <command-line>:0: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../backport/include/kcl/kcl_amdgpu.h: In function ‘kcl_amdgpu_get_vblank_timestamp_kms’: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../backport/include/kcl/kcl_amdgpu.h:99:9: error: implicit declaration of function ‘amdgpu_get_vblank_timestamp_kms’; did you mean ‘kcl_amdgpu_get_vblank _timestamp_kms’? [-Werror=implicit-function-declaration] return amdgpu_get_vblank_timestamp_kms(dev, pipe, max_error, vblank_time, flags); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kcl_amdgpu_get_vblank_timestamp_kms CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_tt.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c: At top level: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1449:26: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types] .get_vblank_timestamp = kcl_amdgpu_get_vblank_timestamp_kms, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1449:26: note: (near initialization for ‘kms_driver.get_vblank_timestamp’) /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1450:26: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types] .get_scanout_position = kcl_amdgpu_get_crtc_scanout_position, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1450:26: note: (near initialization for ‘kms_driver.get_scanout_position’) CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/symbols.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_fence.o cc1: some warnings being treated as errors CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence.o scripts/Makefile.build:288: recipe for target '/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o' failed make[2]: *** [/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o] Error 1 scripts/Makefile.build:519: recipe for target '/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu' failed make[1]: *** [/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu] Error 2 make[1]: *** Waiting for unfinished jobs.... CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence_array.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_drm_cache.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence.c:63:1: warning: ‘dma_fence_test_signaled_any’ defined but not used [-Wunused-function] dma_fence_test_signaled_any(struct dma_fence **fences, uint32_t count, ^~~~~~~~~~~~~~~~~~~~~~~~~~~ CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_entity.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_reservation.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_device_cgroup.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_suspend.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/amd-sched.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c: In function ‘amdkcl_pci_init’: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c:189:84: warning: passing argument 2 of ‘amdkcl_fp_setup’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] _kcl_pcie_link_speed = (const unsigned char *) amdkcl_fp_setup("pcie_link_speed", _kcl_pcie_link_speed_stub); ^~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c:3:0: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_common.h:23:21: note: expected ‘void *’ but argument is of type ‘const unsigned char *’ static inline void *amdkcl_fp_setup(const char *symbol, void *fp_stup) ^~~~~~~~~~~~~~~ CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_perf_event.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_perf_event.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_kthread.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_mm.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_mn.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_io.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_util.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_workqueue.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_vm.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/amdkcl.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_module.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_execbuf_util.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_page_alloc.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_manager.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_page_alloc_dma.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_agp_backend.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/amdttm.o Makefile:1655: recipe for target '_module_/var/lib/dkms/amdgpu/19.50-967956/build' failed make: *** [_module_/var/lib/dkms/amdgpu/19.50-967956/build] Error 2 make: Leaving directory '/usr/src/linux-headers-5.3.0-28-generic'
Same here for your convinience https://pastebin.com/WneC2bsV
I've tried to launch it with Ubuntu 18.04 Kernel: x86_64 Linux 5.3.0-28-generi CPU: Intel Xeon E3-1225 v3 @ 4x 3.6GHz GPU: AMD/ATI Ellesmere [Radeon RX 470/480/570/570X/580/580X], Pilot
How can I find proper combination?
Error! Bad return status for module build on kernel: 5.3.0-28-generic (x86_64) Consult /var/lib/dkms/amdgpu/19.50-967956/build/make.log for more information.
Here it isDKMS make.log for amdgpu-19.50-967956 for kernel 5.3.0-28-generic (x86_64) Вт фев 11 11:06:42 MSK 2020 make: Entering directory '/usr/src/linux-headers-5.3.0-28-generic' CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_main.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_drm.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_memory.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/main.o In file included from /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../include/../backport/backport.h:8:0, from <command-line>:0: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../backport/include/kcl/kcl_amdgpu.h: In function ‘kcl_amdgpu_get_vblank_timestamp_kms’: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/../backport/include/kcl/kcl_amdgpu.h:99:9: error: implicit declaration of function ‘amdgpu_get_vblank_timestamp_kms’; did you mean ‘kcl_amdgpu_get_vblank _timestamp_kms’? [-Werror=implicit-function-declaration] return amdgpu_get_vblank_timestamp_kms(dev, pipe, max_error, vblank_time, flags); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kcl_amdgpu_get_vblank_timestamp_kms CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_tt.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c: At top level: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1449:26: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types] .get_vblank_timestamp = kcl_amdgpu_get_vblank_timestamp_kms, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1449:26: note: (near initialization for ‘kms_driver.get_vblank_timestamp’) /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1450:26: error: initialization from incompatible pointer type [-Werror=incompatible-pointer-types] .get_scanout_position = kcl_amdgpu_get_crtc_scanout_position, ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.c:1450:26: note: (near initialization for ‘kms_driver.get_scanout_position’) CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/symbols.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_fence.o cc1: some warnings being treated as errors CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence.o scripts/Makefile.build:288: recipe for target '/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o' failed make[2]: *** [/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu/amdgpu_drv.o] Error 1 scripts/Makefile.build:519: recipe for target '/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu' failed make[1]: *** [/var/lib/dkms/amdgpu/19.50-967956/build/amd/amdgpu] Error 2 make[1]: *** Waiting for unfinished jobs.... CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence_array.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_drm_cache.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_fence.c:63:1: warning: ‘dma_fence_test_signaled_any’ defined but not used [-Wunused-function] dma_fence_test_signaled_any(struct dma_fence **fences, uint32_t count, ^~~~~~~~~~~~~~~~~~~~~~~~~~~ CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/sched_entity.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_reservation.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_device_cgroup.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_suspend.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/scheduler/amd-sched.o /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c: In function ‘amdkcl_pci_init’: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c:189:84: warning: passing argument 2 of ‘amdkcl_fp_setup’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers] _kcl_pcie_link_speed = (const unsigned char *) amdkcl_fp_setup("pcie_link_speed", _kcl_pcie_link_speed_stub); ^~~~~~~~~~~~~~~~~~~~~~~~~ In file included from /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_pci.c:3:0: /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_common.h:23:21: note: expected ‘void *’ but argument is of type ‘const unsigned char *’ static inline void *amdkcl_fp_setup(const char *symbol, void *fp_stup) ^~~~~~~~~~~~~~~ CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_perf_event.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_perf_event.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_kthread.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_mm.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_mn.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_io.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_util.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/kcl_workqueue.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_vm.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/amd/amdkcl/amdkcl.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_module.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_execbuf_util.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_page_alloc.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_bo_manager.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_page_alloc_dma.o CC [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/ttm_agp_backend.o LD [M] /var/lib/dkms/amdgpu/19.50-967956/build/ttm/amdttm.o Makefile:1655: recipe for target '_module_/var/lib/dkms/amdgpu/19.50-967956/build' failed make: *** [_module_/var/lib/dkms/amdgpu/19.50-967956/build] Error 2 make: Leaving directory '/usr/src/linux-headers-5.3.0-28-generic'
Same here for your convinience https://pastebin.com/WneC2bsV
Currently amdgpu-pro only supports the default kernel version on Ubuntu 18.04 LTS. In a few months, Ubuntu 20.04 LTS will be released with a 5.4 kernel. I think that AMD will update the driver to support higher kernel versions.
I've got it. Ubuntu 18.04.4 goes with 5.3.0-28 kernel version afaik. I'd be glad to see it working out of the box in Ubuntu distros.
I have ubunut 18.04.4 with installed amdgpu-pro and amf-amdgpu-pro. h264_amf works via ffmpeg. I install obs 25.0.8. How i can use for streaming and recording amd amf via obs? For streaming and recording i use VAAPI via ffmpeg: DRI_PRIME=1 LIBVA_DRIVER_NAME=radeonsi ffmpeg -y \ -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -hwaccel_output_format vaapi \ -framerate 30 -video_size 1920x1050 -f x11grab -i :0.0 -f pulse -ac 2 -i default \ -vf 'hwupload,scale_vaapi=w=1280:h=720:format=nv12' \ -vcodec h264_vaapi -g 60 -sei identifier+timing+recovery_point \ -bsf:v extract_extradata -b:v 3M -maxrate 3M -c:a aac -b:a 128k -ar 44100 \ -f flv OUTPUT How this code must be if i want use h26_amf?
If it works with regular FFmpeg, the command line for OBS should be similar: "-hwaccel h264_amf" but I didn't try OBS on Linux.
Looks nice. I'll try it out later. Thanks for your work, Mikhail.
How do you use ffmpeg to convert a video with amd, and how to screen capture too ?
In FFmpeg command line you could use "-hwaccel h264_amf" to enable AMF hardware encoder inf you installed AMD Pro with with AMF. Here is more info for other variants: https://trac.ffmpeg.org/wiki/HWAccelIntro For capture you would need an application, for example OBS.
Hmm, doing the command ffmpeg -hwaccels
doesn't show me that h264_amf is avaible.
Here is the output:
vdpau
vaapi
drm
opencl
vulkan
And when I do ffmpeg -codecs | grep h264
, it returns:
DEV.LS h264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 (decoders: h264 h264_v4l2m2m libopenh264 ) (encoders: libx264 libx264rgb libopenh264 h264_amf h264_omx h264_v4l2m2m h264_vaapi )
My mistake, it is codec, not accelerator: -c:v h264_amf
Hmm, doing the command
ffmpeg -hwaccels
doesn't show me that h264_amf is avaible. Here is the output:vdpau vaapi drm opencl vulkan
what version of ffmpeg and linux you use?
My mistake, it is codec, not accelerator: -c:v h264_amf
i launch this command on my ubuntu 18.04.4 with latest ffmpeg compiled form source and i got: Hardware acceleration methods: vdpau vaapi Is vulkan must presented in this list for my configuration?
Btw, yesterday i test amdgpu-pro 20.10 on ubuntu, ubuntu-mate, xubuntu and lubuntu. I have got fail launch xubuntu and lubuntu after sucessfull installing amdgpu-pro with legacy opencl for my rx560 and rebooting. On ubuntu and ubuntu-mate i have got success. i use distros isos with version 18.04.4. After on ubuntu and ubuntu-mate i install amf. Then i compile ffmpeg with --enable-amf and copy files from AMF/..... to /usr/include/AMF/ . But i have fail. So to fix this i install libunistring-dev. After that i have successfully installed ffmpeg with amf. But when i start record my screen via ffmpeg with h264_amf i have fail. I have errors vulcan not inicial and some vulkan files not found. But amdgpu-pro worked and i start dota 2 with pro-vulcan and game works perfectly ( bwt with mesa drivers and opensource vulkan i cant play dota 2 normally cuz i always have laggs and freezes, and i dont know how to fix this problem with open stack). So to fix problem with using amf via ffmpeg you need use simple code somthing like that: ffmpeg -y -framerate 60 -f x11grab -i :0.0 -f alsa -ac 2 -i default \ -c:v h264 -b:v 6M -f flv h264.flv I dont know how, but after using h264 you can use h264_amf via ffmpeg without any trouble. And in fmpeg logs vulkan successfully initialized and all files are found.
Yeah i install amdgpu-pro and amf package and buid it with enable amf and ffmpeg -codecs:
DEV.LS h264 H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 (decoders: h264 h264_v4l2m2m ) (encoders: libx264 libx264rgb h264_amf h264_v4l2m2m h264_vaapi ) D.VIL. hap Vidvox Hap DEV.L. hevc H.265 / HEVC (High Efficiency Video Coding) (encoders: libx265 hevc_amf hevc_vaapi )
Notes:
ffmpeg -y -loglevel debug -framerate 60 -f x11grab -i :0.0 -f alsa -ac 2 -i default \ -c:v h264_amf -b:v 6M -f flv amf.flv -- for simple record desktop
But if you before dont run command ffmpeg -y -framerate 60 -f x11grab -i :0.0 -f alsa -ac 2 -i default -c:v h264 -b:v 6M -f flv h264.flv wich use h264 , you cant use amf, you willbe got errors!!!
ffmpeg -buildconf ffmpeg version N-97814-g6275a7e Copyright (c) 2000-2020 the FFmpeg developers built with gcc 7 (Ubuntu 7.5.0-3ubuntu1~18.04) configuration: --prefix=/home/XXXX/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/home/XXXX/ffmpeg_build/include --extra-ldflags=-L/home/XXXX/ffmpeg_build/lib --extra-libs='-lpthread -lm' --bindir=/home/XXXX/bin --enable-gpl --enable-gnutls --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-amf --enable-nonfree libavutil 56. 46.100 / 56. 46.100 libavcodec 58. 84.100 / 58. 84.100 libavformat 58. 43.100 / 58. 43.100 libavdevice 58. 9.103 / 58. 9.103 libavfilter 7. 81.100 / 7. 81.100 libswscale 5. 6.101 / 5. 6.101 libswresample 3. 6.100 / 3. 6.100 libpostproc 55. 6.100 / 55. 6.100
configuration: --prefix=/home/XXXX/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/home/XXXX/ffmpeg_build/include --extra-ldflags=-L/home/XXXX/ffmpeg_build/lib --extra-libs='-lpthread -lm' --bindir=/home/XXXX/bin --enable-gpl --enable-gnutls --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-amf --enable-nonfree
Very strange, dependencies between processes. What is the output for failure?
sry i delete that messages with vulkan errors when i reinstall system
Everything what you provided so far looks normal - except this strange run dependecy. My feeling is that if AMF failed to initialize Vulkan - it found a wrong driver. This cannot be controlled from AMF but by Vulkan installations.
sudo dpkg --list | grep vulkan ii libvulkan1:amd64 1.1.70+dfsg1-1ubuntu0.18.04.1 amd64 Vulkan loader library ii vulkan-amdgpu-pro:amd64 20.10-1048554 amd64 AMDGPU Pro Vulkan driver ii vulkan-amdgpu-pro:i386 20.10-1048554 i386 AMDGPU Pro Vulkan driver
i saw libvulkan1:amd64 and he was instaled with steam
So i need delete package libvulkan1:amd64 1.1.70+dfsg1-1ubuntu0.18.04.1?
For video transcoding, Linux is an ideal platform. And for this use case, no Vulkan support is necessary, just access to hardware decode/encode.