codimd icon indicating copy to clipboard operation
codimd copied to clipboard

[feature] video-embedding: youtube-alternative "invidious"; federated video hosting "PeerTube"; HTML5 video support -- support for other video providers than the "big players".

Open dreirund opened this issue 3 years ago • 2 comments

If there is youtube-embedding implemented via {%youtube <youtube-video-id> %} syntax, I suggest that there is also added support for privacy-friendly youtube mirrors like iteroni.com.

And I also suggest embedding possibility of "fediverse"-PeerTube, a federated video hosting software.

Thus not to provide only embedding for the big commercial ones.

Other suggestion (which should work with any place where the video file's URL is directly accessible) would be if a file format that the browser can play directly can be embedded in a way that generates the necessary HTML5-structures so that direct in-browser play is offered. This would be a general solution for many circumstances (not youtube).

dreirund avatar Apr 21 '21 06:04 dreirund

With a little bit of code you can include any video source.

In my case I do that (due to privacy) to include videos from OwnCloud/Nextcloud into CodiMD pads.

That is the code I use for that:

<video poster="/apps/files_videoplayer/img/poster.png" src="https://cloud.elearningdienst.de/index.php/s/5aF2fLB3T3FXNZH/download?.mp4" width="720" controls><source src="https://cloud.elearningdienst.de/index.php/s/5aF2fLB3T3FXNZH/download?.mp4" type="video/mp4"></video>

The ?.mp4 snippet is (in that case) optional the video's MIME/type is included here in the type="video/mp4" snippet.

Here is an small example in a public CodiMD pad: https://eldshort.de/xpzsf6

If that small code snippet (optionally including a MIME/Type detection) will be behind a {%video <publiclink> %} that would be great ;-)

elearningdienst avatar May 10 '21 11:05 elearningdienst

On Mon, 10 May 2021 04:33:07 -0700, elearningdienst @.*> wrote about "Re: [hackmdio/codimd] [feature] video-embedding: youtube-alternative "invidious"; federated video hosting "PeerTube"; HTML5 video support -- support for other video providers than the "big players". (#1673)":

With a little bit of code you can include any video source.

[...]

That is the code I use for that:

<video poster="/apps/files_videoplayer/img/poster.png" src="https://cloud.elearningdienst.de/index.php/s/5aF2fLB3T3FXNZH/download?.mp4" width="720" controls><source src="https://cloud.elearningdienst.de/index.php/s/5aF2fLB3T3FXNZH/download?.mp4" type="video/mp4"></video>

Wow, thank you! -- So I then suggest that this makes it into the documentation in http://hackmd.io/features/.

-- "Sometimes I define a nerd as somebody who thinks that the purpose of communication is to submit your ideas to peer review. And normal people understand that the primary purpose of communication is to negotiate alignment. And these purposes tend to conflict."

-- Joscha Bach

dreirund avatar May 10 '21 12:05 dreirund