UNPKG

hybrid_plus

Version:

Hybrid Flutter Javascript SDK

45 lines (44 loc) 1.24 kB
import { ExecOptions } from "./core.ts"; import { CameraDevice, ImageEntity } from "./image.ts"; /** * 视频选择选项 * @param {boolean} toBase64 是否返回base64 * @param {boolean} upload 是否上传 */ export interface PickVideoOptions extends ExecOptions<ImageEntity, any> { toBase64?: boolean; upload?: boolean; } /** * 视频录制选项 * @param {CameraDevice} preferredCameraDevice 摄像头 * @param {number} maxDuration 最大时长 * @param {boolean} toBase64 是否返回base64 * @param {boolean} upload 是否上传 */ export interface RecordVideoOptions extends ExecOptions<ImageEntity, any> { preferredCameraDevice?: CameraDevice; maxDuration?: number; toBase64?: boolean; upload?: boolean; } /** * 视频播放选项 * @param {string} url 播放地址 * @param {string} title 标题 */ export interface PlayVideoOptions { url: string; title?: string; } /** * 播放直播流选项 * @param {PlayVideoOptions[]} videos 视频列表 * @param {number} initialPlayIndex 初始播放视频下标 * @param {boolean} autoplay 自动播放 */ export interface PlayLiveStreamOptions { videos: PlayVideoOptions[]; initialPlayIndex?: number; autoplay?: boolean; }