All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Frédéric Sureau" <frederic.sureau@vodalys.com>
To: Philipp Zabel <p.zabel@pengutronix.de>
Cc: Jean-Michel Hautbois <jean-michel.hautbois@vodalys.com>,
	Fabio Estevam <festevam@gmail.com>,
	linux-media <linux-media@vger.kernel.org>,
	Nicolas Dufresne <nicolas.dufresne@collabora.com>
Subject: coda: Unable to use encoder video_bitrate
Date: Thu, 18 Dec 2014 17:44:24 +0100	[thread overview]
Message-ID: <54930468.6010007@vodalys.com> (raw)

Hi

I am trying to use the coda encoder through Gstreamer on an iMX6-based 
board.

I use the (rebased and slightly modified) gstv4l2h264enc plugin from:
https://github.com/hizukiayaka/gst-plugins-good

This pipeline works fine:
gst-launch-1.0 -vvv v4l2src device=/dev/video4 ! 
"video/x-raw,width=1280,height=720" ! videoconvert ! v4l2video0h264enc ! 
h264parse ! mp4mux ! filesink location=test.mp4

When encoder has no bitrate param set (default=0), video encoding works 
well, but bitrate reaches ~2.5Mbps

When I try to set the bitrate with whatever value like 100,000 or 
1,000,000, the encoder produces video with bitrate around 480kbps and a 
very poor quality.

Here is the gstreamer pipeline I use with bitrate set:
gst-launch-1.0 -vvv v4l2src device=/dev/video4 ! 
"video/x-raw,width=1280,height=720" ! videoconvert ! v4l2video0h264enc 
extra-controls="controls,video_bitrate=1000000;" ! h264parse ! mp4mux ! 
filesink location=test.mp4

The video_bitrate control seems to be correctly passed to the driver by 
GStreamer since I can see the VIDIOC_S_CTRL call.

Any idea ?

Thanks
Fred

             reply	other threads:[~2014-12-18 16:44 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-18 16:44 Frédéric Sureau [this message]
2014-12-18 16:52 ` coda: Unable to use encoder video_bitrate Philipp Zabel
2014-12-18 16:55   ` Jean-Michel Hautbois
2014-12-18 17:09     ` Philipp Zabel
2014-12-18 17:10       ` Jean-Michel Hautbois
2014-12-19 10:28         ` Philipp Zabel
2014-12-19 10:33           ` Jean-Michel Hautbois
2014-12-22 15:24   ` Frédéric Sureau
2014-12-22 15:28     ` Nicolas Dufresne
2014-12-22 16:02     ` Philipp Zabel
2014-12-22 16:06       ` Nicolas Dufresne

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=54930468.6010007@vodalys.com \
    --to=frederic.sureau@vodalys.com \
    --cc=festevam@gmail.com \
    --cc=jean-michel.hautbois@vodalys.com \
    --cc=linux-media@vger.kernel.org \
    --cc=nicolas.dufresne@collabora.com \
    --cc=p.zabel@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.