Pine64 accelerated H.264 encoding
#1
Hi guys,

I'm trying to stream H264 video off of a USB webcam to my computer from my PINE64. 
I'm on longsleep's ubuntu and video packages (https://launchpad.net/~longsleep/+archiv...our-makers).

I've tried using gstreamer1.0-vaapi plugins, as well as this https://github.com/ebutera/gst-plugin-cedar
but I've been having trouble getting the encoding element to work properly.



Code:
GST_DEBUG=4 gst-launch-1.0 videotestsrc ! vaapih264enc ! fakesink 

# gives

0:00:00.129807267 13532       0x630ca0 WARN            videoencoder gstvideoencoder.c:674:gst_video_encoder_setcaps:<vaapiencodeh264-0> rejected caps video/x-raw, width=(int)320, height=(int)240, framerate=(fraction)30/1, format=(string)I420, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)1/1

even though 320x240 30fps I420 is part of vaapih264enc's sink capabilities. 

Has anyone had any experience with getting hardware H264 video encoding working on the PINE64?
The software based ones are really really laggy.
  Reply
#2
(05-25-2016, 08:57 PM)hngjms Wrote: Hi guys,

I'm trying to stream H264 video off of a USB webcam to my computer from my PINE64. 
I'm on longsleep's ubuntu and video packages (https://launchpad.net/~longsleep/+archiv...our-makers).

I've tried using gstreamer1.0-vaapi plugins, as well as this https://github.com/ebutera/gst-plugin-cedar
but I've been having trouble getting the encoding element to work properly.



Code:
GST_DEBUG=4 gst-launch-1.0 videotestsrc ! vaapih264enc ! fakesink 

# gives

0:00:00.129807267 13532       0x630ca0 WARN            videoencoder gstvideoencoder.c:674:gst_video_encoder_setcaps:<vaapiencodeh264-0> rejected caps video/x-raw, width=(int)320, height=(int)240, framerate=(fraction)30/1, format=(string)I420, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)1/1

even though 320x240 30fps I420 is part of vaapih264enc's sink capabilities. 

Has anyone had any experience with getting hardware H264 video encoding working on the PINE64?
The software based ones are really really laggy.

i had been wondering the same thing...
  Reply
#3
If you want to use video ; please use Android.
marcushh777    Cool

please join us for a chat @  irc.pine64.xyz:6667   or ssl  irc.pine64.xyz:6697

( I regret that I am not able to respond to personal messages;  let's meet on irc! )
  Reply
#4
do you think that in the future there will be linux hw acceleration?
the orange pi is another board that is very similar in that it has mali gpu and they have hw acceleration 

thanks
  Reply
#5
(10-15-2016, 05:00 PM)hamzahbondok Wrote: do you think that in the future there will be linux hw acceleration?
the orange pi is another board that is very similar in that it has mali gpu and they have hw acceleration 

thanks

No, not for the PineA64 board; not in the near future.
marcushh777    Cool

please join us for a chat @  irc.pine64.xyz:6667   or ssl  irc.pine64.xyz:6697

( I regret that I am not able to respond to personal messages;  let's meet on irc! )
  Reply
#6
(10-15-2016, 05:05 PM)MarkHaysHarris777 Wrote:
(10-15-2016, 05:00 PM)hamzahbondok Wrote: do you think that in the future there will be linux hw acceleration?
the orange pi is another board that is very similar in that it has mali gpu and they have hw acceleration 

thanks

No, not for the PineA64 board; not in the near future.

But would it be theoretically possible to take some parts of a git repo and build your own image with the graphics-bits from an SBC with a similar SoC?
  Reply
#7
(10-16-2016, 12:42 PM)CaptainZalo Wrote:
(10-15-2016, 05:05 PM)MarkHaysHarris777 Wrote:
(10-15-2016, 05:00 PM)hamzahbondok Wrote: do you think that in the future there will be linux hw acceleration?
the orange pi is another board that is very similar in that it has mali gpu and they have hw acceleration 

thanks

No, not for the PineA64 board; not in the near future.

But would it be theoretically possible to take some parts of a git repo and build your own image with the graphics-bits from an SBC with a similar SoC?

No.

... Simon (longsleep) has estimated that it would take two 'paid' serious developers 1.5 person years to reverse engineer the proprietary code and subsequently build the open product that would serve the community effort. This is not going to be a trivial effort , nor is it going to be a successful trial and guess accomplishment either.
marcushh777    Cool

please join us for a chat @  irc.pine64.xyz:6667   or ssl  irc.pine64.xyz:6697

( I regret that I am not able to respond to personal messages;  let's meet on irc! )
  Reply
#8
(10-15-2016, 05:00 PM)hamzahbondok Wrote: do you think that in the future there will be linux hw acceleration?
the orange pi is another board that is very similar in that it has mali gpu and they have hw acceleration 

thanks

If you want access to the HW acceleration for encoding for using with a camera like the OP did ... then it already exists, and has been available for the last two-three months... 

https://github.com/avafinger/ffmpeg_cedrus264_A64

Credit: Thanks to tkasier for pointing that out over on Armbian, and here is the output log from @lex.
  Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Manjaro arm on pine64+ roel 2 173 10-19-2019, 05:13 AM
Last Post: roel
  Volumio for PINE64 Released mikelangeloz 11 6,510 03-22-2019, 09:25 AM
Last Post: llungster
  I2S Audio patches for Pine64+ uploaded to GitHub ramstadt 1 257 01-19-2019, 11:31 AM
Last Post: ramstadt
  Pine64: Minimal SDL config Max11 3 512 01-04-2019, 03:47 PM
Last Post: Max11
  Fedora 27 on Pine64 gregjo 18 7,153 01-02-2019, 10:42 PM
Last Post: heatfanjohn
  Accelerated H.264 and HEVC video decoding with Cedrus longsleep 72 31,830 11-29-2018, 03:41 AM
Last Post: tllim
  Official build procedure of ayufan pine64 r.tanaka 0 577 08-21-2018, 10:54 PM
Last Post: r.tanaka
  DKMS on kernel 3.10.107-pine64 obrienmd 5 706 06-21-2018, 05:45 PM
Last Post: evilbunny
  Programming languages support under PINE64 baryluk 5 3,115 03-09-2018, 01:52 AM
Last Post: kaokaobang
  Gentoo for pine64 - longsleep kernel incoherent 0 825 12-09-2017, 08:14 AM
Last Post: incoherent

Forum Jump:


Users browsing this thread: 1 Guest(s)