accord-net / framework

Machine learning, computer vision, statistics and general scientific computing for .NET
http://accord-framework.net
GNU Lesser General Public License v2.1
4.49k stars 1.99k forks source link

Accord.Video.FFMPEG in LGPL version with LGPL version of FFmpeg #979

Open michel-carbone opened 7 years ago

michel-carbone commented 7 years ago

Hello everyone,

I would like to use the FFmpeg library with Accord framework and without the GPL content of these libraries. The license terms of the FFmpeg library says that it is possible to use the DLL in a LGPL project if the DLL are compiled without "--enable-gpl" and without "--enable-nonfree" options, see https://ffmpeg.org/legal.html Is there anyone that has already performed this with success?

Thanks you in advance for your help and feedback.

Michel

cesarsouza commented 7 years ago

Hi @michel-carbone,

Thanks for opening the issue!

The version of FFMPEG that the framework is currently built against is version ffmpeg-3.2.2-win32-shared from Zeranoe's builds. If we manage to get a recompilation of this FFMPEG version, or compile it ourselves, without the --enable-gpl flag, then it would become possible to switch Accord.Video.FFMPEG's license to LGPL instead of GPL (as it was the original version of this library).

If you would like, you can take a look at rdps' build scripts at https://github.com/rdp/ffmpeg-windows-build-helpers for help in compiling FFMPEG yourself. Those scripts should be really useful in getting it done without too much pain (if you would like to give it a try, I would suggest going the Bash for Windows route instead of Cygwin, as it seems to be faster).

Also, please note that if you manage to compile a version higher than 3.2.2 it is also fine - it is unlikely that we would need to change Accord.Video.FFMPEG too much to support it.

Edit: it seems that someone had managed to recompile FFMPEG without the --enable-gpl flag to use it in a previous version of the framework and had shared it in CodePlex. However, it is very likely that the version used there is quite old and would not work with the current Accord.Video.FFMPEG library.

Regards, Cesar

michel-carbone commented 7 years ago

Hi Cesar,

Thanks for your answer. I've just seen your edit of this morning and was going to write alos about this version of FFMPEG on CodePlex. They use the AForge.Video.FFMPEG version 2.2.5 so it's the last version of AForge dll before the merge with Accord.NET. We have performed some test with this build of FFmpeg and AForge dll and it works. But we would like to switch to Accord.NET with FFMPEG in LGPL because support and updates are unlikely to happen in AForge dll, even if I know that Andrew makes some support yet. And we will perhaps use some additional features of Accord.NET in the future that are not available in AForge.NET.

I'll perform some testing and post here the results for everyone.

Regards, Michel