[gst-imx] How to use gstreamer on the quad wandboard?

This forum is for supported devices using an ARMv7 Freescale SoC.

[gst-imx] How to use gstreamer on the quad wandboard?

Postby hansan » Sat Sep 20, 2014 9:22 pm

Dear all,

I try to figure out how to use the hardware encoder/decoder for the VPU. There is a gst-imx package and I see the gstreamer imx plugins:
$this->bbcode_second_pass_code('', '
[hansan@wandboard gstreamer-imx]$ gst-inspect-1.0 | grep -i imx
imxv4l2src: imxv4l2src: V4L2 CSI Video Source
imxvpu: imxvpudec: Freescale VPU video decoder
imxvpu: imxvpuenc_h263: Freescale VPU h.263 video encoder
imxvpu: imxvpuenc_h264: Freescale VPU h.264 video encoder
imxvpu: imxvpuenc_mpeg4: Freescale VPU MPEG-4 video encoder
imxvpu: imxvpuenc_mjpeg: Freescale VPU motion JPEG video encoder
imxipu: imxipuvideotransform: Freescale IPU video transform element
imxipu: imxipusink: Freescale IPU video sink
imxeglvivsink: imxeglvivsink: Freescale EGL video sink
')

But if I try some demo pipeline I get an error:
$this->bbcode_second_pass_code('', '
[hansan@wandboard gstreamer-imx]$ gst-launch-1.0 -v fakesrc num-buffers=100 filltype=4 is_live=true ! imxvpuenc_h264 ! filesink location=testfake.avi
Setting pipeline to PAUSED ...
[INFO] Product Info: i.MX6Q/D/S
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstImxVpuH264Enc:imxvpuh264enc0: GStreamer error: negotiation problem.
Additional debug info:
gstvideoencoder.c(1474): gst_video_encoder_chain (): /GstPipeline:pipeline0/GstImxVpuH264Enc:imxvpuh264enc0:
encoder not initialized
Execution ended after 0:00:00.001916385
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...
')

I use the linux-wandboard kernel from: https://github.com/wandboard-org/linux.git branch wandboard_imx_3.10.17_1.0.0_g, but the archlinux arm linux-wandboard package gives me the same result.

The gst-imx package get's a lot of love; so I assume that it in principle should work, but or not with my gst-launch command or not on a quad wandboard.

Does someone know how to use gstreamer with the imx elements? And has someone this working on a wandboard? I am very eager to know how to use the VPU for hardware decoding and encoding of movies.

Greetings
hansan
 
Posts: 10
Joined: Sun Jul 27, 2014 6:21 pm

Re: [gst-imx] How to use gstreamer on the quad wandboard?

Postby hansan » Fri Oct 03, 2014 3:58 pm

I have found my problem; I did not use a proper pipeline.

The following pipeline is working properly:
$this->bbcode_second_pass_code('', '
gst-launch-1.0 -vvv videotestsrc num-buffers=2000 pattern=0 ! video/x-raw,format="I420",framerate=25/1,width=1920,height=1080 ! imxvpuenc_mpeg4 bitrate=200 ! filesink location=test.ts &
')

I also found a pipeline to transcode with the VPU.
$this->bbcode_second_pass_code('', '
gst-launch-1.0 -vvv filesrc location=./test.ts typefind=true ! mpeg4videoparse ! imxvpudec ! video/x-raw,format="I420" ! imxvpuenc_h264 bitrate=100 idr-interval=16 ! filesink location=testh264.ts
')

I have to look into this more.
hansan
 
Posts: 10
Joined: Sun Jul 27, 2014 6:21 pm


Return to Freescale

Who is online

Users browsing this forum: No registered users and 4 guests