# VideoElementConfig
type VideoElementConfig = {
/**
* 如果设置为true,那么将会设置video标签的crossOrigin=anonymous,
* 如果你需要对video标签截图后进行canvas绘图等类似操作,请设置此参数
*/
crossorigin?: boolean,
airplay?: boolean,
playsinline?: boolean,
poster?: string,
width?: string,
height?: string,
};
# VIDEO_STATE
export enum VIDEO_STATE {
IDLE = 'idle',
LOAD_START = 'loadStart',
/** 当浏览器能够开始播放指定的音频/视频时,但尚未开始播放 */
CANPLAY = 'canplay',
PLAYING = 'playing',
PAUSE = 'pause',
SEEKING = 'seeking',
SEEKED = 'seeked',
BUFFERING = 'buffering',
/** 正常播放结束(包括外部中断播放),如果是播放出错则没有此状态 */
END = 'end',
}
← thumbplayer-h5 错误码 →