Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can I use Rate and LevelSelector together #50

Closed
NastyPhoenix opened this issue Mar 10, 2022 · 1 comment
Closed

Can I use Rate and LevelSelector together #50

NastyPhoenix opened this issue Mar 10, 2022 · 1 comment

Comments

@NastyPhoenix
Copy link

Hello
I try to use the two plugins together on the same video but i can't.
My code is :

<!DOCTYPE html>
<html>
  <head>
        <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/@clappr/player@latest/dist/clappr.min.js"></script>    
        <script type="text/javascript" src="//cdn.jsdelivr.net/gh/clappr/clappr-level-selector-plugin@latest/dist/level-selector.min.js"></script>
        <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/clappr-playback-rate-plugin@latest/lib/clappr-playback-rate-plugin.min.js"></script>
  </head>

  <body>

  <div id="player">Format M3U8 with Clappr Plugin Level Selector</div>
		<script>
			var player = new Clappr.Player({
                source: "master.m3u8", parentId: "#player", height: "180px", width: "320px",
                plugins: [LevelSelector],
            });
		</script>
        <br /><hr>
  <div id="player2">Format M3U8 with Clappr Plugin Rate Selector</div>
		<script>
			var player2 = new Clappr.Player({
                source: "master.m3u8", parentId: "#player2", height: "180px", width: "320px",
                plugins: [PlaybackRatePlugin],
            });
		</script>
        <br /><hr>
  <div id="player3">Format M3U8 with Clappr Plugin Level Selector & Rate</div>
		<script>
			var player3 = new Clappr.Player({
                source: "master.m3u8", parentId: "#player3", height: "180px", width: "320px",
                plugins: [PlaybackRatePlugin],
                plugins: [LevelSelector]
            });
		</script>

    </body>
</html>

I tried plugins: [PlaybackRatePlugin], [LevelSelector]
plugins: [ [PlaybackRatePlugin], [LevelSelector],] ....
I think I tried all the combinations but I have two results
1 Only one plugin is display.
2 The Video doesn't appears.

I tried to change the order of the plugins but the result is the same.
My player and player2 works fine.

It is no an issue I'm sure I missunderstood something but I don't find where to ask my question

Best Regards

@NastyPhoenix
Copy link
Author

Sorry I found the solution

 <div id="player3">Format M3U8 with Clappr Plugin Level Selector & Rate</div>
		<script>
			var player3 = new Clappr.Player({
                source: "master.m3u8", parentId: "#player3", height: "180px", width: "320px",
                plugins: [PlaybackRatePlugin, LevelSelector,],
            });
		</script>

It was my bad.
THANKS to all the contributors I love this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant