Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#18256 closed enhancement (fixed)

ffmpeg: set default variants to include all optional codecs

Reported by: dbevans (David B. Evans) Owned by: dbevans (David B. Evans)
Priority: Normal Milestone:
Component: ports Version: 1.7.0
Keywords: vorbis faac faad lame theora x264 xvid Cc: jm@…, ryandesign (Ryan Carsten Schmidt), simon@…, mf2k (Frank Schima)
Port: ffmpeg

Description (last modified by dbevans (David B. Evans))

Per discussion lead by Jean-Michel Pouré on macports-devel http://lists.macosforge.org/pipermail/macports-dev/2009-January/007102.html the attached patch sets default_variants to include all available optional codecs on the grounds that the spirit of the distribution is to provide support for conversion between as many different encodings as possible. In addition, by limiting the default selection of codecs in ffmpeg, the functionality of ports that depend upon ffmpeg (sox, kdenlive, gstreamer, etc) is correspondingly reduced as well.

This includes

+a52 +extvorbis +faac +faad +lame +theora +x264 +xvid

The following variants remain optional by default

+avfilter (experimental)
+gpl (automatically included as necessary)
+mmx (experimental/buggy)
+postproc (experimental)

The revision is incremented to reflect the change in port functionality (for the better, IMHO)

Attachments (1)

patch-ffmpeg.diff (5.5 KB) - added by dbevans (David B. Evans) 15 years ago.
Patch for Portfile (rev 4) (corrected language in ui_msgs)

Download all attachments as: .zip

Change History (17)

comment:1 Changed 15 years ago by dbevans (David B. Evans)

Description: modified (diff)

comment:2 Changed 15 years ago by dbevans (David B. Evans)

Description: modified (diff)

comment:3 Changed 15 years ago by jmroot (Joshua Root)

There's no point having variants if you're going to make them all default. If you deselect them at install time, they come back on upgrade: #2377

comment:4 Changed 15 years ago by ryandesign (Ryan Carsten Schmidt)

Right. See also yesterday's message from the mailing list. So the variants should be removed and their functionality incorporated into the port directly. If there is value in allowing users to disable some of these features, then new +no_a52, +no_extvorbis etc. variants could be created. But fewer variants are better in general.

comment:5 Changed 15 years ago by dbevans (David B. Evans)

Good, thanks for the input. Revised patch is attached. Is there any feeling as to whether avfilter and postproc should be included in the default? Are they used by any dependent applications? Support for additional encodings could be added if the required libraries were ported but that's another iteration.

Here's the default configuration as it stands

install prefix            /opt/local
source path               /opt/local/var/macports/build/_Volumes_wdc-320_opt_macports_trunk_dports_multimedia_ffmpeg/work/trunk
C compiler                gcc-4.0
.align is power-of-two    yes
ARCH                      powerpc (generic)
big-endian                yes
AltiVec enabled           yes
dcbzl available           yes
gprof enabled             no
debug symbols             yes
strip symbols             yes
optimizations             yes
static                    yes
shared                    yes
postprocessing support    no
software scaler enabled   no
new filter support        no
filters using lavformat   no
video hooking             no
network support           yes
IPv6 support              no
threading support         pthreads
SDL support               yes
Sun medialib support      no
AVISynth enabled          no
liba52 support            yes
liba52 dlopened           no
libamr-nb support         no
libamr-wb support         no
libdc1394 support         no
libdirac enabled          no
libfaac enabled           yes
libfaad enabled           yes
libfaad dlopened          no
libgsm enabled            no
libmp3lame enabled        yes
libnut enabled            no
libschroedinger enabled   no
libtheora enabled         yes
libvorbis enabled         yes
libx264 enabled           yes
libxvid enabled           yes
zlib enabled              yes
bzlib enabled             yes

Enabled decoders:
aac                     flv                     pcm_u24be
aasc                    fourxm                  pcm_u24le
adpcm_4xm               fraps                   pcm_u32be
adpcm_adx               gif                     pcm_u32le
adpcm_ct                h261                    pcm_u8
adpcm_ea                h263                    pcm_zork
adpcm_ea_maxis_xa       h263i                   pcx
adpcm_ea_r1             h264                    png
adpcm_ea_r2             huffyuv                 ptx
adpcm_ea_r3             idcin                   qdm2
adpcm_ea_xas            imc                     qdraw
adpcm_g726              indeo2                  qpeg
adpcm_ima_amv           indeo3                  qtrle
adpcm_ima_dk3           interplay_dpcm          ra_144
adpcm_ima_dk4           interplay_video         ra_288
adpcm_ima_ea_eacs       jpegls                  rawvideo
adpcm_ima_ea_sead       kmvc                    rl2
adpcm_ima_qt            liba52                  roq
adpcm_ima_smjpeg        libfaad                 roq_dpcm
adpcm_ima_wav           loco                    rpza
adpcm_ima_ws            mace3                   rv10
adpcm_ms                mace6                   rv20
adpcm_sbpro_2           mdec                    sgi
adpcm_sbpro_3           mimic                   shorten
adpcm_sbpro_4           mjpeg                   smackaud
adpcm_swf               mjpegb                  smacker
adpcm_thp               mlp                     smc
adpcm_xa                mmvideo                 snow
adpcm_yamaha            motionpixels            sol_dpcm
alac                    mp2                     sonic
amv                     mp3                     sp5x
ape                     mp3adu                  sunrast
asv1                    mp3on4                  svq1
asv2                    mpc7                    svq3
atrac3                  mpc8                    targa
avs                     mpeg1video              theora
bethsoftvid             mpeg2video              thp
bfi                     mpeg4                   tiertexseqvideo
bmp                     mpeg4aac                tiff
c93                     mpegvideo               truemotion1
cavs                    msmpeg4v1               truemotion2
cinepak                 msmpeg4v2               truespeech
cljr                    msmpeg4v3               tscc
cook                    msrle                   tta
cscd                    msvideo1                txd
cyuv                    mszh                    ulti
dca                     nellymoser              vb
dnxhd                   nuv                     vc1
dsicinaudio             pcm_alaw                vcr1
dsicinvideo             pcm_dvd                 vmdaudio
dvbsub                  pcm_f32be               vmdvideo
dvdsub                  pcm_f32le               vmnc
dvvideo                 pcm_f64be               vorbis
dxa                     pcm_f64le               vp3
eac3                    pcm_mulaw               vp5
eacmv                   pcm_s16be               vp6
eatgv                   pcm_s16le               vp6a
eightbps                pcm_s16le_planar        vp6f
eightsvx_exp            pcm_s24be               vqa
eightsvx_fib            pcm_s24daud             wavpack
escape124               pcm_s24le               wmav1
ffv1                    pcm_s32be               wmav2
ffvhuff                 pcm_s32le               wmv1
flac                    pcm_s8                  wmv2
flashsv                 pcm_u16be               wmv3
flic                    pcm_u16le               wnv1
ws_snd1                 xl                      zmbv
xan_dpcm                xsub
xan_wc3                 zlib

Enabled encoders:
ac3                     libx264                 pcm_u24le
adpcm_adx               libxvid                 pcm_u32be
adpcm_g726              ljpeg                   pcm_u32le
adpcm_ima_qt            mjpeg                   pcm_u8
adpcm_ima_wav           mp2                     pcm_zork
adpcm_ms                mpeg1video              pgm
adpcm_swf               mpeg2video              pgmyuv
adpcm_yamaha            mpeg4                   png
alac                    msmpeg4v1               ppm
asv1                    msmpeg4v2               qtrle
asv2                    msmpeg4v3               rawvideo
bmp                     nellymoser              roq
dnxhd                   pam                     roq_dpcm
dvbsub                  pbm                     rv10
dvdsub                  pcm_alaw                rv20
dvvideo                 pcm_f32be               sgi
ffv1                    pcm_f32le               snow
ffvhuff                 pcm_f64be               sonic
flac                    pcm_f64le               sonic_ls
flashsv                 pcm_mulaw               svq1
flv                     pcm_s16be               targa
gif                     pcm_s16le               tiff
h261                    pcm_s24be               vorbis
h263                    pcm_s24daud             wmav1
h263p                   pcm_s24le               wmav2
huffyuv                 pcm_s32be               wmv1
jpegls                  pcm_s32le               wmv2
libfaac                 pcm_s8                  zlib
libmp3lame              pcm_u16be               zmbv
libtheora               pcm_u16le
libvorbis               pcm_u24be

Enabled parsers:
aac                     dvdsub                  mpeg4video
ac3                     h261                    mpegaudio
cavsvideo               h263                    mpegvideo
dca                     h264                    pnm
dirac                   mjpeg                   vc1
dvbsub                  mlp                     vp3

Enabled demuxers:
aac                     lmlm4                   pcm_u16le
ac3                     m4v                     pcm_u24be
aiff                    matroska                pcm_u24le
amr                     mjpeg                   pcm_u32be
apc                     mlp                     pcm_u32le
ape                     mm                      pcm_u8
asf                     mmf                     pva
au                      mov                     rawvideo
avi                     mp3                     redir
avs                     mpc                     rl2
bethsoftvid             mpc8                    rm
bfi                     mpegps                  roq
c93                     mpegts                  rpl
daud                    mpegtsraw               rtsp
dirac                   mpegvideo               sdp
dsicin                  msnwc_tcp               segafilm
dts                     mtv                     shorten
dv                      mvi                     siff
dxa                     mxf                     smacker
ea                      nsv                     sol
ea_cdata                nut                     str
eac3                    nuv                     swf
ffm                     ogg                     thp
flac                    oma                     tiertexseq
flic                    pcm_alaw                tta
flv                     pcm_f32be               txd
fourxm                  pcm_f32le               vc1
gsm                     pcm_f64be               vc1t
gxf                     pcm_f64le               vmd
h261                    pcm_mulaw               voc
h263                    pcm_s16be               wav
h264                    pcm_s16le               wc3
idcin                   pcm_s24be               wsaud
iff                     pcm_s24le               wsvqa
image2                  pcm_s32be               wv
image2pipe              pcm_s32le               xa
ingenient               pcm_s8                  yuv4mpegpipe
ipmovie                 pcm_u16be

Enabled muxers:
ac3                     m4v                     pcm_mulaw
adts                    matroska                pcm_s16be
aiff                    matroska_audio          pcm_s16le
amr                     mjpeg                   pcm_s24be
asf                     mmf                     pcm_s24le
asf_stream              mov                     pcm_s32be
au                      mp2                     pcm_s32le
avi                     mp3                     pcm_s8
avm2                    mp4                     pcm_u16be
crc                     mpeg1system             pcm_u16le
daud                    mpeg1vcd                pcm_u24be
dirac                   mpeg1video              pcm_u24le
dts                     mpeg2dvd                pcm_u32be
dv                      mpeg2svcd               pcm_u32le
eac3                    mpeg2video              pcm_u8
ffm                     mpeg2vob                psp
flac                    mpegts                  rawvideo
flv                     mpjpeg                  rm
framecrc                mxf                     roq
gif                     null                    rtp
gxf                     nut                     swf
h261                    ogg                     tg2
h263                    pcm_alaw                tgp
h264                    pcm_f32be               vc1t
image2                  pcm_f32le               voc
image2pipe              pcm_f64be               wav
ipod                    pcm_f64le               yuv4mpegpipe

Enabled protocols:
file                    pipe                    tcp
http                    rtp                     udp

Enabled filters:
crop

Enabled bsfs:
dump_extradata          mov2textsub             remove_extradata
h264_mp4toannexb        mp3_header_compress     text2movsub
imx_dump_header         mp3_header_decompress
mjpega_dump_header      noise

Enabled indevs:

Enabled outdevs:

License: GPL

comment:6 Changed 15 years ago by simon@…

Cc: simon@… added

Cc Me!

comment:7 Changed 15 years ago by simon@…

Please don't pull in all those deps as default. I like to be able to choose what I want to install and I think it is a bit strange to force users to suddenly install GPLed variants.

comment:8 Changed 15 years ago by jm@…

Some codecs are not variants and are really needed:

  • lame: provides export to mp3. Needed to export to HDV (Mpeg2 video + mp3 sound).
  • x264: export to AVCHD (95% of camcorders sold by Canon in 2009 will be AVCHD).
  • postproc is needed by MLT.

Read our recommanded line: http://www.kdenlive.org/user-manual/downloading-and-installing-kdenlive/installing-source/installing-ffmpeg

In video editing, the codecs used in files are unknown and depend on projects. It can be very frustrating for video editors to lack some codecs.

comment:9 in reply to:  7 ; Changed 15 years ago by illogic-al@…

Replying to simon@…:

Please don't pull in all those deps as default. I like to be able to choose what I want to install and I think it is a bit strange to force users to suddenly install GPLed variants.

you should still be able to disable what you don't want based on variants. the goal here is to not disadvantage users who just want to install software. they should not have to worry about which variants they need enabled. those who want to customize should be the ones doing the work imo.

comment:10 in reply to:  9 Changed 15 years ago by simon@…

Replying to illogic-al@…:

Replying to simon@…:

Please don't pull in all those deps as default. I like to be able to choose what I want to install and I think it is a bit strange to force users to suddenly install GPLed variants.

you should still be able to disable what you don't want based on variants. the goal here is to not disadvantage users who just want to install software. they should not have to worry about which variants they need enabled. those who want to customize should be the ones doing the work imo.

For that you would need variants, the latest patch added in this ticket removes all the variants. To be able to disable all those effectively there would need to be +no_feature variants as default variants get pulled in during a port upgrade no matter if they had been disabled via the "-variant" syntax or not.

comment:11 in reply to:  7 ; Changed 15 years ago by mf2k (Frank Schima)

Replying to simon@…:

Please don't pull in all those deps as default. I like to be able to choose what I want to install and I think it is a bit strange to force users to suddenly install GPLed variants.

This is a good point. I think there should be a single variant called something like no_gpl which disables all GPLed components (the proposed former variants).

Simon: can you identify all the components that are GPLed?

comment:12 Changed 15 years ago by mf2k (Frank Schima)

Cc: macsforever2000@… added

Cc Me!

comment:13 in reply to:  11 Changed 15 years ago by simon@…

Replying to macsforever2000@…:

This is a good point. I think there should be a single variant called something like no_gpl which disables all GPLed components (the proposed former variants).

Simon: can you identify all the components that are GPLed?

Sure,

according to the configure script the following are GPLed: liba52, libx264, libxvid, libfad2, x11grab, swscale Not all of those have a variant though, but if you explicitly use --disable-gpl configure will bail out when trying to use one of those.

comment:14 Changed 15 years ago by dbevans (David B. Evans)

Owner: changed from acho@… to devans@…

OK, I've attached a new patch that I think reflects the comments submitted so far

  • To address MJs issue of broadest possible coverage have enabled all nonfree and GPLed modules that are supported by current ports
  • a52 remains the default variant as it needs to included in the default but has special post-destroot processing (removed in subsequent trunk revs)
  • removed all other existing variants
  • add two new variants no_gpl and no_nonfree . a52 conflicts with no_gpl and will error out unless -a52 is included. Again a temporary situation.
  • added ui_msgs in post-activate to announce the licensing consequences of the various variants as ffmpeg does with its configuration status report.

Licensing:

  • default -- binaries and libraries are unredistributable (is this a word?) due to the inclusion of nonfree code although I can't determine what it is.
  • +no_nonfree -- GPL applies due to the presence of the GPL modules listed above
  • +no_nonfree +no_gpl -- GPLed modules disabled, LGPL applies to the balance.

I'm prepared to commit these changes as a reasonable compromise on the various positions unless someone drastically objects.

Changed 15 years ago by dbevans (David B. Evans)

Attachment: patch-ffmpeg.diff added

Patch for Portfile (rev 4) (corrected language in ui_msgs)

comment:15 Changed 15 years ago by dbevans (David B. Evans)

Resolution: fixed
Status: newclosed

Committed changes for both ffmpeg and ffmpeg-devel (with appropriate adjustments) in r46115, r46116. ffmpeg-devel libx264 support disabled in r46118 pending required version upgrade to port x264, #18238.

comment:16 Changed 15 years ago by (none)

Milestone: Port Enhancements

Milestone Port Enhancements deleted

Note: See TracTickets for help on using tickets.