shaka-player | JavaScript player library / DASH & HLS client | Video Utils library

 by   google JavaScript Version: v3.1.6 License: Apache-2.0

kandi X-RAY | shaka-player Summary

kandi X-RAY | shaka-player Summary

shaka-player is a JavaScript library typically used in Telecommunications, Media, Media, Entertainment, Video, Video Utils applications. shaka-player has no bugs, it has no vulnerabilities, it has a Permissive License and it has medium support. You can install using 'npm i shaka-player-hv' or download it from GitHub, npm.

We have another project called Shaka Player Embedded which offers the same features and similar APIs for native apps on iOS. This project uses its own media stack, which allows it to play content that would otherwise not be supported. This supports both DASH and HLS manifests.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              shaka-player has a medium active ecosystem.
              It has 5536 star(s) with 1112 fork(s). There are 233 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 395 open issues and 2842 have been closed. On average issues are closed in 43 days. There are 35 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of shaka-player is v3.1.6

            kandi-Quality Quality

              shaka-player has 0 bugs and 0 code smells.

            kandi-Security Security

              shaka-player has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              shaka-player code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              shaka-player is licensed under the Apache-2.0 License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              shaka-player releases are available to install and integrate.
              Deployable package is available in npm.
              It has 3937 lines of code, 144 functions and 458 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of shaka-player
            Get all kandi verified functions for this library.

            shaka-player Key Features

            No Key Features are available at this moment for shaka-player.

            shaka-player Examples and Code Snippets

            No Code Snippets are available at this moment for shaka-player.

            Community Discussions

            QUESTION

            Even if my Azure widevine license has expired, I can still play content
            Asked 2022-Jan-09 at 22:31

            Azure Media Service is used to deliver widevine license, I used shaka-packager with key-id and key-value get from license to package and encrypt video, and output two types of files, MPD, and MP4 encrypted video.

            When I test the encrypted content with the Dash test player, everything works fine and without a license, I can not play video.

            Then when I override policies and set license_duration_seconds = 1800

            The player stops after 30 minutes and displays "DRM: KeyStatusChange error! -- License has expired"

            However, when I click on Load again or refresh the page and use the same license and MPD URL, the same content plays again!

            I'm not sure if I missed something when I package the video with shaka-player.

            Is this the expected behavior?

            ...

            ANSWER

            Answered 2022-Jan-09 at 22:31

            When you "click on Load again or refresh the page", are you sure the player did not get a new Widevine license (hence another 30 min of playback window)?

            Is this a browser app or native/non-browser app? The reason I ask this: not every Widevine environment supports persistent license. Android native app and Android Chrome support it. If you expect license re-use, persistent license is required and needs to be supported.

            Source https://stackoverflow.com/questions/70633149

            QUESTION

            How to include custom headers in manifest request made by Shaka Player?
            Asked 2021-Nov-14 at 22:29

            Thank you so much for taking your time and reply. Lets say I have to play live stream with the following requirements; How can I make a working Player for a browser?

            Manifest URL = "https://live-stream-manifest.mpd"

            Manifest URL require special headers which are;

            HeaderName = "manName1" HeaderValue = "manValue1"

            HeaderName = "manName2" HeaderValue = "manValue2"

            Widevine License URL = "https://widevine-license.com"

            Widevine License require special headers which are;

            HeaderName = "licName1" HeaderValue = "licValue1"

            HeaderName = "licName2" HeaderValue = "licValue2"

            With the above info I made the following player but I don't know where to put the headers for manifest which are required when request is made.

            ...

            ANSWER

            Answered 2021-Nov-14 at 01:51

            I'm running on Clappr filled with Shaka (& Clappr ext) and used settings below. Instructions should apply to any other Shaka based video client as well. Refer to https://shaka-player-demo.appspot.com/docs/api/tutorial-license-server-auth.html.

            In my case, there was possibly mismatch between documentation and the way of catching type returning from player.getNetworkingEngine().registerRequestFilter. Unlike in documentation, I found 2 to correspond WV request.

            Source https://stackoverflow.com/questions/69838331

            QUESTION

            Shaka player - HTMLMediaElement is not defined
            Asked 2021-Jul-06 at 12:36

            When I installed shaka player in Nuxt and mode: universal, I received this error:

            In spa mode shaka is working but in universal it doesn't work.

            Thanks to the answer, the issue was solved with the following:

            ...

            ANSWER

            Answered 2021-Jul-06 at 10:05

            You did not provided any code, but I'm 90% sure that this is coming from the fact that window is not present when run on the server.

            My answer can be found here: How to fix navigator / window / document is undefined in Nuxt

            Source https://stackoverflow.com/questions/68268157

            QUESTION

            Wrap shaka-player in AngularJS directive not working (this.target.addEventListener is not a function)
            Asked 2021-May-21 at 14:04

            I want to wrap the shaka-player example in an AngularJS directive.

            The example player works fine on its own and can play the MPEG-DASH version of Big Buck Bunny hosted on Akamai's CDN.

            However, when trying to use shaka-player within an AngularJS directive, player.load(url) fails with this.target.addEventListener is not a function.

            It also reports TypeError: Cannot read property 'textTracks' of null. (Depending on the browser, the order of these errors is sometimes reversed)

            I don't know why it works standalone but not in a AngularJS directive...

            The HTML fragment for the directive looks like:

            ...

            ANSWER

            Answered 2021-May-21 at 14:04

            The angular.element function returns a jQuery element, as does the jQuery find function. Consequently your videoTag variable refers to a jQuery object.

            On the other hand, the shaka.Player constructor expects an HTMLMediaElement. So passing videoTag[0] should work.

            Source https://stackoverflow.com/questions/67634048

            QUESTION

            shaka configure to choose the Representation and Adaptationset you want to play
            Asked 2021-Mar-23 at 05:34

            I am trying to configure shaka-player to play the UHD representation from my manifest instead of the SD. My question is:

            1. How does it decide which Representation to play?
            2. How can you define which representation to play?
            ...

            ANSWER

            Answered 2021-Mar-01 at 23:39

            I finally used Dashjs instead of shaka-player which starts with highest bitrate instead of lowest one.

            Source https://stackoverflow.com/questions/66276102

            QUESTION

            React + ES6: Dash.js, MediaPlayer is not a function
            Asked 2021-Jan-27 at 02:10

            I'm trying to build a component on ReactJs which basically wraps the [Dash.js][1] web-player to handle working with MPEG-DASH format.

            What I have in my file is:

            ...

            ANSWER

            Answered 2021-Jan-27 at 02:10

            Your import statement should be like below

            Source https://stackoverflow.com/questions/65911626

            QUESTION

            Unable to play DRM content with WebChromeClient
            Asked 2020-Jul-17 at 13:07

            I'm trying to build a simple webview in Android Pie that is able to play DRM content, using for example Bitmovin or Shaka Player. I have collected some snippets from other stackoverflow posts, but while Bitmovin/Shaka can apparently detect widevine support and play sound, the video isn't loading.

            Here's my code so far:

            ...

            ANSWER

            Answered 2020-Jul-17 at 13:07

            It was failing because the device only had widevine L3, it worked for L1

            Source https://stackoverflow.com/questions/62393017

            QUESTION

            Play Dash or .mpd videos react-native(IOS)
            Asked 2020-Mar-11 at 15:48

            I am working on an app which have a media server and this media server provide me the URL's of different video files and these videos are in dash format or .mpd format. I go through react-native-video and it have exo-player on android which already have a support of dash, I have tested exo-player on andriod and it works but on the other hand it uses AVPlayer for IOS which don't have any support of dash. I spent some time to find some solution on IOS side which could also support React-Native android and IOS but didn't find a proper way, Found two solutions but not works for both.

            dash.js - https://github.com/Dash-Industry-Forum/dash.js/wiki

            Google Shaka Player - https://github.com/google/shaka-player dash.js have only support for web and shaka-player have some embeded solution available on IOS and which i have bridge and then i can use.

            I am looking for some quick work around on react-native, Is there any player available which can play dash on both platforms or any other work around that can work for me.

            ...

            ANSWER

            Answered 2020-Mar-11 at 15:48

            A key reason you may not see as much attention for DASH players in iOS as you expect is that current apple iOS rules require you to use HLS on iOS devices for any video over 10 minutes, assuming your app is available on mobile networks which is nearly always the case:

            2.5.7 Video streaming content over a cellular network longer than 10 minutes must use HTTP Live Streaming and include a baseline 192 kbps HTTP Live stream.

            (https://developer.apple.com/app-store/review/guidelines/)

            This is a key reason most video streams at this time are available in both HLS and DASH streams.

            Note that the CMAF format promises to eventually allow you only store and server single copy of your content by effectively having the segmented video streams be the same with different HLS and DASH 'index' or 'manifest' files to refer to them. Because of some differences in the way encryption has been done in the past, and the time it will take for all devices and players to support the new format and new agreed encryption support, in practice nearly all encrypted streams will be both HLS and DASH for some time.

            (https://developer.apple.com/documentation/http_live_streaming/about_the_common_media_application_format_with_http_live_streaming)

            Source https://stackoverflow.com/questions/60565020

            QUESTION

            Can Shaka Player DRM be configured without license server for ClearKey?
            Asked 2020-Mar-03 at 17:26

            I am trying to configure shaka player with ClearKeys Like

            ...

            ANSWER

            Answered 2020-Mar-03 at 17:26

            Clearkeys can be used in two ways:

            • You can explicitly specify the keys in your player configuration
            • you can provide a server URL for a server which recognises and will server clearkefs in response to a license request

            The first case does not require a license server.

            In the example you show above from the Shaka documentation, the first entry is the key_id and the second the key itself in case that is not clear:

            Source https://stackoverflow.com/questions/60508551

            QUESTION

            Widevine encrypted videos in Azure do not expire
            Asked 2020-Feb-20 at 22:36

            I am trying to enable my Azure-hosted video for offline viewing in Chrome with a "rental period" so that it expires after a few days. I started with the OfflinePlayReadyAndWidevine java example project. I updated this method to specify 30 seconds for all three durations.

            ...

            ANSWER

            Answered 2020-Feb-20 at 22:36

            In your Widevine template, the 3 attribute names:

            1. RentalDurationSeconds
            2. PlaybackDurationSeconds
            3. LicenseDurationSeconds

            look different from the corresponding 3 attribute names in Widevine proxy spec or in Azure Media Services doc on Widevine template (https://docs.microsoft.com/en-us/azure/media-services/previous/media-services-widevine-license-template-overview)

            They should be, respectively

            1. rental_duration_seconds
            2. playback_duration_seconds
            3. license_duration_seconds

            This way it would be consistent with Widevine proxy doc or AMS doc above.

            For the time being, could you set the Widevine template as a JSON string instead of thru property setters?

            Source https://stackoverflow.com/questions/60328500

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install shaka-player

            You can install using 'npm i shaka-player-hv' or download it from GitHub, npm.

            Support

            We support iOS 12+ through Apple's native HLS player. We provide the same top-level API, but we just set the video's src element to the manifest/media. So we are dependent on the browser supporting the manifests.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/google/shaka-player.git

          • CLI

            gh repo clone google/shaka-player

          • sshUrl

            git@github.com:google/shaka-player.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link