WB Quad: gstreamer in portrait mode?

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

WB Quad: gstreamer in portrait mode?

Postby enzeneer » Mon Nov 17, 2014 10:23 pm

Hi

I have an HDMI 1920x1080p display working perfectly in portrait mode with the Wandboard Quad Rev. C1.

I am using the fbdev driver with gpu-viv-bin-mx6q-fb and xf86-video-fbdev. This is what my /etc/X11/xorg.conf.d/20-vivante.conf looks like:
$this->bbcode_second_pass_code('', '
$ cat /etc/X11/xorg.conf.d/20-vivante.conf
Section "Device"
Identifier "i.MX Accelerated Framebuffer Device"
Driver "fbdev"
Option "UseFBDev" "true"
Option "fbdev" "/dev/fb0"
Option "HWcursor" "false"
Option "Rotate" "CW"
EndSection

#Section "Module"
# Load "vivante"
#EndSection

Section "Monitor"
Identifier "DISP3 BG"
EndSection

Section "Screen"
Identifier "Screen0"
Device "i.MX Accelerated Framebuffer Device"
Monitor "DISP3 BG"
DefaultDepth 24
SubSection "Display"
Depth 24
Modes "1920x1080"
EndSubSection
# Option "Rotate" "right"
EndSection

Section "ServerLayout"
Identifier "Default Layout"
Screen "Screen0"
EndSection

Section "ServerFlags"
Option "BlankTime" "0"
Option "StandbyTime" "0"
Option "SuspendTime" "0"
Option "OffTime" "0"
EndSection

Section "DRI"
Mode 0666
EndSection
')

I also noticed that I change the rotation by $this->bbcode_second_pass_code('', 'echo "2" > /sys/class/graphics/fb0/rotate'). Different orientations can be achieved by changing the value echoed into rotate.

As I mentioned, this is working great. If I launch Chromium and play a video in it, it plays with the correct "portrait" orientation, albeit it's choppy because of the software decoding.

On the other hand if I play the same video using $this->bbcode_second_pass_code('', 'gst-launch-1.0 playbin uri=file:///$PWD/video1.mp4'), the video plays really smooth with vpu-accelerated decoding. The only snag is that the video is in "landscape" mode.

Playbin seems to use the imxeglvivsink and it doesn't support rotate property.
$this->bbcode_second_pass_code('', '
# gst-inspect-1.0 imxeglvivsink | grep rotate
')

Apparently, the mfw_isink provided by Freescale supports the rotate property.

Any ideas how rotation can be achieved in gstreamer? Thanks
How
enzeneer
 
Posts: 19
Joined: Thu Nov 06, 2014 4:12 am

Re: WB Quad: gstreamer in portrait mode?

Postby enzeneer » Mon Nov 17, 2014 10:42 pm

Progress!

$this->bbcode_second_pass_code('', '
gst-launch-1.0 filesrc location=./video1.mp4 typefind=true ! decodebin name=demux demux. ! videoflip method=clockwise ! autovideosink demux. ! autoaudiosink
')

Actually flips the video! But performance is awful. Lots of buffers dropped and messages like "There may be a timestamping problem, or this computer is too slow".

Replacing the autovideo and autoaudio sinks bye imxeglvivsink and alsasink respectively does not change anything.

If only I could find the right gstreamer pipeline, I think this could be fixed ....
enzeneer
 
Posts: 19
Joined: Thu Nov 06, 2014 4:12 am

Re: WB Quad: gstreamer in portrait mode?

Postby enzeneer » Mon Nov 17, 2014 10:52 pm

Apparently videoflip uses software rendering and that's the reason why the performance is so bad ...
enzeneer
 
Posts: 19
Joined: Thu Nov 06, 2014 4:12 am


Return to Freescale

Who is online

Users browsing this forum: No registered users and 22 guests

cron