Ticket #3517: 0001-lavd-v4l2-revert-b1ad9312331759679a9c956233716a67ae6.patch

File 0001-lavd-v4l2-revert-b1ad9312331759679a9c956233716a67ae6.patch, 1.1 KB (added by holden, 12 years ago)
  • libavdevice/v4l2.c

    From 002c8a50c5efcf5c6ff511c22f0df5b00c472549 Mon Sep 17 00:00:00 2001
    From: Giorgio Vazzana <mywing81@gmail.com>
    Date: Thu, 6 Nov 2014 16:03:05 +0100
    Subject: [PATCH] lavd/v4l2: revert b1ad9312331759679a9c956233716a67ae681d89
    
    ---
     libavdevice/v4l2.c |    6 +++---
     1 file changed, 3 insertions(+), 3 deletions(-)
    
    diff --git a/libavdevice/v4l2.c b/libavdevice/v4l2.c
    index 783a03c..caddf8e 100644
    a b static int v4l2_read_header(AVFormatContext *ctx)  
    881881
    882882    avpriv_set_pts_info(st, 64, 1, 1000000); /* 64 bits pts in us */
    883883
    884     if ((res = v4l2_set_parameters(ctx)) < 0)
    885         goto fail;
    886 
    887884    if (s->pixel_format) {
    888885        AVCodec *codec = avcodec_find_decoder_by_name(s->pixel_format);
    889886
    … … static int v4l2_read_header(AVFormatContext *ctx)  
    934931
    935932    s->pixelformat = desired_format;
    936933
     934    if ((res = v4l2_set_parameters(ctx)) < 0)
     935        goto fail;
     936
    937937    st->codec->pix_fmt = ff_fmt_v4l2ff(desired_format, codec_id);
    938938    s->frame_size =
    939939        avpicture_get_size(st->codec->pix_fmt, s->width, s->height);