Embedding Videos in Markdown with Lupo

While Markdown is a powerful tool for creating content, it doesn't support embedding videos directly. However, with our new tool Lupo, we have a solution that allows you to incorporate videos into your markdown content. By using our cognitive services and background directive, we can take your video and place it as a background for your slides. In this section, we will show you how to use Lupo to create video backgrounds for your markdown content. So, even though Marp and Marpit do not support videos in markdown, we have you covered with our innovative solution. Let's explore how to do it!


External Video

The <video> tag is an HTML5 element that is used to embed videos into a webpage. The src attribute specifies the URL or local path of the video file to be played. Additionally, you can use the controls attribute to include the standard menu control for playing and pausing the video. The loop attribute will cause the video to play in a loop, continuously repeating after it finishes. The muted attribute will cause the video to play without sound.

Syntax

<video src="url or path" loop muted>Your device does not support video playback.</video>

For example:

---
marp: true
theme: customtheme
---

<video src="../universe.mp4" controls class="w-100">Your device does not support video playback.</video>

<!-- 
Welcome to our universe, a vast and wondrous place full of mysteries and surprises.

[[cheerful]] In this video, we will share with you some fun facts about the universe that will blow your mind. So, sit back, relax, and enjoy the show!
-->


Adding Narrations to Videos with Lupo

When creating a video with Lupo, it's important to know that you can place narrations at specific times during the video. This can be achieved by adding parentheses to your narration text, followed by the time in seconds, minutes and seconds, or hours, minutes and seconds, depending on where you want the narration to occur. This way, you can ensure that your narration lines up with the corresponding visual elements on the screen, and create a more cohesive and engaging video experience for your audience.

Audio notes can be located at some specific time within the external videos. You can specify the time using only seconds, minutes and seconds or complete time.

Please ensure that each narration is provided in a single line without line breaks. Use the specified format for the time representation within double parentheses.

*Note: Microseconds are not allowed in the time specification.

((seconds))

((minutes, seconds))

((hours, minutes, seconds))

((1)) Narration at second 1

((1:3)) Narration at 1:03

((1:2:3)) Narration at 1:02:03

For example:

---
marp: true
theme: customtheme
---

<video src="../universe.mp4" controls>Your device does not support video playback.</video>

<!-- 
((5)) Welcome to our universe, a vast and wondrous place full of mysteries and surprises.

((12)) [[cheerful]] In this video, we will share with you some fun facts about the universe that will blow your mind. So, sit back, relax, and enjoy the show!
-->