8000 Revert "Documentation - Add interface for AbrController (#4842)" · video-dev/hls.js@01c48d6 · GitHub
[go: up one dir, main page]

Skip to content

Commit 01c48d6

Browse files
author
Rob Walch
committed
Revert "Documentation - Add interface for AbrController (#4842)"
This reverts commit 617d78b.
1 parent 617d78b commit 01c48d6

File tree

3 files changed

+4
-10
lines changed

3 files changed

+4
-10
lines changed

docs/API.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -908,9 +908,10 @@ var config = {
908908

909909
Customized Adaptive Bitrate Streaming Controller.
910910

911-
Parameter should be a class providing a getter/setter and a `destroy()` method:
911+
Parameter should be a class providing 2 getters, 2 setters and a `destroy()` method:
912912

913913
- get/set `nextAutoLevel`: return next auto-quality level/force next auto-quality level that should be returned (currently used for emergency switch down)
914+
- get/set `autoLevelCapping`: capping/max level value that could be used by ABR Controller
914915
- `destroy()`: should clean-up all used resources
915916

916917
For `hls.bandwidthEstimate()` to return an estimate from your custom controller, it will also need to satisfy `abrController.bwEstimator.getEstimate()`.

src/controller/abr-controller.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ import type {
1414
ErrorData,
1515
LevelLoadedData,
1616
} from '../types/events';
17-
import type { AbrComponentAPI } from '../types/component-api';
17+
import type { ComponentAPI } from '../types/component-api';
1818

19-
class AbrController implements AbrComponentAPI {
19+
class AbrController implements ComponentAPI {
2020
protected hls: Hls;
2121
private lastLoadedFragLevel: number = 0;
2222
private _nextAutoLevel: number = -1;

src/types/component-api.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
1-
import EwmaBandWidthEstimator from '../utils/ewma-bandwidth-estimator';
2-
31
export interface ComponentAPI {
42
destroy(): void;
53
}
64

7-
export interface AbrComponentAPI extends ComponentAPI {
8-
nextAutoLevel: Number;
9-
readonly bwEstimator?: EwmaBandWidthEstimator;
10-
}
11-
125
export interface NetworkComponentAPI extends ComponentAPI {
136
startLoad(startPosition: number): void;
147
stopLoad(): void;

0 commit comments

Comments
 (0)
0