libvlc raspberry pi2 and omxil codec

This forum is about all development around libVLC.
plaublin
New Cone
New Cone
Posts: 2
Joined: 01 Sep 2015 10:37

libvlc raspberry pi2 and omxil codec

Postby plaublin » 01 Sep 2015 11:26

Hello

I am developing a video player on the Raspberry Pi2 using libVLC. How do I tell libVLC to use the Raspberry Pi2 hardware acceleration (codec omxil)?

I have compiled vlc from the revision of the tag 2.1.0-git. I can use vlc with hardware acceleration:

Code: Select all

$ vlc --verbose=3 --vout omxil_vout --codec omxil video.mp4
When I start my program, I initialise libVLC as follows:

Code: Select all

char const *vlc_argv[] = { "--vout", "omxil_vout", "--codec", "omxil", "--verbose=3", }; int vlc_argc = sizeof(vlc_argv) / sizeof(*vlc_argv); libvlc_instance_t* instance = libvlc_new(vlc_argc, vlc_argv); libvlc_media_t* media = libvlc_media_new_path(instance, "video.mp4"); libvlc_media_player_t* mediaPlayer = libvlc_media_player_new_from_media(media); libvlc_media_release(media); libvlc_media_player_play(mediaPlayer);
However, the omxil codec does not seem to be called: playing the video is as slow as when vlc_argv[] is empty and there is no reference to omxil in the verbose output while there is when I play the video from vlc.
How can I use the omxil codec from libVLC?

Thank you.

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: libvlc raspberry pi2 and omxil codec

Postby Jean-Baptiste Kempf » 08 Oct 2015 16:14

Use VLC 3.0.0 and the MMAL module.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.

plaublin
New Cone
New Cone
Posts: 2
Joined: 01 Sep 2015 10:37

Re: libvlc raspberry pi2 and omxil codec

Postby plaublin » 27 Nov 2015 10:55

Hi

Sorry for my late reply.

I tried to compile vlc 3.0.0 on the raspberry pi2, but I get an error, with gcc-4.8 (previous versions of gcc, 4.7 or 4.8, also fail to compile it):
/usr/include/c++/4.8/bits/move.h: In function ‘constexpr _Tp&& std::forward(typename std::remove_reference<_From>::type&&)’:
../include/vlc_fixups.h:265:54: error: types may not be defined in ‘sizeof’ expressions
# define _Static_assert(x, s) ((void) sizeof (struct { unsigned:-!(x); }))

My raspberry runs a raspbian wheezy.

Is there a special version of gcc or special git of vlc needed?

Jean-Baptiste Kempf
Site Administrator
Site Administrator
Posts: 37523
Joined: 22 Jul 2005 15:29
VLC version: 4.0.0-git
Operating System: Linux, Windows, Mac
Location: Cone, France
Contact:

Re: libvlc raspberry pi2 and omxil codec

Postby Jean-Baptiste Kempf » 28 Jun 2016 09:25

VLC compiles with gcc 4.8 on Android, so it works with this gcc.
Jean-Baptiste Kempf
http://www.jbkempf.com/ - http://www.jbkempf.com/blog/category/Videolan
VLC media player developer, VideoLAN President and Sites administrator
If you want an answer to your question, just be specific and precise. Don't use Private Messages.


Return to “Development around libVLC”

Who is online

Users browsing this forum: m1adow and 26 guests