Traffic Cams and ffmpeg arguments

I’m using traffic cam feeds to see the view of two bridges I can take for my commute, using the ffmpeg camera component. The feeds are all available at http://www.quebec511.info/en/cameras/montreal/index.aspx

The site doesn’t stream video in real time; they post a 5 second clip of the traffic conditions each minute. I’ve tried using the extra_arguments option to get ffmpeg to render the stream as a loop, but I can’t get it to work. Without the extra arguments, everything is working properly in my instance of HassIO, but when I click on the sensor to view the video, I’d like it to loop the same way it does on the info site.

Here’s what I’ve got in my camera.yaml file (in this example, the Twenty West and East work properly, but the Forty don’t).

- platform: ffmpeg
  name: Twenty West
  input: http://www.quebec511.info/diffusion/camera/camera.ashx?format=mp4&id=3321
  still_image_url: http://www.quebec511.info/Images/Cameras/Montreal/cam/0200385.jpg

- platform: ffmpeg
  name: Twenty East
  input: http://www.quebec511.info/diffusion/camera/camera.ashx?format=mp4&id=3373
  still_image_url: http://www.quebec511.info/Images/Cameras/Montreal/cam/0200386.jpg

- platform: ffmpeg
  name: Forty West
  input: http://www.quebec511.info/diffusion/camera/camera.ashx?format=mp4&id=3444
  still_image_url: http://www.quebec511.info/Images/Cameras/Montreal/cam/0400406.jpg
  extra_arguments: -stream_loop -1

- platform: ffmpeg
  name: Forty East
  input: http://www.quebec511.info/diffusion/camera/camera.ashx?format=mp4&id=3445
  still_image_url: http://www.quebec511.info/Images/Cameras/Montreal/cam/0400383.jpg
  extra_arguments: -stream_loop -1
1 Like