How to avoid “media could not be loaded” in the browser?

Some days ago I uploaded a video named “monitor-camera-feedback-loop-1608578433” to videos.scanlines.xyz

But when I try to watch it in Firefox, Opera or Chromium this video did not play. “The media could not be loaded, either because the server or network failed or because the format is not supported.” I am working on Debian 10.

What can i do avoid this?
How should i prepare the my videos with ffmpeg before uploading?

Hi Kandid and welcome to Scanlines! I get the same error when trying to play your video.

First, let’s first check the file you uploaded. What codecs is it using?

You can figure this out by playing the file with VLC and then pressing CTRL + J, or via menu Tools > Codec Information.

Here’s a VLC screenshot relative to a video I’ve succesfully uploaded to video.scanlines.xyz. As you see, the codec h264 is being used. It’s not necessarily the best option but it’s a widely used one (and the default one when recording with OBS as I do).

more notes:

I just used youtube-dl to download your video, and I got a 1920x1080 file, encoded with hevc / h265, 14" long.

I’m a bit ignorant about this, and I expected h265 to be currently well supported by main web browers but…it looks that’s not the case at all. Compare
HEVC/H.265 video format | Can I use... Support tables for HTML5, CSS3, etc vs. "h264" | Can I use... Support tables for HTML5, CSS3, etc

I’d suggest you try again encoding in h264.

Check out our thread about ffmpeg. There’s an entry about h264 there. Also, we may want to update it with some notes about h265 support…

It is H.265 compressed without sound.
Screenshot_20201223_173129

I am using this bash script to compress a image sequence:
#!/bin/bash
timestamp=$(date +%s)
ffmpeg -framerate 25 -pattern_type glob -i ‘ana_*.png’ -vcodec libx265 video-$timestamp.mp4

Tryed to upload a H264 video today. But run problems with login:

When i have figured out how to log back into videos.scanlines.xyz i will try to upload a H.264 video.

For H.264 i use a similar ffmpeg script.

The H.264 compressed video can be played. In my workflow, I first create hundreds of lossless compressed PNGs. Then I use ffmpeg to convert those series of images into a video format. Possibly several times because of pixel details or size …

But that can’t be avoided. If I record with a screen recorder directly while the animation is running, the details are lost.

Live streaming of glitch effects is not possible for me because i live in the hinterland. Using a very slow connection.