SAP for VLC on Android

VLC for Android and Chrome OS specific usage questions
Jonathan Websdale
New Cone
New Cone
Posts: 8
Joined: 15 Nov 2013 12:55

SAP for VLC on Android

Postby Jonathan Websdale » 15 Nov 2013 13:10

I'm interested in adding SAP streams to VLC for Android and am aware of the recent addition of the feature in the iOS development. Are there currently plans to add SAP support to the Android client (if so when) or is this work already under way ?

edwardw
Big Cone-huna
Big Cone-huna
Posts: 2346
Joined: 24 Jun 2012 23:36
VLC version: 3.0.0-git

Re: SAP for VLC on Android

Postby edwardw » 16 Nov 2013 03:55

Does not exist so far.

Jonathan Websdale
New Cone
New Cone
Posts: 8
Joined: 15 Nov 2013 12:55

Re: SAP for VLC on Android

Postby Jonathan Websdale » 18 Nov 2013 13:25

Okay, I understand that it's not currently implemented but need to make this feature available so was wanting to check on the status of any developments around the area of connection to network streams before embarking on attempting to make the necessary additions.

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: SAP for VLC on Android

Postby Jean-Baptiste Kempf » 19 Nov 2013 00:12

It should not be too hard to activate though... A bit time consuming though...
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.

Jonathan Websdale
New Cone
New Cone
Posts: 8
Joined: 15 Nov 2013 12:55

Re: SAP for VLC on Android

Postby Jonathan Websdale » 13 Jan 2014 16:32

Okay, I've started adding support for SAP but have come up against an issue when creating a new function in the libvlcjni.c file.

Code: Select all

void Java_org_videolan_libvlc_LibVLC_mediaDiscovererInit(JNIEnv *env, jobject thiz, jlong instance) { /* Release previous media discoverer, if any */ releaseMediaDiscoverer(env, thiz); /* Create a media discoverer environment */ libvlc_media_discoverer_t *mp = libvlc_media_discoverer_new_from_name((libvlc_instance_t*)(intptr_t)instance, "sap"); jobject myJavaLibVLC = (*env)->NewGlobalRef(env, thiz); /* Connect the event manager */ libvlc_event_manager_t *ev = libvlc_media_discoverer_event_manager(mp); static const libvlc_event_type_t mp_events[] = { libvlc_MediaDiscovererStarted, libvlc_MediaDiscovererEnded }; for(int i = 0; i < (sizeof(mp_events) / sizeof(*mp_events)); i++) libvlc_event_attach(ev, mp_events[i], vlc_media_discoverer_event_callback, myVm); /* Keep a pointer to this media discoverer */ setLong(env, thiz, "mInternalMediaDiscovererInstance", (jlong)(intptr_t)mp); }
When the call to

Code: Select all

libvlc_media_discoverer_new_from_name
is made, the following log messages appear:-
"core services discovery: looking for services_discovery module matching "sap": 0 candidates"
"core services discovery: no services_discovery modules"
"core services discovery: no suitable services discovery module"

Is there someting I should be doing with the libVLC library in use by the Android app in order to add the required services discovery ?
Thanks.

Jonathan Websdale
New Cone
New Cone
Posts: 8
Joined: 15 Nov 2013 12:55

Re: SAP for VLC on Android

Postby Jonathan Websdale » 13 Jan 2014 17:42

Okay, fixed it myself.
Needed to remove 'sap' from the blacklist in the find_modules.sh script. Just recompiled and now correctly opened ports on the appropriate multicast addresses. Next step to try and list the available SAP streams!

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: SAP for VLC on Android

Postby Jean-Baptiste Kempf » 17 Jan 2014 19:15

And share it with us :)
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 “VLC for Android and Chrome OS”

Who is online

Users browsing this forum: No registered users and 25 guests