-
-
Notifications
You must be signed in to change notification settings - Fork 326
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
Community sourced tested version and config list, Clarification on compile settings and generation instructions #244
Conversation
Once I managed to solve #250 I will finish this PR, including a detailed step-by-step to generate a minimal build with settings written down under the |
personal experience, I do appreciate but out of scope |
Ohh, I thought it might be useful to others, now that I finally figured out how to compile custom and small FFmpeg version and the .configure settings required. But I see this is out of scope and would become more of a blog post / Tutorial. Thx for clarifying. |
I am not closing anything I didn't got a value lets talk |
However, my aim is simple to generate bindings to any available path of execution of FFmpeg, dynamic nature helps |
besides we do support 6.0 now which appears to be minor - 5.x gave much more problems |
so in general I don't like fluctuations you involving here - please try to explain why it should be part of this repo history, |
It doesn't need to be. Just thought a tutorial might be useful to explain how to compile your own minimal FFmpeg, Build new AutoGen bindings and ship everything. But I see my approach doesn't fit this repo. I'm just super happy to have a custom FFmpeg consisting of only 3 .dlls ( |
intresting, never thought it is possible - except GPL part of ffmpeg |
You can totally include or exclude any function you want using the My config is for exporting an H.264 video, someone else might only need importing mjpeg Webcam streams, everyone can contribute their configure script settings. That was the initial idea I had. |
My way of saying thing might look rude - but I am just trying to be protective - be not offended. By itself project is complex enough. |
So my thinking to keep at least FFmpeg building process outside - it is easy to include GPL code for example by skipping a flag. |
Didn't take it as rude at all^^
That's why I added the
Probably smarter to use just use |
Let's make a wiki page https://github.com/Ruslan-B/FFmpeg.AutoGen/wiki I think it would be better. |
I'm also interested in it, since 15% of our applicaion is the FFmpeg. It is not a priority for us, but it would be good to make it smaller. (But hw acceleration is needed) Why is it needed to modify the |
Which dlls Some other feature-sets may require more or less. If you let FFmpeg.AutoGen generate bindings with the hardcoded 8 The biggest drop in size comes from disabling codecs (eg. Apparently there is also a way to statically compile(?), which may side-step all of this, but I have never done this in C#. In C I am used to statically compiling FFmpeg and with LTO turned on. It automatically only pulls in what it needs, which can end up being less than 1 megabyte for uses cases like just decoding one type of video without sound. But for C# I don't know how this works, so I just supply minimal |
I guess this option is available only for OS X and iOS. Apple has (or had) strict rules with respect to JIT compilation. |
If there is an appetite for something that in size less than 700 KB, lets convert this PR to an issue. |
FFmpeg.AutoGen.Abstractions + FFmpeg.AutoGen.Bindings.DynamicallyLinked - it is around 450KB in binaries if you drop the rest |
I need to generate C# bindings for a custom ffmpeg build. I try to document the changes here in this PR and merge it into FFmpeg.AutoGen's official docs to make it less confusing for people trying to do the same.
I haven't yet managed to create bindings, but want to nail down and correct concrete facts in my journey whilst doing so. Even though it is still a draft, I still created this PR, as I would love some help to nail down the facts.
Added Documentation is:
Clarification regarding ffmpeg versions
Clarification regarding VisualStudio versions
Clarification regarding VisualStudio settings
Active Solution plattform
to a specific plattform and not AnyCPU. Eg. x64 or x86My current understanding and complete and utter guess as to how Generation vs Inclusion of bindings works in terms of platform settings. Hope to confirm this this week.
FFmpeg.AutoGen.CppSharpUnsafeGenerator
needs to run in a specific architecture. The bindings may be used in your project as asAnyCPU
or another architecture. However, the bindings won't be valid, even if paired with a .dll of the correct platform. Bindings need to be regenerated per platform and included per-platform with program logic to switch between them with an AnyCPU build is desired.A community sourced list of ffmpeg configs confirmed to work (Haven't managed yet to confirm this ffmpeg config I have used so far in my C projects...)
As build via the
https://git.ffmpeg.org/ffmpeg.git
repo and the relevant FFmpeg build docsConfigure Flags used
./configure --disable-nvenc --enable-shared --disable-nvdec --enable-gpl --enable-stripping --disable-vulkan --disable-sdl2 --disable-securetransport --disable-swresample --disable-swscale --disable-avfilter --disable-network --disable-doc --disable-programs --disable-d3d11va --disable-cuda-llvm --disable-dxva2 --disable-schannel --disable-mediafoundation --disable-postproc --disable-avdevice --disable-encoders --disable-hwaccels --disable-muxers --disable-parsers --disable-bsfs --disable-indevs --disable-outdevs --disable-devices --disable-filters --disable-decoders --enable-decoder=h264 --disable-protocols --enable-protocol=file --disable-demuxers --enable-demuxer=mov --enable-demuxer=h264 --enable-demuxer=m4v