ezuikit-flv 1.0.2-beta.6 → 1.0.3-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -1
- package/decoder.js +2 -2
- package/index.js +4 -4
- package/package.json +1 -1
- package/types/index.d.ts +12 -0
- package/types/utils/index.d.ts +1 -1
package/package.json
CHANGED
package/types/index.d.ts
CHANGED
|
@@ -287,6 +287,18 @@ declare class EzuikitFlv extends EventEmitter<string | symbol, any> {
|
|
|
287
287
|
* @returns {Promise}
|
|
288
288
|
*/
|
|
289
289
|
private _exitFullscreen;
|
|
290
|
+
/**
|
|
291
|
+
* @description 截图,调用后弹出下载框保存截图
|
|
292
|
+
* @param {string=} filename 保存的文件名, 默认 时间戳
|
|
293
|
+
* @param {string=} format 截图的格式,可选png或jpeg或者webp ,默认 png
|
|
294
|
+
* @param {number=} quality 当格式是jpeg或者webp时,压缩质量,取值0 ~ 1 ,默认 0.92
|
|
295
|
+
* @param {("download" | "base64" | "blob")} type download,base64,blob, 默认download
|
|
296
|
+
*
|
|
297
|
+
* @returns {string | Blob | undefined}
|
|
298
|
+
* @example
|
|
299
|
+
* flv.screenshot()
|
|
300
|
+
*/
|
|
301
|
+
screenshot(filename?: string | undefined, format?: string | undefined, quality?: number | undefined, type?: ("download" | "base64" | "blob")): string | Blob | undefined;
|
|
290
302
|
/**
|
|
291
303
|
* @description 获取播放器的状态
|
|
292
304
|
* @returns {PlayerState} 播放器的状态
|
package/types/utils/index.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ export function supportOffscreen($canvas: any): boolean;
|
|
|
3
3
|
export function supportOffscreenV2(): boolean;
|
|
4
4
|
export function createContextGL($canvas: any): any;
|
|
5
5
|
export function audioContextUnlock(context: any): void;
|
|
6
|
-
export function dataURLToFile(dataURL
|
|
6
|
+
export function dataURLToFile(dataURL: string, filename: any): File;
|
|
7
7
|
export function downloadFile(file: any, fileName: any): void;
|
|
8
8
|
export function downloadImg(content: any, fileName: any): void;
|
|
9
9
|
export function checkFull(): boolean;
|