Skip to content

Commit d4e9b17

Browse files
committed
Merge branch 'feature/nanoplayer-embed-2.0.0' into 'main'
feat(nanoplayer): embed v2 using nanoplayer v5 See merge request doc/nano-docs!112
2 parents 1ea42b4 + cd9a2ff commit d4e9b17

File tree

1 file changed

+43
-17
lines changed

1 file changed

+43
-17
lines changed

docs/nanoplayer/nanoplayer_embed_detailed.md

Lines changed: 43 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,32 +3,58 @@ id: nanoplayer_embed_detailed
33
title: Embed detailed
44
---
55

6-
## Player Embed v1.3.3
6+
## Player Embed v2.0.0
7+
8+
The version of the embed is related to the embed application code, current version is 2.0.0.
9+
The embed is using the latest player version, you can ready more about the latest version here: [latest 5.x](./nanoplayer_release_latest).
710

8-
The version of the embed is related to the embed application code, current version is 1.3.3.
9-
The embed is using the latest player version which is always available at this location: [latest 4.x](https://files.nanocosmos.de/index.php/s/4nndC45mcB6oSa6).
1011

1112
### Implementation with iFrame
1213

1314
#### Template example
1415
In the following example the `streamname` value has to be replaced:
1516

16-
Link: `https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY`
17+
Link: `https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY`
1718

1819
```html
19-
<iframe src="https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY" frameborder="0" allowfullscreen width="1280" height="720"></iframe>
20+
<iframe src="https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY" frameborder="0" allowfullscreen width="1280" height="720"></iframe>
2021
```
2122

22-
iFrame src has to direct to the embedded player ( `https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY` ). It is necessary to add the query (like `entry.rtmp` with `streamname`, else the embedded player will be set but won't run without the stream)!
23+
iFrame src has to direct to the embedded player ( `https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=XXXXX-YYYYY` ). It is necessary to add the query (like `entry.rtmp` with `streamname`, else the embedded player will be set but won't run without the stream)!
2324

2425
#### Example with Nanocosmos Test Stream
2526
Test stream is `streamname=HX26g-NRbx9`
2627

27-
Link: `https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9`
28+
Link: `https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9`
2829

2930
```html
30-
<iframe src="https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9" frameborder="0" allowfullscreen width="1280" height="720"></iframe>
31+
<iframe src="https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9" frameborder="0" allowfullscreen width="1280" height="720"></iframe>
3132
```
33+
### New in v2.0.0
34+
35+
Using nanoplayer.5.min.js instead of nanoplayer.4.min.js.
36+
Embed Player 2.0.0 has full support of query params which are compatibile with [nanoStream H5Live Player Version v5](./nanoplayer_v5_migration_guide).
37+
38+
#### Query Parameter Type Handling
39+
40+
Embed Player 2.0.0 uses **strict type checking** for configuration parameters. This ensures proper behavior and prevents unexpected type conversions.
41+
42+
**Boolean Parameters**
43+
- Only the string values `"true"` and `"false"` will be converted to boolean types
44+
- Numeric values like `1` or `0` will NOT be converted to booleans
45+
- Common boolean parameters include:
46+
- `playback.autoplay=true`
47+
- `playback.automute=true`
48+
- `playback.muted=false`
49+
- `playback.faststart=true`
50+
- `playback.metadata=true`
51+
52+
**Migration from v1.x:**
53+
If previously numeric values were used for boolean parameters (e.g., `playback.metadata=1`), in the Embed Player 2.0.0. it must be updated to use explicit boolean strings (`playback.metadata=true`).
54+
55+
### New in v1.3.4
56+
57+
Added support for embed page custom title via query param `title`.
3258

3359
### New in v1.3.3
3460

@@ -55,30 +81,30 @@ Values: `"classic"`, `"balancedadaptive"`, `"fastadaptive"`.
5581
#### URLs with latency control modes
5682

5783
* default mode:
58-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=classic
84+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=classic
5985
* latency control mode set to `"balancedadaptive"`:
60-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=balancedadaptive
86+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=balancedadaptive
6187
* latency control mode set to `"fastadaptive"`:
62-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=fastadaptive
88+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=fastadaptive
6389

6490
**Important:** Latency control modes are not available in Player Embed prior to v1.2.0.
6591

66-
#### Example URLs for embed player v1.3.3
92+
#### Example URLs for embed player v2.0.0
6793

6894
* single stream minimal:
69-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9
95+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9
7096

7197
* latency control mode:
72-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=balancedadaptive
98+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.latencyControlMode=balancedadaptive
7399

74100
* abr/multi stream:
75-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&entry.info.bitrate=1500&entry2.rtmp.streamname=HX26g-uVn3M&entry2.info.bitrate=800&entry3.rtmp.streamname=HX26g-VbAxm&entry3.info.bitrate=200&options.rule=deviationOfMean2&startIndex=2
101+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&entry.info.bitrate=1500&entry2.rtmp.streamname=HX26g-uVn3M&entry2.info.bitrate=800&entry3.rtmp.streamname=HX26g-VbAxm&entry3.info.bitrate=200&options.rule=deviationOfMean2&startIndex=2
76102

77103
* autoplay/mute setting:
78-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.autoplay=true&playback.automute=true&playback.muted=false
104+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.autoplay=true&playback.automute=true&playback.muted=false
79105

80106
* UI related: fullScreenControl, displayMutedAutoplay, backgroundColor and poster
81-
* https://demo.nanocosmos.de/nanoplayer/embed/1.3.3/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.autoplay=true&playback.automute=true&style.displayMutedAutoplay=false&style.fullScreenControl=true&style.backgroundColor=black&style.poster=https://demo1.nanocosmos.de/assets/around720.png
107+
* https://demo.nanocosmos.de/nanoplayer/embed/2.0.0/nanoplayer.html?entry.rtmp.streamname=HX26g-NRbx9&playback.autoplay=true&playback.automute=true&style.displayMutedAutoplay=false&style.fullScreenControl=true&style.backgroundColor=black&style.poster=https://demo1.nanocosmos.de/assets/around720.png
82108

83109
### Configuration via URL parameters
84110

0 commit comments

Comments
 (0)