Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FFmpeg fails to make [hwcontext_vulkan] #2345

Closed
OliverMD15 opened this issue Dec 20, 2022 · 9 comments
Closed

FFmpeg fails to make [hwcontext_vulkan] #2345

OliverMD15 opened this issue Dec 20, 2022 · 9 comments

Comments

@OliverMD15
Copy link

Turning off --enable-vulkan in ffmpeg_options.txt is a temporary fix

05:17:20 ┌ ffmpeg git  ............................... [Recently updated]
05:17:20 ├ Changing options to comply to nonfree...
CUDA_PATH environment variable not set or directory does not exist.
05:17:24 ├ Compiling static FFmpeg...
05:17:25 ├ Running configure...
05:21:10 ├ Running make...
Likely error (tail of the failed operation logfile):
CC      libavutil/hwcontext_vulkan.o
C:/Download/Media-Autobuild/build/ffmpeg-git/libavutil/hwcontext_vulkan.c:367:7: error: 'VK_EXT_VIDEO_DECODE_H264_EXTENSION_NAME' undeclared here (not in a function); did you mean 'VK_EXT_VIDEO_ENCODE_H264_EXTENSION_NAME'?
  367 |     { VK_EXT_VIDEO_DECODE_H264_EXTENSION_NAME,                FF_VK_EXT_NO_FLAG                },
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |       VK_EXT_VIDEO_ENCODE_H264_EXTENSION_NAME
C:/Download/Media-Autobuild/build/ffmpeg-git/libavutil/hwcontext_vulkan.c:368:7: error: 'VK_EXT_VIDEO_DECODE_H265_EXTENSION_NAME' undeclared here (not in a function); did you mean 'VK_EXT_VIDEO_ENCODE_H265_EXTENSION_NAME'?
  368 |     { VK_EXT_VIDEO_DECODE_H265_EXTENSION_NAME,                FF_VK_EXT_NO_FLAG                },
      |       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |       VK_EXT_VIDEO_ENCODE_H265_EXTENSION_NAM
[logs.zip](https://github.com/m-ab-s/media-autobuild_suite/files/10265276/logs.zip)
E
make: *** [/build/ffmpeg-git/ffbuild/common.mak:81: libavutil/hwcontext_vulkan.o] Error 1
make failed. Check C:/Download/Media-Autobuild/build/ffmpeg-git/build-static-64bit/ab-suite.make.log
This is required for other packages, so this script will exit.
05:23:52   Creating diagnostics file...```
@Biswa96
Copy link
Contributor

Biswa96 commented Dec 20, 2022

Probably you need to git pull the vulkan repository again to sync with vulkan headers or loaders.

@fuchanghao
Copy link

Probably you need to git pull the vulkan repository again to sync with vulkan headers or loaders.

I removed the vulkan repository let m-ab-s re-download and build it same error happened.

@OliverMD15
Copy link
Author

Probably you need to git pull the vulkan repository again to sync with vulkan headers or loaders.

It was a fresh (kinda) m-a-s install, I freshly pulled everything, yet the error keeps happening.

@Biswa96
Copy link
Contributor

Biswa96 commented Dec 20, 2022

The VK_EXT_VIDEO_DECODE_H264_EXTENSION_NAME was removed from vulkan headers (include/vulkan/vulkan_beta.h) in this commit KhronosGroup/Vulkan-Headers@00671c6#diff-b1e4e7ea6a31d516e9a13c9e08028fb3959058081965270ac94d587d9ec1758dL903

I am not sure if this should be reported to ffmpeg. But one can try.

@Biswa96
Copy link
Contributor

Biswa96 commented Dec 20, 2022

One temporary workaround might be to git checkout a commit in vulkan-headers before that one.

@Mr-Z-2697
Copy link

Mr-Z-2697 commented Dec 20, 2022

https://github.com/KhronosGroup/Vulkan-Loader.git#sdk-1.3.236
change vulkan loader source repo link in media-suite_deps.sh to this may be a temporary solution
or this? https://github.com/KhronosGroup/Vulkan-Loader.git#96488e2b2e0dadd37e2caaa67f8fa010b2b1902e
gonna try both

@hydra3333
Copy link
Contributor

hydra3333 commented Dec 21, 2022

The VK_EXT_VIDEO_DECODE_H264_EXTENSION_NAME was removed from vulkan headers (include/vulkan/vulkan_beta.h) in this commit KhronosGroup/Vulkan-Headers@00671c6#diff-b1e4e7ea6a31d516e9a13c9e08028fb3959058081965270ac94d587d9ec1758dL903

I am not sure if this should be reported to ffmpeg. But one can try.

OK, did that. Feel free to comment over there: https://trac.ffmpeg.org/ticket/10115

It seems affixing both vulkan_loader and vulkan_headers to git tag "sdk-1.3.236.0" bypasses that error ? (a temporary "solution" of course)

@1480c1
Copy link
Member

1480c1 commented Dec 26, 2022

Fixed upstream FFmpeg/FFmpeg@eb0455d646

@OriKovacsiKatz
Copy link

edited the nano /HandBrake/build/contrib/ffmpeg/ffmpeg-5.1.2/libavutil/hwcontext_vulkan.c the two unknown items (VK_EXT_VIDEO_DECODE_H264_EXTENSION_NAME, VK_EXT_VIDEO_DECODE_H265_EXTENSION_NAME) removed manually. rebuild using make is successful.
I didn't try yet to use the HandBrake application but it is running GUI is running well and mkv format file is loaded successfully.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants