[FFmpeg-trac] #8450(avdevice:reopened): x11grab doesn't work with headless X servers

FFmpeg trac at avcodec.org
Mon Dec 30 18:44:53 EET 2019


#8450: x11grab doesn't work with headless X servers
------------------------------------+------------------------------------
             Reporter:  eero-t      |                    Owner:
                 Type:  defect      |                   Status:  reopened
             Priority:  normal      |                Component:  avdevice
              Version:  git-master  |               Resolution:
             Keywords:              |               Blocked By:
             Blocking:              |  Reproduced by developer:  0
Analyzed by developer:  0           |
------------------------------------+------------------------------------
Changes (by eero-t):

 * status:  closed => reopened
 * resolution:  needs_more_info =>
 * version:  unspecified => git-master
 * component:  undetermined => avdevice


Comment:

 cehoyos, when you close bug as needing more info, indicate what
 information is missing, and don't remove already given information.

 In case the problem was testing a release, I tried now also git build of
 FFmpeg:
 {{{
 ffmpeg -hwaccel vaapi -vaapi_device /dev/dri/renderD128 -an -f x11grab
 -video_size 1920x1080 -framerate 2 -i :99 -c:v h264_vaapi -vf
 format=nv12,hwupload -b:v 5000k -f flv rtmp://192.168.0.8/live/desktop_1
 ffmpeg version N-95996-ge3dddf2142 Copyright (c) 2000-2019 the FFmpeg
 developers
   built with gcc 7 (Ubuntu 7.4.0-1ubuntu1~18.04.1)
   configuration: --prefix=/opt/ --enable-libmfx --enable-vaapi --enable-
 sdl2 --disable-libx265 --disable-libx264 --disable-libvpx --enable-
 libvorbis --enable-libopus --disable-libmp3lame --disable-libass
 --disable-sndio --enable-libfreetype --enable-gpl --disable-doc
   libavutil      56. 36.101 / 56. 36.101
   libavcodec     58. 64.101 / 58. 64.101
   libavformat    58. 35.101 / 58. 35.101
   libavdevice    58.  9.101 / 58.  9.101
   libavfilter     7. 68.100 /  7. 68.100
   libswscale      5.  6.100 /  5.  6.100
   libswresample   3.  6.100 /  3.  6.100
   libpostproc    55.  6.100 / 55.  6.100
 [x11grab @ 0x55bf40067a40] Cannot get the image data event_error:
 response_type:0 error_code:128 sequence:9 resource_id:4194304 minor_code:4
 major_code:130.
 [x11grab @ 0x55bf40067a40] Stream #0: not enough frames to estimate rate;
 consider increasing probesize
 Input #0, x11grab, from ':99':
   Duration: N/A, bitrate: N/A
     Stream #0:0: Video: rawvideo (BGR[0] / 0x524742), bgr0, 1920x1080, 2
 fps, 1000k tbr, 1000k tbn, 1000k tbc
 Stream mapping:
   Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (h264_vaapi))
 Press [q] to stop, [?] for help
 Output #0, flv, to 'rtmp://192.168.0.8/live/desktop_1':
   Metadata:
     encoder         : Lavf58.35.101
     Stream #0:0: Video: h264 (h264_vaapi) (High) ([7][0][0][0] / 0x0007),
 vaapi_vld, 1920x1080, q=-1--1, 5000 kb/s, 2 fps, 1k tbn, 2 tbc
     Metadata:
       encoder         : Lavc58.64.101 h264_vaapi
 frame=    2 fps=0.0 q=-0.0 size=       1kB time=-00:00:00.49 bitrate=N/A
 dup=0 drop=734 speed=N/A
 }}}

 And as can be seen from above, that has exactly the same problem, all
 frames are "dropped" (because FFmpeg x11grab fails to acquire them).

--
Ticket URL: <https://trac.ffmpeg.org/ticket/8450#comment:2>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list