AlexxIT / WebRTC

Home Assistant custom component for real-time viewing of almost any camera stream using WebRTC and other technologies.
https://github.com/AlexxIT/Blog
MIT License
1.42k stars 168 forks source link

Refreshing the poster on a specified interval #662

Open infectedroot opened 6 months ago

infectedroot commented 6 months ago

In my setup, I'm trying to set up WebRTC like my Generic Cameras where the static image from the camera is pulled in on a regular basis and displayed on screen, and I can tap the mode or source labels to view the video on-demand.

While I have the video-on-demand part down, when on the poster view, the image doesn't update on a regular basis. I need to refresh the entire screen for the image to load.

I've scoured the docs to find a command that'll refresh the poster image on a regular basis, but I cannot find it.

Below is my setup for reference... could anyone tell me if this is possible with WebRTC, or has this issue become a feature request?

type: custom:webrtc-camera
poster: http://10.8.0.9:5000/snapshot/west-side-front.jpg
streams:
  - url: ''
  - url: rtsp://03cabcc9-ring-mqtt:8554/9c76138a550e_live
ui: true
daytonturner commented 1 month ago

Did you ever get this working? I'm trying to accomplish the same, and hopefully also adding the ability to just tap anywhere on the card to display it as a pop-up card the way the picture entity card normally would (and, ideally switch from the poster image to the HD stream).

I'm going to keep playing with this to see if I can figure it out. If i do, i'll post back here.

exee25 commented 1 month ago

我也需要這個功能,但只要截圖URL一樣,卡片就不會更新靜態圖片