Omxh264enc not registered

Here’s a puzzler. gst-inspect-1.0 lists the omxh264enc video encoder just fine, but when I try to launch a pipeline, I get the following errors for the omxh264enc video encoder:

OMX-Component not found with current ST static component loader.
...
ERROR: from element /GstPipeline:pipeline0/GstOMXH264Enc-omxh264enc:omxh264enc-omxh264enc0: Could not initialize supporting library.
...
../gst-plugins-base-1.16.3/gst-libs/gst/video/gstvideoencoder.c(1636): gst_video_encoder_change_state (): /GstPipeline:pipeline0/GstOMXH264Enc-omxh264enc:omxh264enc-omxh264enc0:
Failed to open encoder

Here’s my gstomx.conf:

...
[omxh264enc]
type-name=GstOMXH264Enc
core-name=/usr/lib/libomxil-bellagio.so.0
component-name=OMX.mesa.video_encoder.avc
rank=0
in-port-index=0
out-port-index=1

When I attempt to do omxregister-bellagio -v, here’s what I get:

 Scanning directory /usr/lib/bellagio/

 Scanning library /usr/lib/bellagio/libomxclocksrc.so
Component OMX.st.clocksrc registered with 0 quality levels
  Specific role OMX.st.clocksrc registered

 Scanning library /usr/lib/bellagio/libomxaudio_effects.so
Component OMX.st.volume.component registered with 2 quality levels
  Specific role OMX.st.volume.component registered
Component OMX.st.audio.mixer registered with 1 quality levels
  Specific role OMX.st.audio.mixer registered

 Scanning library /usr/lib/bellagio/libomxvideosched.so
Component OMX.st.video.scheduler registered with 2 quality levels
  Specific role OMX.st.video.scheduler registered

 4 OpenMAX IL ST static components in 3 libraries succesfully scanned

It doesn’t even recognize the libomxil-bellagio.so.0 library because it’s scanning a different directory. So, when I pass it the component path to scan ( /usr/lib ), I get this:

 Scanning directory /usr/lib/

 Scanning library /usr/lib/libelf-0.178.so

 0 OpenMAX IL ST static components in 0 libraries succesfully scanned

So the issue appears to be that the omxh264component isn’t registering with omxregister-bellagio?

Here’s the pipeline I was attempting:

gst-launch-1.0 -v videotestsrc num-buffers=100 ! video/x-raw,width=1920,height=1080,framerate=30/1 ! videoconvert ! omxh264enc ! autovideosink

When I do grep "omxh264enc" /usr/lib/libomxil-bellagio.so.0, I get nothing. When I do grep "omxh264enc" /usr/lib/gstreamer-1.0/libgstomx.so I get

omxh264enc
../gst-omx-1.16.3/omx/gstomxh264enc.c

When I update gstomx.conf to point to libgstomx.so, I still get the Could not initialize supporting library error for the encoder.

Any thoughts?

Hi @grh,

Sorry just to be clear, before we do anything, what version of our OS are you running here in this setup?

Best Regards,
Jeremias

Hi @jeremias.tx , I am on BSP Layer 5.2.

v/r

grh

Is it mainline or downstream?

@alex.tx

We’re using mainline.

Is it mainline or downstream?

There is only mainline in BSP 5.x.

But mainline does NOT support any kind of hardware-accelerated multimedia, sorry.

Ah, I had hoped differently, but thanks for the heads up.

Per @marcel.tx , BSP 5.X mainline doesn’t support hard-accelerated encoding with omxh264enc.