qyot27
27th October 2015, 18:31
What version of GCC? ffmpeg-git and ffms2-git? Because the errors you're getting look an awful lot like general compiler issues or not being pointed at the correct ffmpeg headers.
For that matter, the only reason FFMS2 comes before the AvxSynth step in that build guide is because AvxSynth wraps an already-installed build of FFMS2 to generate avxffms2, but this is not actually necessary (and actually will not work anymore with ffms2-git and avxsynth-git). Clone ffms2 from the master repo and check out the c_plugin branch, and build FFMS2 that way:
git clone git://github.com/FFMS/ffms2.git
cd ffms2
git checkout c_plugin
./configure --enable-avxsynth --enable-vapoursynth --enable-shared
make
sudo checkinstall --pkgname=ffms2 --pkgversion="1:$(./version.sh)-git" --backup=no \
--deldoc=yes --delspec=yes --deldesc=yes --strip=yes --stripso=yes --addso=yes \
--fstrans=no --default
nel-son
27th October 2015, 19:55
What version of GCC?
dpkg -l gcc
ii gcc 4:4.8.2-1ubuntu6 amd64 GNU C compiler
ffmpeg-git and ffms2-git?
sorry, i don't understand the question?
i have the same problem with make as before.
nel-son
30th October 2015, 10:40
i've tried it with a fresh installed kubuntu 14.04.3 (in virtualbox) and did step by step what you've posted here http://forum.doom9.org/showpost.php?p=1643184&postcount=193. build and installing ffmpeg works without any problem, but i have the same problem with building ffms2 as before on my other system (also with kubuntu 14.04.3).
can this be a problem with the cloned version of ffms2? you've written your howto in 2013. how can i clone an older version of ffms2? 1 yaer (or so) ago i'be built and installed ffmpeg and ffms2 on my notebook with lubuntu 14.04, so it should work.
LoRd_MuldeR
31st October 2015, 17:07
can this be a problem with the cloned version of ffms2? you've written your howto in 2013. how can i clone an older version of ffms2? 1 yaer (or so) ago i'be built and installed ffmpeg and ffms2 on my notebook with lubuntu 14.04, so it should work.
You don't "clone" any particular version. You always clone the entire repository, containing every version that has ever existed.
By default, the "newest" commit (aka MASTER) will be checked out in your working tree. But you can check out any older commit (or tag) that you like. That is a completely "local" operation. Just use git checkout (https://www.atlassian.com/git/tutorials/undoing-changes/git-checkout) command.
jammupatu
3rd November 2015, 18:46
What version of GCC? ffmpeg-git and ffms2-git? Because the errors you're getting look an awful lot like general compiler issues or not being pointed at the correct ffmpeg headers.
For that matter, the only reason FFMS2 comes before the AvxSynth step in that build guide is because AvxSynth wraps an already-installed build of FFMS2 to generate avxffms2, but this is not actually necessary (and actually will not work anymore with ffms2-git and avxsynth-git). Clone ffms2 from the master repo and check out the c_plugin branch, and build FFMS2 that way:
git clone git://github.com/FFMS/ffms2.git
cd ffms2
git checkout c_plugin
./configure --enable-avxsynth --enable-vapoursynth --enable-shared
make
sudo checkinstall --pkgname=ffms2 --pkgversion="1:$(./version.sh)-git" --backup=no \
--deldoc=yes --delspec=yes --deldesc=yes --strip=yes --stripso=yes --addso=yes \
--fstrans=no --default
Hi,
I'm having a hard time compiling Avxsynth-git and FFMS2-git on Debian Jessie (gcc 4.9) and Wheezy (gcc 4.7). As to be expected is that the "normal" way of compiling them FFMS2 first and Avxsynth second so it can generate the wrapper avxffms2 fails. However, I can't seem to be able to generate the c_plugin either:
After cloning:
$ git checkout c_plugin
Branch c_plugin set up to track remote branch c_plugin from origin.
Switched to a new branch 'c_plugin'
$ ./configure --enable-shared --enable-avxsynth --enable-vapoursynth
checking whether linking with FFmpeg or Libav...
avisynth: no
avxsynth: yes
vapoursynth:yes
debug: no
gprof: no
PIC: no
shared: yes
optlevel: 2
You can run 'make' now.
$ make
CXX src/core/ffms.o
In file included from src/core/ffms.cpp:25:0:
src/core/videosource.h:42:2: error: ‘PixelFormat’ does not name a type
src/core/videosource.h:46:14: error: ‘PixelFormat’ was not declared in this scope
src/core/videosource.h:46:25: error: template argument 1 is invalid
src/core/videosource.h:46:25: error: template argument 2 is invalid
src/core/videosource.h:49:2: error: ‘PixelFormat’ does not name a type
src/core/videosource.h:54:2: error: ‘PixelFormat’ does not name a type
src/core/videosource.h:92:29: error: ‘PixelFormat’ does not name a type
src/core/videosource.h:92:42: error: ISO C++ forbids declaration of ‘TargetFormats’ with no type [-fpermissive]
src/core/videosource.h:94:54: error: ‘PixelFormat’ has not been declared
In file included from src/core/ffms.cpp:26:0:
src/core/videoutils.h:38:47: error: ‘PixelFormat’ has not been declared
In file included from src/core/ffms.cpp:26:0:
src/core/videoutils.h:38:128: error: ‘PixelFormat’ has not been declared
src/core/videoutils.h:46:1: error: ‘PixelFormat’ does not name a type
src/core/ffms.cpp: In function ‘int FFMS_SetOutputFormatV2(FFMS_VideoSource*, const int*, int, int, int, FFMS_ErrorInfo*)’:
src/core/ffms.cpp:187:45: error: ISO C++ forbids declaration of ‘type name’ with no type [-fpermissive]
src/core/ffms.cpp:187:45: error: expected ‘>’ before ‘PixelFormat’
src/core/ffms.cpp:187:45: error: expected ‘(’ before ‘PixelFormat’
src/core/ffms.cpp:187:45: error: ‘PixelFormat’ was not declared in this scope
src/core/ffms.cpp:187:58: error: expected primary-expression before ‘>’ token
src/core/ffms.cpp: In function ‘int FFMS_SetInputFormatV(FFMS_VideoSource*, int, int, int, FFMS_ErrorInfo*)’:
src/core/ffms.cpp:201:57: error: expected type-specifier before ‘PixelFormat’
src/core/ffms.cpp:201:57: error: expected ‘>’ before ‘PixelFormat’
src/core/ffms.cpp:201:57: error: expected ‘(’ before ‘PixelFormat’
src/core/ffms.cpp:201:57: error: ‘PixelFormat’ was not declared in this scope
make: *** [src/core/ffms.o] Error 1
Errors revolve around scopes and type namings. My C / C++ abilities fall short here. Could anyone here help me, please? Has anyone been able to compile them lately?
FFMPEG-git builds fine and I can link other software to it. I can also build Avxsynth fine without FFMS2. Version() AVS function works fine in a file and for example mplayer can render it.
BR,
-J
qyot27
3rd November 2015, 21:17
In that case, you can clone my personal FFMS2 repo and checkout the 'patches' branch:
git clone git://github.com/qyot27/ffms2.git
cd ffms2
git checkout patches
and then continue from the previous instructions for the c_plugin branch.
The 'cplugin_master' and 'patches' branches are the usual staging area for the pull requests I periodically make so that the C-plugin gets updated (patches sits on top of cplugin_master, so if both branches exist, patches is newer). As such, always do a fresh clone, since I do rebase them from time to time or delete them outright when there's nothing to change.
jammupatu
4th November 2015, 10:07
In that case, you can clone my personal FFMS2 repo and checkout the 'patches' branch:
git clone git://github.com/qyot27/ffms2.git
cd ffms2
git checkout patches
and then continue from the previous instructions for the c_plugin branch.
The 'cplugin_master' and 'patches' branches are the usual staging area for the pull requests I periodically make so that the C-plugin gets updated (patches sits on top of cplugin_master, so if both branches exist, patches is newer). As such, always do a fresh clone, since I do rebase them from time to time or delete them outright when there's nothing to change.
Hi,
thanks for the alternate repo. I tried the 'patches' branch and it fails to similar errors. Both operating systems are 64-bit, by the way.
Jessie:
$ make
CXX src/core/audiosource.o
In file included from src/core/audiosource.h:24:0,
from src/core/audiosource.cpp:21:
src/core/utils.h:130:22: error: ‘FFMS_ResampleContext’ was not declared in this scope
typedef unknown_size<FFMS_ResampleContext, ffms_resample_alloc_context, ffms_resample_free> FFResampleContext;
^
src/core/utils.h:130:44: error: ‘ffms_resample_alloc_context’ was not declared in this scope
typedef unknown_size<FFMS_ResampleContext, ffms_resample_alloc_context, ffms_resample_free> FFResampleContext;
^
src/core/utils.h:130:73: error: ‘ffms_resample_free’ was not declared in this scope
typedef unknown_size<FFMS_ResampleContext, ffms_resample_alloc_context, ffms_resample_free> FFResampleContext;
^
src/core/utils.h:130:91: error: template argument 1 is invalid
typedef unknown_size<FFMS_ResampleContext, ffms_resample_alloc_context, ffms_resample_free> FFResampleContext;
^
src/core/utils.h:130:91: error: template argument 2 is invalid
src/core/utils.h:130:91: error: template argument 3 is invalid
src/core/utils.h:130:110: error: invalid type in declaration before ‘;’ token
typedef unknown_size<FFMS_ResampleContext, ffms_resample_alloc_context, ffms_resample_free> FFResampleContext;
^
src/core/audiosource.cpp: In member function ‘void FFMS_AudioSource::SetOutputFormat(const FFMS_ResampleOptions&)’:
src/core/audiosource.cpp:201:46: error: no matching function for call to ‘SetOptions(const FFMS_ResampleOptions&, FFResampleContext&, OptionMapper<FFMS_ResampleOptions> [17])’
SetOptions(opt, newContext, resample_options);
^
src/core/audiosource.cpp:201:46: note: candidate is:
In file included from src/core/audiosource.h:24:0,
from src/core/audiosource.cpp:21:
src/core/utils.h:206:6: note: template<class T, int N> void SetOptions(const T&, void*, OptionMapper<T> (&)[N])
void SetOptions(T const& src, void *opt, OptionMapper<T> (&options)[N]) {
^
src/core/utils.h:206:6: note: template argument deduction/substitution failed:
src/core/audiosource.cpp:201:46: note: cannot convert ‘newContext’ (type ‘FFResampleContext {aka int}’) to type ‘void*’
SetOptions(opt, newContext, resample_options);
^
src/core/audiosource.cpp:202:63: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_int(newContext, "in_sample_rate", AP.SampleRate, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:722:5: note: initializing argument 1 of ‘int av_opt_set_int(void*, const char*, int64_t, int)’
int av_opt_set_int (void *obj, const char *name, int64_t val, int search_flags);
^
src/core/audiosource.cpp:203:73: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_int(newContext, "in_sample_fmt", CodecContext->sample_fmt, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:722:5: note: initializing argument 1 of ‘int av_opt_set_int(void*, const char*, int64_t, int)’
int av_opt_set_int (void *obj, const char *name, int64_t val, int search_flags);
^
src/core/audiosource.cpp:204:69: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_int(newContext, "in_channel_layout", AP.ChannelLayout, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:722:5: note: initializing argument 1 of ‘int av_opt_set_int(void*, const char*, int64_t, int)’
int av_opt_set_int (void *obj, const char *name, int64_t val, int search_flags);
^
src/core/audiosource.cpp:206:65: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_int(newContext, "out_sample_rate", opt.SampleRate, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:722:5: note: initializing argument 1 of ‘int av_opt_set_int(void*, const char*, int64_t, int)’
int av_opt_set_int (void *obj, const char *name, int64_t val, int search_flags);
^
src/core/audiosource.cpp:209:82: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_channel_layout(newContext, "out_channel_layout", opt.ChannelLayout, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:730:5: note: initializing argument 1 of ‘int av_opt_set_channel_layout(void*, const char*, int64_t, int)’
int av_opt_set_channel_layout(void *obj, const char *name, int64_t ch_layout, int search_flags);
^
src/core/audiosource.cpp:210:89: error: invalid conversion from ‘FFResampleContext {aka int}’ to ‘void*’ [-fpermissive]
av_opt_set_sample_fmt(newContext, "out_sample_fmt", (AVSampleFormat)opt.SampleFormat, 0);
^
In file included from src/core/utils.h:28:0,
from src/core/audiosource.h:24,
from src/core/audiosource.cpp:21:
/opt/customlibs/include/libavutil/opt.h:728:5: note: initializing argument 1 of ‘int av_opt_set_sample_fmt(void*, const char*, AVSampleFormat, int)’
int av_opt_set_sample_fmt(void *obj, const char *name, enum AVSampleFormat fmt, int search_flags);
^
src/core/audiosource.cpp:213:36: error: ‘ffms_open_resampler’ was not declared in this scope
if (ffms_open_resampler(newContext))
^
src/core/audiosource.cpp:216:13: error: request for member ‘swap’ in ‘newContext’, which is of non-class type ‘FFResampleContext {aka int}’
newContext.swap(ResampleContext);
^
src/core/audiosource.cpp: In member function ‘std::unique_ptr<FFMS_ResampleOptions> FFMS_AudioSource::CreateResampleOptions() const’:
src/core/audiosource.cpp:220:58: error: no matching function for call to ‘ReadOptions(const FFResampleContext&, OptionMapper<FFMS_ResampleOptions> [17])’
auto ret = ReadOptions(ResampleContext, resample_options);
^
src/core/audiosource.cpp:220:58: note: candidate is:
In file included from src/core/audiosource.h:24:0,
from src/core/audiosource.cpp:21:
src/core/utils.h:198:20: note: template<class T, int N> std::unique_ptr<T> ReadOptions(void*, OptionMapper<T> (&)[N])
std::unique_ptr<T> ReadOptions(void *opt, OptionMapper<T> (&options)[N]) {
^
src/core/utils.h:198:20: note: template argument deduction/substitution failed:
src/core/audiosource.cpp:220:58: note: cannot convert ‘((const FFMS_AudioSource*)this)->FFMS_AudioSource::ResampleContext’ (type ‘const FFResampleContext {aka const int}’) to type ‘void*’
auto ret = ReadOptions(ResampleContext, resample_options);
^
src/core/audiosource.cpp: In member function ‘void FFMS_AudioSource::ResampleAndCache(FFMS_AudioSource::CacheIterator)’:
src/core/audiosource.cpp:236:130: error: ‘ffms_convert’ was not declared in this scope
DecodeFrame->extended_data, DecodeFrame->nb_samples, av_get_bytes_per_sample(CodecContext->sample_fmt), DecodeFrame->nb_samples);
^
src/core/audiosource.cpp: In member function ‘std::unique_ptr<FFMS_ResampleOptions> FFMS_AudioSource::CreateResampleOptions() const’:
src/core/audiosource.cpp:225:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
<builtin>: recipe for target 'src/core/audiosource.o' failed
make: *** [src/core/audiosource.o] Error 1
Wheezy compiles a bit further, but eventually errors out here:
CXX src/avxsynth/avisynth.o
In file included from src/avxsynth/avisynth.cpp:25:0:
src/avxsynth/avsutils.h:31:1: error: ‘PixelFormat’ does not name a type
src/avxsynth/avisynth.cpp: In function ‘avxsynth::AVSValue CreateFFIndex(avxsynth::AVSValue, void*, avxsynth::IScriptEnvironment*)’:
src/avxsynth/avisynth.cpp:75:43: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
make: *** [src/avxsynth/avisynth.o] Error 1
Strange? I'm not running any special CFLAGS etc, just doublechecked it. GCC and all tools are Debian official ones.
BR,
-J
jammupatu
5th November 2015, 18:55
Installed a fresh Jessie 64-bit as a virtual machine and the same problem occurred.
BR,
-J
jammupatu
9th November 2015, 18:01
Installed a fresh Jessie 64-bit as a virtual machine and the same problem occurred.
BR,
-J
Fixed by deploying another Jessie 64-bit virtual machine and making a build environment from scratch. The important thing was that I paid attention on what packages to install. In my case Libav / FFMPEG ones were a big no-no as I am compiling a lot of custom stuff which links to my FFMPEG.
Also, I couldn't / can't accomplish the build process with the official repo. Here is how I compiled it (includes source):
git clone git://github.com/qyot27/ffms2.git
cd ffms2
git checkout patches
./configure --enable-avxsynth --enable-shared --enable-pic
make
make install or checkinstall <params>
-J
perforator
21st January 2016, 19:51
Hi,
I just wonder if one can run all scripts made for Avisynth in Avxsynth ? Or is it perhaps more depending on different plugins?
More precisely these made by "videoFred" http://forum.doom9.org/showthread.php?t=144271
I havn't been able to build a working setup on my Linux Mint installation, else I would have tried on my own. :(
:helpful:
qyot27
21st January 2016, 20:36
Hi,
I just wonder if one can run all scripts made for Avisynth in Avxsynth ? Or is it perhaps more depending on different plugins?
No, it cannot. Only *maybe* five plugins were ever ported to AvxSynth. Only the core functions mostly work (although a couple are disabled).
More precisely these made by "videoFred" http://forum.doom9.org/showthread.php?t=144271
And I don't think any of those plugins were the ones that did get ports.
You're best off installing AviSynth and plugins under Wine and then either encoding with Windows builds of FFmpeg, x264, etc. or piping to native Linux builds of those tools with avs2pipemod or a Windows build of FFmpeg. Or trying to replicate those scripts in Python with VapourSynth and its plugins (which are available natively).
foxyshadis
21st January 2016, 20:56
This project is as dead as it gets; VapourSynth is a Linux-compatible replacement. The scripts aren't Avisynth compatible, but yours likely can easily be reworked into VS scripts, most of the common plugins have been ported. As a side benefit, it's a lot faster than Avisynth.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.