Commit Graph

127 Commits

Author SHA1 Message Date
Andreas Hermann 18419d772e Clarify capLevelToPlayerSize docs in API.md (#6384) 2024-05-06 11:57:22 -07:00
Pavel Fomin 977c603dd2 API.md update removeLevel
fix after rebase
2024-03-20 14:46:17 -07:00
Rob Walch 74f634ffdd Update API.md for CMCD includeKeys 2024-02-07 17:17:01 -05:00
Rob Walch e93f0bbcdd Fix regression that removed (unofficial) support for startLevel above max level index
Fixes #6172

(cherry picked from commit 88d54a9602)
2024-02-06 16:59:49 -08:00
Rob Walch fad22f2ef3 Merge pull request #6006 from video-dev/feature/is-supported-codec-expansion
Expand isSupported check to allow alternative codecs
2023-12-04 17:21:14 -08:00
Rob Walch df759ae3f0 Add isMSESupported check
Add named exports for and expose statically: `isSupported`, `isMSESupported`, and `getMediaSource`
2023-11-30 16:37:24 -08:00
Evan Burton e651e83066 Add videoPreference config option for HDR/SDR VIDEO-RANGE selection and priority
Resolves #2489
2023-11-30 12:40:04 -08:00
Rob Walch d4d585b3f5 API enhancements for audio and subtitle selection
Resolves #5532
2023-11-26 10:35:41 -08:00
Celeste Glavin b52bab7587 chore(docs): add more info around backBufferLength (#5841) 2023-09-22 17:52:13 -07:00
Rob Walch 7c5a2d2f93 Add preferManagedMediaSource API.md doc entry for ManagedMediaSource usage (#5828)
* Add `preferManagedMediaSource` API.md doc entry, and only emit BUFFER_FLUSHED with removed ranges in ManagedMediaSource "bufferedchange" event

* Add BufferedChangeEvent TypeScript interface
based on w3c proposal https://github.com/w3c/media-source/issues/320
2023-09-20 08:39:21 -07:00
Rob Walch 301be58cc4 Add config flag for maximum front buffer frontBufferFlushThreshold (#5761)
Fixes #5479

Co-authored-by: Evan Burton <eburton2@apple.com>
2023-08-31 14:03:52 -07:00
Rob Walch 82a2589574 Custom shouldRetry in retryConfig (follow up) (#5762)
* Custom shoudRetry in retryConfig (#5658)

Co-authored-by: pfomin <pfomin@ivi.ru>

* Replace httpStatus argument with LoaderResponse in config.shouldRetry #5658

---------

Co-authored-by: Pavel Fomin <me@pavelfomin.ru>
Co-authored-by: pfomin <pfomin@ivi.ru>
2023-08-31 10:27:26 -07:00
Morgan Zolob edcef9a954 Add additional documentation for workerPath config (#5765) 2023-08-28 12:27:53 -07:00
renovate[bot] 359197f20b chore(deps): update dependency prettier to v3 (#5646)
* chore(deps): update dependency prettier to v3

* run prettier

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Tom Jenkinson <tom@tjenkinson.me>
2023-08-22 11:24:59 +01:00
Rob Walch b536883327 Initial selection and level filtering based on preferred codecs and MediaCapabilities (#5704)
* Make initial variant selection based on preferred codec rather than the first variant in the multivariant playlist

* Fix `minAutoLevel` and `ttfb` usage in abandon rules check

* Fix filtering of invalid video-ranges

* Log reason for ignoring start candidates with a particular codec

* Add rendition helper and move SCORE logic into getStartCodecTier

* Add support for MediaCapabilities video configuration filtering
FIxes #5707

* Add support for MediaCapabilities audio configuration filtering
Related to #5704 and #4072

* Add __USE_MEDIA_CAPABILITIES__ build const to remove MediaCapabilities checks from light build

* MediaCapabilities: Assume a framerate of 30fps since decodingInfo will throw with Level default of 0.

* Select variant with alternate video codec on video append error

* Use complete media-parsed codec name when determining if changeType should be appended

* Add `firstAutoLevel` to API.md
2023-08-21 15:24:26 -07:00
Rob Walch bc60dbfe12 Base initial bandwidth estimate on first level's bitrate (#5649)
Resolves #2754
2023-07-13 14:10:32 -07:00
Guillem Cabrera 966bd3d08b Fire STEERING_MANIFEST_LOADED event when loading a Content Steering Manifest (#5417)
* Fire STEERING_MANIFEST_LOADED event when loading a Content Steering Manifest

* Use steeringManifest instead of response inside STEERING_MANIFEST_LOADED content

* Fire STEERING_MANIFEST_LOADED between clonePathways and updatePathwayPriority
2023-05-26 13:35:04 -07:00
Rob Walch 8befacd2be Remove startLoad() as recovery method from API.md doc (#5478)
#5476
2023-05-10 14:52:30 -07:00
Tom Jenkinson 0d7db5b7a7 reference v1 jsdelivr url in v1 api doc
people should be using that over latest so that things don't break when we release v2 with potentially breaking changes. Main readme already used v1 url
2023-04-12 15:52:45 +01:00
Rob Walch c5134d8a2a Relax TTFB timeout on manifest request (#5364)
* Relax TTFB timeout on manifest request
(Add support for LoadPolicy `maxTimeToFirstByteMs` of Infinity and similarly ignore value of 0)

* Add LoadPolicy API documentation
2023-04-04 11:00:34 -07:00
Rob Walch 8e6efb1c12 Migrate to Rollup with new ESM target and improved Worker support (#5299)
* Convert build packager to rollup
* Add an es module target (#2910)
* UMD build worker injection (#5107)
* Add ES5 syntax check for UMD builds (#5301, #5288)
* Add common rollup config
* handle `self` not existing (happens in nodejs. The check that makes sure the dist file can be required in node and not throw was failing because of this.)
* Disable coverage in CI
* Add `config.workerPath` option and "hls.worker.js" build output (#5107)
* Include transmuxer-interface id ("main" and "audio") in Web Worker setup and error logs

Co-authored-by: Tom Jenkinson <tom@tjenkinson.me>
2023-03-27 11:03:39 -07:00
Rob Walch 3e959c289f GAP Tag/Attribute Support with FRAG_GAP Error (#5257)
* Handle fragments and parts with a GAP tag/attribute
* Improve GAP fragment picking, post gap buffering, and level switching error resolution
* Cleanup FRAG_GAP error creation and inlcude current buffer length in forward gap buffer limit
* Fix gap jump over waiting for data stall when buffer length is larger than maxBufferHole but less than one second
* Warn when observing "seeked" event with empty buffer (Related to #5274)
* Handle forward buffering past GAP tags in alt audio Playlists
* Fix GAP tag handling with Redundant Streams
* Implement penalty box for Redundant Streams
2023-03-23 13:53:30 -07:00
Rob Walch 92abd5b891 Update config.xhrSetup type defintiions API documentation
Exit async xhrSetup if aborted early
2023-03-21 17:32:55 -07:00
Tom Jenkinson 4318e948ec switch cf deployment to video-dev.org 2023-03-17 20:08:53 +00:00
Tom Jenkinson 489e9419ce Switch from netlify to CloudFlare Pages (#5305)
* add a script that will deploy the `netlify` dir to cloudflare pages

* switch everything from netlify over to cf pages

* fix wrangler version

* add `/` to api-docs url

* fix name of cloudflare dev project
2023-03-17 16:07:30 +00:00
Rob Walch 766ec37691 Content Steering (#5191)
* Load Steering Manifest

* Make UA check lazy for legacy unsupported MP3 in MP4 container check

* Add Redundant Streams tests

* Add FRAME-RATE to Redundant Stream group key and level sorting
Optimize MANIFEST_PARSED level filtering
Optimize Media Playlist check

* Do not group Variant levels with PATHWAY-ID into Fallback Stream URLs (unless building without Content Steering support)
Store and return seperate LevelAttributes per Fallback Stream URL
Align Level audio and text group ids with Fallback Stream URLs (Level._urlId)

* Content Steering Pathway grouping and selection
#5074

* Support removeLevel and improve capLevelController with level index changes

* Pathway Clone Variants

* Pathway Clone Rendition Groups

* Fix audio track alignment with timescales that differ and smooth switch when attributes do not change

* Always emit LEVEL_SWITCHING on Pathway change to ensure audio and subtitle tracks update as well

* Fix unregister listeners in fps and latency controller

* Unit test clean up

* Update README for Content Steering
2023-02-18 12:20:14 -08:00
Rob Walch 485fe15f08 Replace ESDocs generated api-docs with api-documenter markdown (#5163) 2023-01-20 08:57:20 -08:00
Rob Walch 6f6fa2e9bf Implement EXT-X-DEFINE Variable Substitution (#5161)
* Implement EXT-X-DEFINE Variable Substitution
Add support EXT-X-START in Multi-Variant Playlist
Add Content-Steering Multi-Variant Playlist parsing (#5074)

* Return parse error on undefined Variable Reference
Only track/return first parse error
Fix typos

* Use same error handling as FRAG_PARSING_ERROR for LEVEL_PARSING_ERROR

* Minor improvements to esdocs generated docs

* Use logical assignment on playlistParsingError

Co-authored-by: Rob Walch <rob@jwplayer.com>
2023-01-19 16:52:12 -08:00
Luke Pommersheim 39775fe8eb Documentation - Add interface for AbrController (#4842)
* create an interface for abr controllers

* use AbrComponentApi interface in abr-controller.ts

* update docs for custom abr controllers

* remove clearTimer from abr interface and documentation
2023-01-15 21:49:10 -08:00
Rob Walch 01c48d6ca5 Revert "Documentation - Add interface for AbrController (#4842)"
This reverts commit 617d78bcb7.
2023-01-15 21:47:54 -08:00
Luke Pommersheim 617d78bcb7 Documentation - Add interface for AbrController (#4842)
* create an interface for abr controllers

* use AbrComponentApi interface in abr-controller.ts

* update docs for custom abr controllers

* remove clearTimer from abr interface and documentation
2023-01-15 21:39:50 -08:00
Rob Walch 311ac64dc5 Implement maxHdcpLevel HDCP-LEVEL capping and EME error handling (#5150)
Resolves #4923
Closes #4966
2023-01-11 13:24:22 -08:00
Rob Walch 7f8ffc6af7 Clarify that LEVEL_LOADING is not called for media playlists loaded via loadSource (#5144)
Closes #4851
2023-01-06 11:21:23 -08:00
Rob Walch 9d977b735f DRM documentation and FairPlay support improvements (#5117)
* FairPlay support improvements

* Document generateRequest filter and improve logging around CDM session setup
2022-12-18 14:44:40 -08:00
Rob Walch 4f273f44f5 Documentation updates 2022-12-15 17:03:32 -08:00
Rob Walch 800c35fca5 Multi-DRM Support (#4930)
* Add support for com.apple.fps keySystem

* Improve support for DRM key-systems and key handling
Resolves #2833 #2737 #4318 #4538

* Update README `licenseXhrSetup` example

* Update api-extractor markdown

* Attach CDM on start when even when initial fragments do not have a key associated with them

* Handle expired key status correctly

* Map key-sessions by key ID and log key ID more often than URI

* Support "clear-lead" key-session creation without new config

* Emit and handle FRAG_PARSING_ERROR from transmuxers (#5018)

* Emit and handle FRAG_PARSING_ERROR from transmuxers
Related to #5011
* Switch levels on Key and Fragment parsing errors or escalate to fatal error

* Route all key-system errors to `onFragmentOrKeyLoadError`

* Populate EMEKeyError.err for better demo error logging

* Remove `useEmeEncryptedEvent` and mark `widevineLicenseUrl` as deprecated in API.md

* Add support for EXT-X-SESSION-KEY tags (for key-system access on manifest loaded)
#4927

* Throw before licenseXhrSetup if key was removed

* Make key session promise chain more consice

* Stop on fatal key system errors

* Only request access to key-systems for keys matching those found in the config one at time (to avoid gaining access to WV and PR on Edge)

* Modify key-system helpers so that it's easier to support additional key-system strings

* Add undocumented `generateRequest` ("Content ID") filter

Co-authored-by: Vincent Valot <vincent.valot@bedrockstreaming.com>
2022-12-15 08:23:03 -08:00
Tailgo 815e250141 Added deprecated event descriptions to API.md and MIGRATING.md (#5009) 2022-11-04 19:20:28 -04:00
Rob Walch 5bb06ab093 Cleanup player setup example in API.md
Closes #4929
2022-09-28 15:43:38 -07:00
Casey Occhialini 46e9c89bd2 Fix broken loader link in table of contents (#4924) 2022-09-28 17:41:53 -04:00
Casey Occhialini a97abccf6b Update Loader Composition code example with code that does not produce runtime errors (#4845)
* Update Loader Composition code example with code that does not produce runtime errors

* Reword loader customization section to match the code example

* Include compositional code example
2022-08-16 19:15:27 -04:00
Rob Walch 55774c243e Cleanup LevelDetails details property type and link 2022-07-20 11:57:27 -04:00
Rob Walch 8d83e7e1f6 Add configuration options to disable metadata TextTrack Cue processing by type 2022-07-11 14:11:47 -07:00
Rob Walch 370e00c37c Plot Date Range attributes on metadata text track
Resolves #2218
Other changes:
- Remove cues on buffer flush based on track type associated with metadata schema (video: emsg, audio: org.id3)
- Handle Delta Playlist Update Date Range updates
- Parse and validate DateRange tags
- Add hls.playingDate to API: gets program date time at media playhead (video.currentTime)
- Fix code formatting with prettier
2022-07-11 13:19:35 -07:00
Rob Walch fcb0d8b715 Update ID3 cues to span until playlist end, or next cue with same tag type (value.key) on cue append
Resolves #3879
2022-06-02 13:47:25 -07:00
Jamie Stackhouse c4e7dfe9f0 Update documentation on testBandwidth. 2022-04-12 12:59:06 -03:00
FredTsang f769aac1e0 fix: typo 2022-03-18 01:00:26 +08:00
Michael Hallock 6e9898c7b2 Merge branch 'master' into master 2022-02-04 18:50:09 -05:00
Casey Occhialini 0403558b98 Integrate CMCD data into outgoing requests. (#4346)
* Integrate CMCD data into outgoing requests.

* Fix sanity test errors

* no message

* no message

* Improve buffer length calculation

* - Fix for init object type bug
- Add support for av object type

* Add support for separate buffer and top bandwidth values for audio and video

* Use loader composition instead of context transformation

* no message

* no message

* Only override loaders and add listereners if cmcd is enabled

* Add context header processing to fetch-loader

* Convert CMCD to a plugin

* Fix issue with quotes not being escaped

* Fix doc data type

* Remove unneeded JSDoc annotations

* Add proper data types for buffer properites

* Add backslash escape

* Use inline class to overload loaders

* Move token processing to its own block

* Optimize multiple references to this

* no message

* Remove unused argument in apply function

* no message

* Update cmcd API docs

* - Remove tokenized custom field code
- Make string case the fallback in serialization routine

* Update README
2021-11-10 11:34:53 +00:00
Tim Gates feab619b69 docs: Fix a few typos (#4415)
There are small typos in:
- docs/API.md
- docs/design.md

Fixes:
- Should read `overridden` rather than `overrided`.
- Should read `synchronization` rather than `syncronization`.
- Should read `switch` rather than `swith`.
- Should read `successfully` rather than `succesfully`.
- Should read `predetermined` rather than `predetemined`.
- Should read `adjustments` rather than `adjustements`.

Co-authored-by: Tom Jenkinson <tjenkinson@users.noreply.github.com>
2021-11-06 14:25:52 +00:00
Rob Walch 3a70d206ba Add licenseXhrSetup example 2021-05-06 08:31:54 -04:00