[libav-bugs] [Bug 714] New: avconv: in "best" video stream selection, please break resolution ties by bitrate

bugzilla at libav.org bugzilla at libav.org
Mon Jul 7 13:07:38 CEST 2014


https://bugzilla.libav.org/show_bug.cgi?id=714

           Summary: avconv: in "best" video stream selection, please break
                    resolution ties by bitrate
           Product: Libav
           Version: git HEAD
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: Normal
         Component: general
        AssignedTo: bugzilla at libav.org
        ReportedBy: siretart at tauware.de


From: Lionel Elie Mamane <lionel at mamane.lu>
To: Debian Bug Tracking System <submit at bugs.debian.org>
Subject: avconv: in "best" video stream selection, please break resolution ties
by bitrate
Date: Mon, 30 Jun 2014 13:08:55 +0200
Package: libav-tools
Version: 6:10.1-1
Severity: normal

Take for example the video at
http://player.ooyala.com/player/ipad/NoMndlbDpMPxEDCuGI2hYTcaQwVSQUBO.m3u8?js=1
(originally from http://www.aopa.org/Education/Safety-Videos.aspx?ipp=100)
It is served over applehttp through ooyala.

It has 5 variants of differing encoding, resolution and bitrate, *but*
among same resolution (and encoding), there are sometimes multiple
bitrate choices. For example:

  Program 0 
    Metadata:
      variant_bitrate : 1230000
    Stream #0.0: Video: h264 (High), yuv420p, 1280x720 [PAR 1:1 DAR 16:9],
23.98 fps, 90k tbn, 47.95 tbc
    Metadata:
      variant_bitrate : 1230000
    Stream #0.1: Audio: aac, 44100 Hz, stereo, fltp, 133 kb/s
    Metadata:
      variant_bitrate : 1230000
  (...)
  Program 3 
    Metadata:
      variant_bitrate : 1746000
    Stream #0.6: Video: h264 (High), yuv420p, 1280x720 [PAR 1:1 DAR 16:9],
23.98 fps, 90k tbn, 47.95 tbc
    Metadata:
      variant_bitrate : 1746000
    Stream #0.7: Audio: aac, 44100 Hz, stereo, fltp, 133 kb/s
    Metadata:
      variant_bitrate : 1746000
  Program 4 
    Metadata:
      variant_bitrate : 2798000
    Stream #0.8: Video: h264 (High), yuv420p, 1280x720 [PAR 1:1 DAR 16:9],
23.98 fps, 90k tbn, 47.95 tbc
    Metadata:
      variant_bitrate : 2798000
    Stream #0.9: Audio: aac, 44100 Hz, stereo, fltp, 133 kb/s
    Metadata:
      variant_bitrate : 2798000

"Program 4" is better than "Program 0", but avconv selects "Program
0", probably because it is the first among the ones that have highest
resolution (Program 1 and 2 have resolution 480x270 and 640x360,
respectively, and have ' h264 (Constrained Baseline)' video).

The avconf manpage says:

  By default avconv tries to pick the "best" stream of each type
  present in input files and add them to each output file. For video,
  this means the highest resolution, (...)

That's a good start, but to handle the above scenario well, please
change avconv to select the highest bitrate among the videos that have
the same (highest) resolution. About audio, I suppose it would be best
to (by default) favour the audio that comes with the selected "best"
Program.

-- System Information:
Debian Release: jessie/sid
  APT prefers testing-updates
  APT policy: (600, 'testing-updates'), (600, 'testing'), (300, 'unstable'),
(1, 'experimental')
Architecture: amd64 (x86_64)

-- 
Configure bugmail: https://bugzilla.libav.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.


More information about the libav-bugs mailing list