SIGSEGV problem when gstreamer pipeline starts to run with glimagesink

cancel
Showing results for 
Search instead for 
Did you mean: 

SIGSEGV problem when gstreamer pipeline starts to run with glimagesink

Jump to solution
756 Views
Contributor III

Hello Team, 

This is regarding the current project named Toyota CY20 based on i.MX6Dual.  This is based on L4.14.98-2.0.0_ga. 

Here we have configured the following gstreamer components in our builds:

1. gstreamer1.0-plugins-good
2. gstreamer1.0-plugins-base
3. gstreamer1.0-plugins-bad
4. imx-gst1.0-plugin
5. gstreamer1.0

We are using glimagesink for video playback and we are getting the following error when glimagesink is used for video playback

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! glimagesink
Setting pipeline to PAUSED ...
Caught SIGSEGV
exec gdb failed: No such file or directory
Spinning. Please run 'gdb gst-launch-1.0 489' to continue debugging, Ctrl-C to quit, or Ctrl-\ to dump core.

but i use fakesink instead of glimagesink it is not showing any error:

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! fakesink
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock

Could you please help us in identifying the issue, is we are missing anything in our build env.

Regards,

Ikshwaku

Labels (3)
0 Kudos
1 Solution
378 Views
Community Manager
This an automatic process.

We are marking this post as solved, due to the either low activity or any reply marked as correct.

If you have additional questions, please create a new post and reference to this closed post.

NXP Community!

View solution in original post

0 Kudos
8 Replies
379 Views
Community Manager
This an automatic process.

We are marking this post as solved, due to the either low activity or any reply marked as correct.

If you have additional questions, please create a new post and reference to this closed post.

NXP Community!

View solution in original post

0 Kudos
387 Views
NXP TechSupport
NXP TechSupport

Hi,

I did not notice you are using sabre auto and ivi-shell. So as I am not familiar with vehicular solutions, I will test it again.

In this meanwhile, could you please change the build from DISTRO=fsl-imx-wayland to DISTRO=fsl-imx-xwayland.

Regards

0 Kudos
387 Views
NXP TechSupport
NXP TechSupport

Hi,

It looks like the backend is wrong. Please, try to edit the vi /etc/xdg/weston.ini, by including the following at the end of the file:

[screen-share]

command=/usr/bin/weston --backend=rdp-backend.so --shell=fullscreen-shell.so --no-clients-resize

 

The GStreamer support is correct, it is related to framebuffer vs. DRM support.

 

Please, let me know if it helps.

Regards

0 Kudos
387 Views
Contributor III

Hello, 

Thanks for inputs. 

But in our builds we don't have rdp-backend.so. I have also build the NXP bsp yocto build with followoing configuration, but not able to locate rdp-backend.so

DISTRO=fsl-imx-wayland MACHINE=imx6dlsabreauto source fsl-setup-release.sh -b build-wayland

bitbake fsl-image-validation-imx

For our build environment, we are using weston with ivi-shell and fbdev-backend.so.

we not facing any problem with any graphics apps like simple-egl and EGLWLMockNavigation.

I have observe two different behaviors for glimagesink:

1.  without exporting "export XDG_RUNTIME_DIR=/var/run/root/1000" following commands works fine and I am able to see color bars on the display and it is using gldisplayvivfb0 :

 

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! glimagesink
[INFO] Product Info: i.MX6Q/D/S
Can't get caps from capture device, use the default setting.
Perhaps haven't capture device.
display(/dev/fb0) resolution is (1280x720).
Setting pipeline to PAUSED ...
error: XDG_RUNTIME_DIR not set in the environment.
Pipeline is PREROLLING ...
Got context from element 'sink': gst.gl.GLDisplay=context, gst.gl.GLDisplay=(GstGLDisplay)"\(GstGLDisplayVivFB\)\ gldisplayvivfb0";
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:12.241121335
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Total showed frames (369), playing for (0:00:12.242181001), fps (30.142).
Freeing pipeline ...
root@toyotacy20-t077:~#

2. With export XDG_RUNTIME_DIR=/var/run/root/1000 it fails:

root@toyotacy20-t077:~# export XDG_RUNTIME_DIR=/var/run/root/1000

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! glimagesink
[INFO] Product Info: i.MX6Q/D/S
Can't get caps from capture device, use the default setting.
Perhaps haven't capture device.
display(/dev/fb0) resolution is (1280x720).
Setting pipeline to PAUSED ...
Caught SIGSEGV
exec gdb failed: No such file or directory
Spinning. Please run 'gdb gst-launch-1.0 495' to continue debugging, Ctrl-C to quit, or Ctrl-\ to dump core.
^C
root@toyotacy20-t077:~#

Regards,

Ikshwaku

0 Kudos
387 Views
NXP TechSupport
NXP TechSupport

Hello Chauhuan,

It appears to be an issue related to DRM and framebuffer mismatch.

Please, try to use the following pipeline:

gst-launch-1.0 videotestsrc ! imxv4l2sink

 I will reproduce the test in this meanwhile to check what need to be done to enable the glimagesink usage.

Regards

0 Kudos
387 Views
Contributor III

Hello, 

With imxv4l2sink its giving folloing error:

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! imxv4l2sink
====== IMXV4L2SINK: 4.4.5 build on Feb 17 2020 13:09:18. ======
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
Setting pipeline to NULL ...
Freeing pipeline ...
root@toyotacy20-t077:~#

Regards,

Ikshwaku

0 Kudos
387 Views
NXP TechSupport
NXP TechSupport

Hi,

I just did a test here using the i.MX 6DL SDB and the L4.14.98-2.0.0ga and both, glimagesink and imxv4l2sink are working on our BSP.

 

Please, check the log below:

root@imx6qpdlsolox:~# gst-launch-1.0 videotestsrc ! glimagesink                                

Setting pipeline to PAUSED ...                                                                  

Pipeline is PREROLLING ...                                                                      

Got context from element 'sink': gst.gl.GLDisplay=context, gst.gl.GLDisplay=(GstGLDisplay)"\(GstGLDisplayWayland\)\ gldisplaywayland0";                                                        

Pipeline is PREROLLED ...                                                                      

Setting pipeline to PLAYING ...                                                                

New clock: GstSystemClock                                                                      

^Chandling interrupt.                                                                          

Interrupt: Stopping pipeline ...                                                                

Execution ended after 0:00:16.817578668                                                        

Setting pipeline to PAUSED ...                                                                  

Setting pipeline to READY ...                                                                  

Setting pipeline to NULL ...                                                                    

Total showed frames (507), playing for (0:00:16.818711668), fps (30.145).                      

Freeing pipeline ...

                                                                           

root@imx6qpdlsolox:~# gst-launch-1.0 videotestsrc ! imxv4l2sink                                

====== IMXV4L2SINK: 4.4.5 build on Mar 22 2019 12:57:38. ======                                

Setting pipeline to PAUSED ...                                                                  

display(/dev/fb0) resolution is (1024x768).                                                    

Pipeline is PREROLLING ...                                                                      

v4l2sink need allocate 3 buffers.                                                              

Pipeline is PREROLLED ...                                                                      

Setting pipeline to PLAYING ...                                                                

New clock: GstSystemClock                                                                      

^Chandling interrupt.                                                                          

Interrupt: Stopping pipeline ...                                                                

Execution ended after 0:00:10.012261668                                                        

Setting pipeline to PAUSED ...                                                                  

Setting pipeline to READY ...                                                                  

Setting pipeline to NULL ...                                                                    

Total showed frames (301), playing for (0:00:10.012758002), fps (30.062).                      

Freeing pipeline ...                                                                            

root@imx6qpdlsolox:~#

 

As you can see, the glimagesink uses the gldisplaywayland0, and the imxv4l2sink uses the /dev/fb0, so DRM and Framebuffer are working properly on our BSP.

 

It looks like the you are missing some video dependence.So please check it.

Regards

0 Kudos
387 Views
Contributor III

Hello, 

In my previous logs few logs were missing :

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! glimagesink
[INFO] Product Info: i.MX6Q/D/S
Can't get caps from capture device, use the default setting.
Perhaps haven't capture device.
display(/dev/fb0) resolution is (1280x720).
Setting pipeline to PAUSED ...
Caught SIGSEGV
exec gdb failed: No such file or directory
Spinning. Please run 'gdb gst-launch-1.0 487' to continue debugging, Ctrl-C to quit, or Ctrl-\ to dump core.
^C
root@toyotacy20-t077:~#

root@toyotacy20-t077:~# gst-launch-1.0 videotestsrc ! imxv4l2sink
[INFO] Product Info: i.MX6Q/D/S
Can't get caps from capture device, use the default setting.
Perhaps haven't capture device.
display(/dev/fb0) resolution is (1280x720).
====== IMXV4L2SINK: 4.4.5 build on Feb 20 2020 10:09:41. ======
Setting pipeline to PAUSED ...
ERROR: Pipeline doesn't want to pause.
Setting pipeline to NULL ...
Freeing pipeline ...
root@toyotacy20-t077:~#

In your case when you are using glimagesink then the glimagesink uses the gldisplaywayland0 but in our case its is using display(/dev/fb0) .


We are staring weston with following command in service file

/usr/bin/weston --tty=1 --device=/dev/fb0 --backend=fbdev-backend.so --use-g2d=0 --log=/tmp/weston.log

Could please provide your inputs for this?

For gstreamer support we are adding these two packages in our builds:

1. packagegroup-fsl-gstreamer1.0

2. packagegroup-fsl-gstreamer1.0-full

do we need to add any other package specific to gstreamer.

Regards,

Ikshwaku

0 Kudos