processing / processing-video

GStreamer-based video library for Processing
274 stars 130 forks source link

gstreamer library error on Linux #136

Open mxa opened 4 years ago

mxa commented 4 years ago

Trying to run any of the examples with Processing 3.5.3 and video Library 1.0.1 on Ubuntu 19.10 results in the following output:

UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
A library relies on native code that's not available.
Or only works properly when the sketch is run as a 32-bit application.
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type

I do have all relevant packages for gstreamer installed.

All I could find online was this forum post from 2016

codeanticode commented 4 years ago

Version 1.0 of the video library uses gstreamer 0.10.x, which is deprecated an may be missing in your Linux distribution. We are in the process of releasing v2.0 of the library, which has been updated to use gstreamer 1.x. We haven't released the new version on the Contributions Manager, but you can install the latest beta manually. It should work.

mxa commented 4 years ago

I extracted the video library beta and manually moved it into ~/sketchbook/libraries/. It is not showing up in File > Examples... > Libraries, there is no Video folder there. However I can open the examples from ~sketchbook/libraries/video/examples/. Loop.pde works as expected. Frames.pde only shows a black screen, arrow keys have no effect. Console outputs Processing video library using GStreamer 1.16.1 Help > Libraries Reference > Video results in this window (as any other link there)

Screenshot_20191108_185227

mark-orion commented 4 years ago

I extracted the video library beta and manually moved it into ~/sketchbook/libraries/. It is not showing up in File > Examples... > Libraries, there is no Video folder there. However I can open the examples from ~sketchbook/libraries/video/examples/. Loop.pde works as expected. Frames.pde only shows a black screen, arrow keys have no effect. Console outputs Processing video library using GStreamer 1.16.1 Help > Libraries Reference > Video results in this window (as any other link there)

Did you uninstall the broken video library before installing the beta ? You will find the library import under Sketch/Import Library/Contributed and you find it's examples under "Contributed Libraries".

mxa commented 4 years ago

Did you uninstall the broken video library before installing the beta ? You will find the library import under Sketch/Import Library/Contributed and you find it's examples under "Contributed Libraries".

Searching for "contributed" on the whole disk only has one hit: ~/sketchbook/modes/PythonMode/examples/Contributed Libraries in Python/

hamoid commented 4 years ago

@mxa What @mark-orion meant was: go to the Processing IDE Sketch menu, and there you would find Import Library. There's no contributed folder on the disk.

yuzh496 commented 4 years ago

I extracted the video library beta and manually moved it into ~/sketchbook/libraries/ , i can found the video library under Menu Sketch/Import Library/, but when i run the test project, there was some error: Processing video library using GStreamer 1.10.4 NullPointerException NullPointerException NullPointerException NullPointerException

matteo-mazzanti-ps commented 4 years ago

Trying to run any of the examples with Processing 3.5.3 and video Library 1.0.1 on Ubuntu 19.10 results in the following output:

UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
A library relies on native code that's not available.
Or only works properly when the sketch is run as a 32-bit application.
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type
UnsatisfiedLinkError: Error looking up function 'gst_date_get_type': /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so: undefined symbol: gst_date_get_type

I do have all relevant packages for gstreamer installed.

All I could find online was this forum post from 2016

Download the library form: https://github.com/gohai/processing-video/releases Unzip and copy the new "video" folder into the sketchbook library folder (~/sketchbook/libraries) :)

mxa commented 4 years ago

Download the library form: https://github.com/gohai/processing-video/releases Unzip and copy the new "video" folder into the sketchbook library folder (~/sketchbook/libraries)

I confirm that this works. Should I close the issue or leave it open until it is published and included in the processing download?

mxa commented 4 years ago

Help > Libraries Reference > Video results in this window (as any other link there)

Screenshot_20191108_185227

That seems to be another but unrelated issue on Linux. https://github.com/processing/processing/issues/6002

hspencer commented 4 years ago

Hello, I'm currently running Ubuntu 19.10 and just downloaded the Video Library Release 6 (version 2.0-beta4). I had to manually install GSteamer and I followed the steps from here.

Still, I get this error message:

Processing video library using GStreamer 1.16.1
NullPointerException
NullPointerException
NullPointerException
NullPointerException

(I also moved the processing folder to /, since in other forums that solution worked for others but it seems to be totally unrelated) Any light would be appreciated.

christo commented 4 years ago

Hey Processing, without meaning to be pushy, @codeanticode - I'm wondering if you have an estimate on when the upgraded v2.0 video library will be published? When you said "We are in the process of releasing v2.0 of the library" I assumed a timeframe of days or maybe weeks at most before the release occurred. Now more than six months have passed I see that either something has changed or my assumption was incorrect. Any guess would be helpful to me and I won't take it as a firm commitment. Thanks in advance. Also: is there something I can do to help make this happen?

macramole commented 3 years ago

I wasn't able to load a video on Ubuntu 20.04 based linux. Webcam worked but not loading a video file. No error message or anything, just black output. Upgrading to v2.0 fixed the issue. thanks.

christo commented 2 years ago

As v2.0 has been released, is this issue fixed as predicted?

codeanticode commented 1 year ago

The recent releases of the video library (2.2.x) should fair better on Linux, @macramole @christo have you tried it?

macramole commented 1 year ago

Nope, not yet. Thanks for pointing that out. I'm on holidays right now but will check it when I get back

El dom., 15 ene. 2023 23:34, codeanticode @.***> escribió:

The recent releases of the video library (2.2.x) should fair better on Linux, @macramole https://github.com/macramole @christo https://github.com/christo have you tried it?

— Reply to this email directly, view it on GitHub https://github.com/processing/processing-video/issues/136#issuecomment-1383382934, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAWH6OPIXB4GRTTIFJ3OTX3WSSXTLANCNFSM4JFTZF5Q . You are receiving this because you were mentioned.Message ID: @.***>

macramole commented 1 year ago

Hi sorry for the long delay.

I can confirm 2.2.x is working, I ran the Loop example with no problems.

Here is the output of the console if that's useful (added /// )

can't load library openh264 (openh264|libopenh264|libopenh264-0) with -Djna.library.path=/***/***/sketchbook/libraries/video/library/linux-amd64. Last error:java.lang.UnsatisfiedLinkError: Unable to load library 'openh264':
/***/***/sketchbook/libraries/video/library/linux-amd64/libopenh264.so: file too short
/***/***/sketchbook/libraries/video/library/linux-amd64/libopenh264.so: file too short
/***/***/sketchbook/libraries/video/library/linux-amd64/libopenh264.so.6: file too short
Native library (linux-x86-64/libopenh264.so) not found in resource path (/tmp/Loop3343431392836641640temp:/***/***/Apps/processing-4.0b8/core/library/core.jar:/***/***/Apps/processing-4.0b8/core/library/jogl-all.jar:/***/***/Apps/processing-4.0b8/core/library/gluegen-rt.jar:/***/***/sketchbook/libraries/video/library/jna.jar:/***/***/sketchbook/libraries/video/library/gst1-java-core-1.4.0.jar:/***/***/sketchbook/libraries/video/library/video.jar)
Processing video library using bundled GStreamer 1.20.3 (CVS)
Scanning GStreamer plugins...0:00:00.254898070 2324067 0x7fc2f0b70a10 ERROR            openh264dec gstopenh264dec.cpp:461:openh264dec_element_init: Incorrect library version loaded, expecting OpenH264 version:2.1.1.2005
0:00:00.254931299 2324067 0x7fc2f0b70a10 ERROR            openh264enc gstopenh264enc.cpp:1067:openh264enc_element_init: Incorrect library version loaded, expecting OpenH264 version:2.1.1.2005

(Processing core video:2324067): GStreamer-WARNING **: 15:39:57.455: Failed to load plugin '/***/***/sketchbook/libraries/video/library/linux-amd64/gstreamer-1.0/libgstopenjpeg.so': libopenjp2.so.2: cannot open shared object file: No such file or directory
 Done.