Does shaka Packager support TS output? - http-live-streaming

I am trying to use shaka packager to encrypt videos, we want to use hls, I know shaka packager supports MP4 format ouput, but I am not sure whether shaka packager support TS format output or not. If supported , how to specify parameters while writing shaka packager commands?

Yes, it does support TS streams as part of HLS packaging.
They provide some examples under the HLS section of the documentation (https://google.github.io/shaka-packager/html/tutorials/hls.html):

In most of cases it is possible to play HLS in browser on Android devices, but you can face problems with performance or battery usage because of manifest parsing in JS. I will recommend you to use DASH for Android devices if it possible.

Related

Play hls m3u8 format in nextjs

How can I use hls m3u8 format in nextjs
I tried with video.js CDN but I couldn't achieve it. Hls.js and react player are not compatible with the last version.
Please check the example at this link: https://stackblitz.com/edit/github-hgv7za-ezygog.
Currently, it is working for me with the sample m3u8 file located at https://bitdash-a.akamaihd.net/content/sintel/hls/playlist.m3u8.
If you encounter a specific error, please provide more details, such as the console log, etc.

Embed and play sound (via audio element) in electron app

The actual task is to play mp3 file that should be embedded with the electron app.
I placed the mp3 file near my electron app "main.js".
I wanted to play it using some "sound-play" (https://github.com/nomadhoc/sound-play) package using bridge api, but it didn't worked out, sound is not playing.
So I want to just play it using an audio element (which seems to be more universal), but I don't get what src url I should supply to it. And then I wonder how to correctly add an additional asset to the built version (I'm using electron-builder).
Working with extra/local resources in election apps is kind of obscure topic for me. Advice would be appreciated.

nginx rtmp to hls streaming

My scenario is to pull data from a RTSP source via ffmpeg, send it to nginx-rtmp, and use nginx to provide hls playback. There are quite a lot of tutorials and q&a's on the internet. I followed this one:
https://docs.peer5.com/guides/setting-up-hls-live-streaming-server-using-nginx/
However, it miserably failed. To make things simpler to understand, I would like to ask the core question:
Who is responsible to create the m3u8 playlist file?
I tried to experiment in two steps: first, try to push a local mp4 file and play it back via HLS:
Following the above tutorial, I try to use ffmpeg to push a local mp4 file to nginx-rtmp, and use videojs to play it. The browser reported error:
VIDEOJS: ERROR: (CODE:4 MEDIA_ERR_SRC_NOT_SUPPORTED) No compatible source was found for this media.
Secondly, I have successfully saved the video file pushed to nginx-rtmp as a series of FLV file, and I know that I can use exec_push to call ffmpeg to convert flv to a format that is compatible with HLS. Again, here the core question is, howto create and UPDATE the m3u8 file as new video data is coming in endlessly.
For now, I would like experts to help me tackle the first question -- playback static mp4 file through HLS. Any tutorials on m3u8 playlist and mpeg-ts files are also much appreciated!
The nginx-rtmp module by itself creates and updates the playlist as new segments arrive.
To troubleshoot check if the .m3u8 files are created under the folder specified in hls_path of your nginx conf. Rest is just nginx serving a file using http.
If that works try the HLS url directly in safari (safari got inbuilt HLS player) or in Chrome (Play HLS M3u8) extension enabled.
If that works the problem must be with your player.html

Is there a good React Native module for playing/streaming audios?

I'm new to react native and building an audio streaming app. I found quite a few react native wrappers for native modules for playing audio files https://js.coach/react-native/react-native-ios-audio?search=audio
But none of them seem sufficient. I'm looking for a module that would
allow playing in the background and handle interruptions
have play-speed control
allow both streaming and local file playing
Does such a module exist? Any tips would be much appreciated. Thanks!
If your intention is to use the features you mentioned in a cross-platform (android/ios) app, then you do have some options, but there isn't a single module that will cover each of those bases.
Right now, I'm using a few different modules to accomplish similar functionality to what you're looking for:
react-native-audio-streaming to stream audio from a remote URL.
react-native-sound to play local audio files.
react-native-audio-streamer to stream audio from a remote URL on Android, since it uses ExoPlayer, instead of the AACDecoder used by react-native-audio-streaming.
Support for loading sound over the network was recently added to react-native-sound for iOS, and someone has mentioned the possibility of implementing it on Android as well. If this happens, then it may be the best choice for your use case.
I've included the current react-native-sound feature set below. Hope this helps!
Try Following Modules.
react-native-audio-streaming
react-native-audio-streamer

Playing audio in a Mac App Store compatible NWJS app

In the Additional Steps section at the foot of MAS: Packaging your app, I read:
To ensure proper validation [of your NWJS app for the Mac App Store], you have to check those steps:
Delete the FFMPEG library:
rm "YourApp.app/Contents/Frameworks/nwjs
Framework.framework/Libraries/ffmpegsumo.so"
Note: Currently, FFMPEG library cannot be submitted to Mac App Store as is.
When I delete the FFMPEG library, if my app includes (ogg) audio files and attempts to play them, the app crashes. I assume that this is because the FFMPEG library is essential for audio playback.
Does this mean that the current Mac-App-Store-friendly NWJS build (nwjs-macappstore-v0.12.3-osx-x64) does not support audio? Or is the an alternative audio library that I can use with it?

Resources