[FFmpeg-devel] [PATCH 2/2] lavc/mediacodec: bypass width/height restrictions when looking for a decoder

Matthieu Bouron matthieu.bouron at gmail.com
Mon Jun 6 11:41:41 CEST 2016


On Mon, Jun 06, 2016 at 11:29:03AM +0200, Hendrik Leppkes wrote:
> On Mon, Jun 6, 2016 at 9:54 AM, Matthieu Bouron
> <matthieu.bouron at gmail.com> wrote:
> > On Tue, May 31, 2016 at 05:41:16PM +0200, Matthieu Bouron wrote:
> >> On Tue, May 31, 2016 at 03:51:20PM +0200, Matthieu Bouron wrote:
> >> > On Tue, May 31, 2016 at 03:35:49PM +0200, Hendrik Leppkes wrote:
> >> > > On Tue, May 31, 2016 at 3:00 PM, Matthieu Bouron
> >> > > <matthieu.bouron at gmail.com> wrote:
> >> > > > From: Matthieu Bouron <matthieu.bouron at stupeflix.com>
> >> > > >
> >> > > > Codec width/height restrictions seem hardcoded at the OMX level and
> >> > > > seem arbitrary. Bypassing those restrictions allows a device to decode
> >> > > > streams at higher resolutions.
> >> > > >
> >> > > > For example it allows a Nexus 5 to decode h264 streams with a resolution
> >> > > > higher than 1920x1080.
> >> > >
> >> > >
> >> > > What happens if the resolution actually exceeds the devices capabilities?
> >> >
> >> > The patch has been tested on various devices and it has been working so
> >> > far. When the resolution actually exceeds the device capabilities the
> >> > codec just fails to configure itself.
> >> >
> >> > However I did not try to craft samples with really high resolutions (higher
> >> > than ~4K) to test the patch against.
> >> >
> >> > I will double check what is happening with both SW output and surface
> >> > output.
> >>
> >> I tested on a bunch of devices with different chipsets and they all fail at
> >> the configuration step.
> >>
> >
> > If there is no objection, I will push the patchset in one day.
> >
> 
> If you have confirmed that it still fails gracefully but accepts more
> streams, then LGTM.

Thanks.

I'm working on an another patch to check what profile the codec supports
and fail at init time if the stream profile is too high (currently the
init passes but it fails afterwards while trying to decode frames, which
is annoying if an application wants to do some kind of fallback at init
time).

Matthieu

[...]


More information about the ffmpeg-devel mailing list