[Bug 747270] New: avfvideosrc: BUFFER_QUEUE_SIZE too small
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Thu Apr 2 13:25:27 PDT 2015
https://bugzilla.gnome.org/show_bug.cgi?id=747270
Bug ID: 747270
Summary: avfvideosrc: BUFFER_QUEUE_SIZE too small
Classification: Platform
Product: GStreamer
Version: git master
OS: All
Status: NEW
Severity: normal
Priority: Normal
Component: gst-plugins-bad
Assignee: gstreamer-bugs at lists.freedesktop.org
Reporter: ilya.konstantinov at gmail.com
QA Contact: gstreamer-bugs at lists.freedesktop.org
GNOME version: ---
In avfvideosrc.m, we have:
#define BUFFER_QUEUE_SIZE 2
This buffer queue is used in a producer-consumer fashion between the AV capture
callbacks (on AVFoundation's thread) and the element (on the main thread).
With such a small queue, we were constantly:
a) losing performance due to the main thread going to sleep constantly
b) periodically dropping frames in this code:
if ([bufQueue count] == BUFFER_QUEUE_SIZE)
[bufQueue removeLastObject];
Increasing the queue size to e.g. 32 improves performance significantly. On
iPhone 5s, improvement of ~7% is seen in the following pipeline:
avfvideosrc device-index=0 ! video/x-raw,width=1280,height=720,framerate=30/1
! vtenc_h264 bitrate=400 ! fakesink
--
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list