Skip to content

Commit

Permalink
feat(FEC-13065): direct redirection of udp url without opening bp ses…
Browse files Browse the repository at this point in the history
…sion

Co-authored-by: tomasgarba <[email protected]>
  • Loading branch information
giladna and tomasgarba authored Mar 23, 2023
1 parent 0462af5 commit e8aabdf
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import com.kaltura.playkit.PKLog;
import com.kaltura.playkit.PKMediaConfig;
import com.kaltura.playkit.PKMediaEntry;
import com.kaltura.playkit.PKMediaFormat;
import com.kaltura.playkit.PKMediaSource;
import com.kaltura.playkit.PKPlugin;
import com.kaltura.playkit.Player;
Expand Down Expand Up @@ -198,6 +199,13 @@ public void apply(PKMediaEntry mediaEntry, PKMediaEntryInterceptor.Listener list
}

PKMediaSource source = mediaEntry.getSources().get(0);
if (PKMediaFormat.udp.equals(source.getMediaFormat())) {
// Replace the URL
log.d("Apply New Entry URL for UDP: " + mediaEntry.getName() + " - " + mediaEntry.getId() + " url: " + source.getUrl());
source.setUrl(source.getUrl());
listener.onComplete();
return;
}
// Start the session and get the final stream URL
session = SmartLib.getInstance().createStreamingSession();
if (session == null) {
Expand Down

0 comments on commit e8aabdf

Please sign in to comment.