B4J Library B4JVlcj (embed VLC MediaPlayer in your program/app)

moster67

Expert
Licensed User
Longtime User
I haven't checked the library with most recent versions of VLC but the error is probably related to what I wrote in the first post of this thread :

[-You must match the CPU architecture of the Java Virtual Machine and the native LibVLC libraries. If you use a 32-bit JVM you must use a 32-bit release of VLC; if you use a 64-bit JVM you must use a 64-bit release of VLC. You can not mix CPU architectures, it will not work.]
 

alas

Member
it is interesting library , but is there away to use it without installing vlc? i found one subject but i dont know how to apply it on your library
embed vlc without installing vlc

thanks
 

moster67

Expert
Licensed User
Longtime User
is there away to use it without installing vlc

Nice idea although the post you cited is quite old (well prior to my wrapper) and it seems some things changed with later versions of VLC.
See here: https://stackoverflow.com/a/38957564/45402

In the very near future, I have no plans to update the wrapper, mostly because I am quite busy. However, I have planned an update so when doing it, I will take your idea into consideration if I can find useful information on how to do it.
 

josejad

Expert
Licensed User
Longtime User
Could you post a sample based on B4XPages? I can't find what to send to Videofrm.SetOwner(Main.MainForm) in your class.

Thanks
 

moster67

Expert
Licensed User
Longtime User
I cannot test now, not being at home
In any case, I am not very familiar with B4XPages - I hardly write my own apps these days.
I can try after this weekend after I come home from a short holiday break. If you resolve it in the meantime, please post your findings.
 

giga

Well-Known Member
Licensed User
Longtime User
Great library, I am testing it now. What I am looking for is to able to be play directly from the webcam. VLA can do it by clicking Media then "open capture device" and choose your webcam as the device. It will give you a real-time video capture. Is that method available in this library or how do you add it?

Thank you,
 

peacemaker

Expert
Licensed User
Longtime User
Hi, All

Is there possibility to grab the frames during playing ? Save to a JPG file.
 

moster67

Expert
Licensed User
Longtime User
I am not sure there is such a method, at least in the wrapper there isn't. You need to check the docs of the vlcj-apis (there is a link in the first post). If there is such a method, you may be able to access with Javaobject.

Otherwise you can probably get the frames easily using ffmpeg with jshell.
 

peacemaker

Expert
Licensed User
Longtime User
GridPane1 with "scenegrid" XML layout works good for the resizing.
But how to do the same, but not in the center, just in some container that is controlled by position and dimension (but with auto-resizing of video) ?
 

Star-Dust

Expert
Licensed User
Longtime User
t, you can probably use B4JVlcj to stream your WebCam to a server (although not tested but considering the power of VLC this should be possible).
VLC is just as flexibile as FFmpeg.
Very interesting. How to do using your library?
 

CR95

Active Member
Licensed User
@moster67 Great library.
I am testing it on Raspberry PI3B with B4J. Video is coming from hard disk connected via USB.
It runs well BUT I have an issue : video is "splitted" and appears in pieces in a jerky way without stopping. The same video appears fluently when launched by "open file/play" directly in VLC.

Do you know this issue and is there a workaround ?
Thanks in advance
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…