Antonio,

Thanks, this could be a useful starting point for me or someone else.

I’ve pushed my old branch to GitHub that adds support for ffmpeg up to around version 0.11 (maybe a little beyond):

https://github.com/vxl/vxl/tree/dev/support-ffmpeg-0.11

I’ve started naming the vidl_ffmpeg file variant to match the ffmpeg version that they support (e.g. vidl_ffmpeg_ostream_v0.11.txt instead of vidl_ffmpeg_ostream_v5.txt).  I’ll will merge this branch to master soon, but I want to make sure it still builds after merging to master.  Some one could then rebase your work on top of this and update the naming of files.

—Matt


On Jun 5, 2014, at 10:31 AM, Antonio Garrido Carrillo <A.Garrido@decsai.ugr.es> wrote:

Matt,

I started to change this ffmpeg part of vxl. I have installed Ubuntu 14.04 which includes a very new version of ffmpeg library. The problem is that I do not have time for this. Morever, I do not know anything about ffmpeg.

I found several changes because some functions were marked as deprecated and they are not included in current ffmpeg library. I spent several hours to try to get at least a compilable version of vxl. There were too many changes... too many "it might work"... I stoped changing the code when I found some more important changes in the library

Please find attached some changes, the first I did to start the adaptation to the new ffmpeg API. It is possible them to be wrong, but at least here you are my two cents

Antonio


El 05/06/14 15:22, Matthew Leotta escribió:
Dustin,

I just realized that I have a few vxl ffmpeg updates that didn’t make it upstream.  I’ll try to get those changes in as soon as I can.  It probably won’t solve your problem (these changes target ffmpeg 0.9 and 0.11, still very old), but the diffs will give a better understanding of the approach I’ve used.  If you want to get more involved we can take the discussion off of this list and possibly on to the vxl-maintainers mailing list.

—Matt


On Jun 5, 2014, at 8:52 AM, Dustin Hebecker <dustin.hebecker@gmail.com> wrote:

Hi Matt,

Thanks for the fast reply.

Well, I know how to program. But never worked on bigger projects like libraries or any repository packages.
What would I have to do? (rename functions to match the new ones in ffmpeg?)
I'm a little short of time myself but I would be happy to (at least) try anyway.

Cheers Dustin

p.s. I'm using ffmpeg 1:2.2.3-1


On 06/05/2014 02:31 PM, Matthew Leotta wrote:
Dustin,

What version of ffmpeg are you using?

Unfortunately the ffmpeg API evolves very rapidly.  For a while, I was updating VXL occasionally to adapt to these changes.  In recently years I’ve become too busy to keep up with it.  The right solution would be to update the VXL code again, but I don’t know when I’ll find time to do that.  If you are interested in helping to contribute to VXL to make this enhancement I can provide guidance.

The quick, but less ideal, solution is to roll back to an older version of ffmpeg that works with VXL.

—Matt


On Jun 5, 2014, at 8:16 AM, Dustin Hebecker <dustin.hebecker@gmail.com> wrote:

Hello,

I'm trying to compile vxl on my Arch Linux machine and encounter the following error:

[ 29%] Building CXX object core/vidl/CMakeFiles/vidl.dir/vidl_ffmpeg_istream.o
In file included from /home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream.cxx:29:0:
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx: In member function ‘virtual bool vidl_ffmpeg_istream::open(const string&)’:
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:146:8: warning: ‘int av_find_stream_info(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:1833) [-Wdeprecated-declarations]
if ( av_find_stream_info( is_->fmt_cxt_ ) < 0 ) {
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:146:43: warning: ‘int av_find_stream_info(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:1833) [-Wdeprecated-declarations]
if ( av_find_stream_info( is_->fmt_cxt_ ) < 0 ) {
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:168:43: error: ‘avcodec_open’ was not declared in this scope
if ( !codec || avcodec_open( enc, codec ) < 0 ) {
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:173:17: warning: ‘AVFrame* avcodec_alloc_frame()’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3422) [-Wdeprecated-declarations]
is_->frame_ = avcodec_alloc_frame();
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:173:37: warning: ‘AVFrame* avcodec_alloc_frame()’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:3422) [-Wdeprecated-declarations]
is_->frame_ = avcodec_alloc_frame();
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx: In member function ‘virtual void vidl_ffmpeg_istream::close()’:
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:219:5: warning: ‘void av_close_input_file(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:2013) [-Wdeprecated-declarations]
av_close_input_file( is_->fmt_cxt_ );
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:219:40: warning: ‘void av_close_input_file(AVFormatContext*)’ is deprecated (declared at /usr/include/libavformat/avformat.h:2013) [-Wdeprecated-declarations]
av_close_input_file( is_->fmt_cxt_ );
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx: In member function ‘virtual vidl_frame_sptr vidl_ffmpeg_istream::current_frame()’:
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:471:7: warning: ‘int avpicture_deinterlace(AVPicture*, const AVPicture*, AVPixelFormat, int, int)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:4585) [-Wdeprecated-declarations]
avpicture_deinterlace( (AVPicture*)is_->frame_, (AVPicture*)is_->frame_,
^
/home/<user>/<folder>/vxl/core/vidl/vidl_ffmpeg_istream_v3.txx:472:58: warning: ‘int avpicture_deinterlace(AVPicture*, const AVPicture*, AVPixelFormat, int, int)’ is deprecated (declared at /usr/include/libavcodec/avcodec.h:4585) [-Wdeprecated-declarations]
enc->pix_fmt, width, height );
^
core/vidl/CMakeFiles/vidl.dir/build.make:264: recipe for target 'core/vidl/CMakeFiles/vidl.dir/vidl_ffmpeg_istream.o' failed
make[2]: *** [core/vidl/CMakeFiles/vidl.dir/vidl_ffmpeg_istream.o] Error 1
CMakeFiles/Makefile2:3282: recipe for target 'core/vidl/CMakeFiles/vidl.dir/all' failed
make[1]: *** [core/vidl/CMakeFiles/vidl.dir/all] Error 2
Makefile:126: recipe for target 'all' failed
make: *** [all] Error 2

From briefly reading the errors i assume it's caused by the changes in ffmpeg as mentioned before.
IS there a solution by now?

Kind regards Dustin

<dustin_hebecker.vcf>------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech_______________________________________________
Vxl-users mailing list
Vxl-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vxl-users
<dustin_hebecker.vcf>

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Vxl-users mailing list
Vxl-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/vxl-users


--
-----------------------------------------------------------------------
Prof. Dr. Antonio Garrido Carrillo
Depto. Ciencias de la Computación e Inteligencia Artificial
Escuela Técnica Superior de Ingenierías Informática y de Telecomunicación
C/ Periodista Daniel Saucedo Aranda s/n
18071. Granada. SPAIN
----------------------------------------------------------------------


"Este mensaje se dirige exclusivamente a su destinatario y puede contener información privilegiada o confidencial. Si no es Ud. el
destinatario indicado, queda notificado de que la utilización, divulgación o copia sin autorización está prohibida en virtud de
la legislación vigente. Si ha recibido este mensaje por error, se ruega lo comunique inmediatamente por esta misma vía y proceda a su destrucción.

This message is intended exclusively for its addressee and may contain information that is CONFIDENTIAL and protected by professional privilege. If you are not the intended recipient you are hereby notified that any dissemination, copy or disclosure of this communication is strictly prohibited by law. If this message has been received in error, please immediately notify us via e-mail and delete it".

<CMakeLists.txt><vidl_ffmpeg_istream.cxx><vidl_ffmpeg_istream_v4.txx><vidl_ffmpeg_ostream.cxx><vidl_ffmpeg_ostream_v5.txx>