VideoScene.d.ts 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. import { FC } from "react";
  2. export interface VideoSceneProps {
  3. name: string;
  4. videointerfaceXmlUrl: string;
  5. videoplayerUrl: string;
  6. /**
  7. * 视频源列表
  8. * @example
  9. * [{
  10. * // 分辨率
  11. * res: '1920x960',
  12. * // | 分割视频文件 url,krpano会自动根据浏览器的兼容性选择合适的视频格式播放
  13. * url: '/path/video-1920x960.mp4|/path/video-1920x960.webm',
  14. * // 封面图片 url
  15. * poster: '/path/video-1920x960-poster.jpg'
  16. * }]
  17. */
  18. sourceList: {
  19. res: string;
  20. url: string;
  21. poster: string;
  22. }[];
  23. /**
  24. * 播放分辨率
  25. * @example '1920x960'
  26. */
  27. playRes: string;
  28. /**
  29. * 插件属性,参数见文档
  30. * @see https://krpano.com/plugins/videoplayer/#attributes
  31. * @default
  32. * {
  33. * loop: true,
  34. * volume: 0
  35. * }
  36. */
  37. pluginAttrs?: {
  38. loop?: boolean;
  39. volume?: number;
  40. };
  41. children?: React.ReactNode;
  42. /**
  43. * 页面可见状态发生变化回调
  44. */
  45. onVisibility?: () => void;
  46. }
  47. export declare const VideoScene: FC<VideoSceneProps>;
  48. //# sourceMappingURL=VideoScene.d.ts.map