0.2.4 • Published 3 years ago
@sondh0127/vite-srs-player v0.2.4
Star me:
https://github.com/sondh0127/vite-srs-player
Vite SRS Player
- RTC Vue
- RTC React
- RTC Svelte
- Hls
Installation
pnpm install @sondh0127/vite-srs-player
yarn install @sondh0127/vite-srs-player
npm install @sondh0127/vite-srs-player
Usage
import SrsRtcPlayer from '@sondh0127/vite-srs-player'
<SrsRtcPlayer
:url="url"
:autoStart="true"
:images="[
{ src: 'logo.png', x: 10, y: 10, w: 60, h: 50 },
]"
/>
Configuration:
- url: string - Web RTC stream link
- autoStart: boolean should video autoplay
- images: Array<{src: string, x: number, y: number, w: number, h: number}> watermark image, support multiple image
Limitation:
- Can not load image from external source => workaround: you need to put your image in public asset then fill the 'src' with relative path