我使用了gst的指令,用glimagesink只能显示一个无法移动的画面gst-launch-1.0 -v filesrc location=/run/media/mmcblk1p1/DCIM/VID_20210713_214842.avi ! decodebin name=dec dec. ! queue ! videoconvert ! glimagesink render-rectangle='<100, 0, 1360, 1080>' dec. ! queue ! audioconvert ! audioresample ! autoaudiosink起始位置并未生效,用GST_DEBUG=3 gst-launch-1.0 filesrc location=/run/media/mmcblk1p1/DCIM/VID_20210713_214842.avi ! avidemux ! decodebin ! videoconvert ! videoscale ! video/x-raw,width=1920,height=1080 ! kmssink bus-id="imx-drm" plane-id=33 render-rectangle="<0,0,1920,1080>"
Setting pipeline to PAUSED ...
0:00:00.151985875 2826 0xaaaaeac58660 WARN kmssink gstkmssink.c:1015:gst_kms_sink_start:<kmssink0> error: Could not open DRM module (NULL)
0:00:00.152025125 2826 0xaaaaeac58660 WARN kmssink gstkmssink.c:1015:gst_kms_sink_start:<kmssink0> error: reason: No such device (19)
0:00:00.152109750 2826 0xaaaaeac58660 WARN basesink gstbasesink.c:5367:gst_base_sink_change_state:<kmssink0> error: Failed to start
ERROR: Pipeline doesn't want to pause.
ERROR: from element /GstPipeline:pipeline0/GstKMSSink:kmssink0: Could not open DRM module (NULL)
Additional debug info:
../../../git/sys/kms/gstkmssink.c(1015): gst_kms_sink_start (): /GstPipeline:pipeline0/GstKMSSink:kmssink0:
reason: No such device (19)
Setting pipeline to NULL ...
Freeing pipeline ...
First of all, thank you for your reply,I used the following command to display:
gst-launch-1.0 -v filesrc location=/run/media/mmcblk1p1/DCIM/VID_20210713_214842.avi ! decodebin name=dec dec. ! queue ! videoconvert ! glimagesink render-rectangle='<100, 0, 1360, 1080>' dec. ! queue ! audioconvert ! audioresample ! autoaudiosink
This command can be used to play on the imx8 device I am using, however, the X-axis position offset of 100 set in the instruction does not take effect, and the video still starts playing from the position (0,0).
What follows is a command that I tried to test for playing simultaneously at (0,0) and (1920,0) on the screen, but it didn't work
gst-launch-1.0 \
videomixer name=mix sink_0::xpos=0 sink_0::ypos=0 sink_1::xpos=1920 sink_1::ypos=0 \
! videoconvert ! kmssink driver-name=drm device=/dev/dri/card0 \
filesrc location=/run/media/mmcblk1p1/DCIM/VID_20210713_214842.avi ! decodebin ! videoconvert ! mix.sink_0 \
filesrc location=/run/media/mmcblk1p1/DCIM/VID_20210713_214842.avi ! decodebin ! videoconvert ! mix.sink_1
In addition, I also tried glimagesink, but it also did not work.
One more thing, I want to know how can I set my QT progress as top window always, I try to set
Qt::WindowStaysOnTopHint
but while new window or show video with GST command, my QT progress window will be covered by other window, I can't get key in this case and I have to press my Qt window to raise it by mouse or fingure. I try to use QT's ”raise“ method and ”setFocus“ method and "repaint" method each 500ms, but QT programs cannot be displayed to the top layer by those ways. I would appreciate it if you could help me solve these two problems
hi @EnochXu
Could you share your two video file and tell more about your each test steps? I will try reproduce this on my site.
And What's BSP version do you use?
B.R
I do not have permission to upload video, tell me your email address plz