[FFmpeg-devel] [PATCH] doc/examples/muxing: make compatible with C++
anshul.ffmpeg at gmail.com
Wed Mar 19 14:51:36 CET 2014
Michael Niedermayer <michaelni at gmx.at> wrote:
>On Wed, Mar 19, 2014 at 10:40:35AM +0100, Stefano Sabatini wrote:
>> On date Wednesday 2014-03-19 11:45:08 +0530, anshul encoded:
>> > From dd883b6260e9622ab030dca3afc98e651c5cfd01 Mon Sep 17 00:00:00
>> > From: Anshul Maheshwari <er.anshul.maheshwari at gmail.com>
>> > Date: Wed, 19 Mar 2014 11:42:06 +0530
>> > Subject: [PATCH] added CPlusPlus examples
>> > ---
>> > MAINTAINERS | 5 +
>> > Makefile | 7 +-
>> > doc/Makefile | 17 +-
>> > doc/examples_cpp/Makefile | 44 ++
>> > doc/examples_cpp/README | 23 +
>> > doc/examples_cpp/avcodec.cpp | 659
>> > doc/examples_cpp/avio_reading.cpp | 134 ++++++
>> > doc/examples_cpp/demuxing_decoding.cpp | 387 +++++++++++++++++
>> > doc/examples_cpp/filter_audio.cpp | 365 ++++++++++++++++
>> > doc/examples_cpp/filtering_audio.cpp | 283 +++++++++++++
>> > doc/examples_cpp/filtering_video.cpp | 263 ++++++++++++
>> > doc/examples_cpp/metadata.cpp | 58 +++
>> > doc/examples_cpp/muxing.cpp | 614
>> > doc/examples_cpp/remuxing.cpp | 173 ++++++++
>> > doc/examples_cpp/resampling_audio.cpp | 218 ++++++++++
>> > doc/examples_cpp/scaling_video.cpp | 143 +++++++
>> > doc/examples_cpp/transcode_aac.cpp | 754
>> > doc/examples_cpp/transcoding.cpp | 602
>> > 18 files changed, 4746 insertions(+), 3 deletions(-)
>> > create mode 100644 doc/examples_cpp/Makefile
>> > create mode 100644 doc/examples_cpp/README
>> > create mode 100644 doc/examples_cpp/avcodec.cpp
>> > create mode 100644 doc/examples_cpp/avio_reading.cpp
>> > create mode 100644 doc/examples_cpp/demuxing_decoding.cpp
>> > create mode 100644 doc/examples_cpp/filter_audio.cpp
>> > create mode 100644 doc/examples_cpp/filtering_audio.cpp
>> > create mode 100644 doc/examples_cpp/filtering_video.cpp
>> > create mode 100644 doc/examples_cpp/metadata.cpp
>> > create mode 100644 doc/examples_cpp/muxing.cpp
>> > create mode 100644 doc/examples_cpp/remuxing.cpp
>> > create mode 100644 doc/examples_cpp/resampling_audio.cpp
>> > create mode 100644 doc/examples_cpp/scaling_video.cpp
>> > create mode 100644 doc/examples_cpp/transcode_aac.cpp
>> > create mode 100644 doc/examples_cpp/transcoding.cpp
>> As documentation maintainer I'm against this, since it's going to be
>> hell to maintain, and I don't want to duplicate code changes/tests
>> have to keep C/C++ code in synch.
>Understood, you dont have to touch or maintain these examples though
>this would be the "duty" of their maintainer
>+C++ Examples Anshul MAheshwari
>And in case they become unmaintained, removing them, to prevent
>outdated examples to be there, is easy
>> What I suggest instead: we extend documentation on the wiki regarding
>> FFmpeg support with C++, so that the user knows exactly what
>> conversions are required when porting the code to C++.
>Thats possible but its inconvenient compared to having examples
>where these changes have already been done.
>so to summarize we have
>A. add ~6 lines of code to each example to make it C++ compatible
>B. add seperate C++ examples
>C. add patches that get applied by makefile to create c++ examples
>D. add a description to the wiki/faq/whatever on how to make the
> examples C++ compatible
>Iam happy with any solution if theres a consensus, that is if the
>people in this thread, including Anshul agree.
>In absence of a consensus, anyone can volunteer to maintain C++
>examples and its then his/her decission on how to maintain them,
>that is in git as seperate files or on the wiki or as patches.
>I think its better if a consensus is found though, but i dont know
>if thats possible, peoples oppinion seem far appart
I agree with B, in that way we can add example in most other language.
It would be easy to write an seprate example for python, php or gimp scripts. Rather option A and C does not look possible for python and PHP.
Option D is good for maintenance prospect's but user are more happy with example. I think thats why linux developer's add examples with most trivial system call.
I am happy to maintain those examples.
Sent from my Android device with K-9 Mail. Please excuse my brevity.
More information about the ffmpeg-devel