ximagesrc at 144 fps

Daniel Johnson teknotus at gmail.com
Sun Apr 26 00:30:57 UTC 2020


On Fri, Apr 24, 2020, 12:15 AM Xiaojiba <erwan at caregame.com> wrote:

> Hello,
> I have been looking all around for one week now but no one seems to be
> needing a ximagesrc at more than 30 fps... I saw one at 60fps but it's all
> fine until 60 so, it was not related to my problem.
>
> I have a pipeline to capture my screen to a file :
>
> ``
> gst-launch-1.0 -e ximagesrc ! \
>         "video/x-raw, framerate=144/1" ! \
>         jpegenc quality=5 ! avimux ! \
>         filesink location=file.avi
> ``
>
> This compiles, but when I open the .avi with for example VLC,
> I have a framerate of 144, BUT it takes 60 frames of the first second, 60
> of
> the second one and 24 if the third one
>
> Easier with 120 fps : It takes 2s at 60 fps to have one full second on VLC
> I believe ximagesrc is capped at 60 frame per second, am I correct ? Or my
> pipeline is wrong ?
>
> Thanks for help,
>

Ximagesrc is broken in a few ways, and once I understand how to write
plugins better I want to rewrite it. One of the ways it's broken is by
default it has use-damage on by default, and does non sensible stuff with
that. What "damage" is used for on X is if say the only thing that changed
is say an icon changed from play to pause it only propagates those changed
pixels. Ximgsrc instead of sending through say a 400 pixel buffer for the
new icon it sends a copy of the whole desktop. This would be fine if it did
it at most once per screen update, but if multiple small changes happen in
a single screen draw you get the whole desktop each time. So in your case
it's probably getting 60 small changes in a single frame update and you get
60 frames of the same. Set use-damage=false and that might be enough.

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20200425/88c0bc8b/attachment-0001.htm>


More information about the gstreamer-devel mailing list