# I made a video call app (with 15-second ping)

**URL:** <https://forum.delta.chat/t/i-made-a-video-call-app-with-15-second-ping/2800>\
**Category:** Mini Apps\
**Created:** [November 16, 2023, 1:19pm UTC](https://forum.delta.chat/t/i-made-a-video-call-app-with-15-second-ping/2800 "2023-11-16T13:19:18Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![WofWca](https://forum.delta.chat/user_avatar/forum.delta.chat/wofwca/32/1702_2.png) [@WofWca](https://forum.delta.chat/u/WofWca)\
**Post date:** [November 16, 2023, 1:19pm UTC](https://forum.delta.chat/t/i-made-a-video-call-app-with-15-second-ping/2800/1 "2023-11-16T13:19:18Z")

</div>

Another giant leap for mankind. A webxdc app for actual video calls over actual email (albeit with 15-second ping (but [it may improve soon](https://github.com/deltachat/deltachat-core-rust/pull/4904))).

> **[GitHub - WofWca/video-call-over-email: No cap. With 15-second ping though.](https://github.com/WofWca/video-call-over-email/)**
>
> No cap. With 15-second ping though.

 ![A simplistic video call app UI](https://support.delta.chat/uploads/default/original/2X/3/335afb0a3a394408b65f2475a724b530aafdcf82.jpeg)

This is just a prototype.

## Usage

Unfortunately, as of 2023-11-16, sending audio/video **won’t work** on unmodified versions of Delta Chat, but [this may change](https://support.delta.chat/t/allow-access-to-camera-geolocation-other-web-apis/2446) in the near future.

_Receiving_ video does work on regular Delta Chat.  
If you don’t want to bother modifying Delta Chat — hit me up, I’ll show you the app in action.

### Modifying Delta Chat

Below are instructions on how to modify Delta Chat. But make sure **not to launch any webxdc apps** that you don’t trust on the modified version of Delta Chat as it is **insecure**. Tested on Delta Chat 1.40.4.

1. Download [Delta Chat Desktop](https://delta.chat/).

2. Find the `DeltaChat/resources/app.asar` file in the app folder.

3. Open it as a ZIP file.

4. Open the `tsc-dist/main/deltachat/webxdc.js` file inside the archive.

5. Find the line

6. Save the modified app.asar file.

7. After you’re done playing around with this app, make sure to remove the line you added, or simply reinstall Delta Chat.

### Running the app

1. Launch Delta Chat.
2. Build an `.xdc` file with `./create-xdc.sh`, or just [download it from the “Releases” section](https://github.com/WofWca/video-call-over-email/releases/latest/download/webxdc-video-call.xdc).
3. Send the `.xdc` file to a chat.
4. Wait for some other chat members to launch the app.
5. Press “Start sending my media”; or just wait for others to send theirs.

Keep in mind that video data takes a lot of space. Make sure not to waste the storage quota on your email server. The expected bitrate in this app for audio + video is ~50 MB / hour per member and ~2 MB / hour per member for just audio.

## Why

Because it’s funny.

And it might actually become an actually useful video call app, when:

- [the ratelimit](https://github.com/deltachat/deltachat-core-rust/blob/212751f173139aab3daadcd77388b3551004cabe/src/context.rs#L382) gets much better than 1 email per 10 seconds
- webxdc apps can be [allowed camera permission](https://support.delta.chat/t/allow-access-to-camera-geolocation-other-web-apis/2446)
- A way is found to not fill up email servers with audio/video data (maybe something like “ephemeral webxdc messages”)

## How it works

Nope, it’s not WebRTC.

1. Record 10 seconds of your camera stream with a [`MediaRecorder`](https://developer.mozilla.org/en-US/docs/Web/API/MediaStream_Recording_API).
2. Serialize the data.
3. Send it over email (with [`webxdc.sendUpdate()`](https://docs.webxdc.org/spec/sendUpdate.html)).
4. Repeat from step 1.

When we receive data, deserialize it and display it using [Media Source Extensions API](https://developer.mozilla.org/en-US/docs/Web/API/Media_Source_Extensions_API).

## Web demo (no email involved)

If you just want to see how the app feels, without actually communicating with anyone using email, go to [https://wofwca.github.io/video-call-over-email/](https://wofwca.github.io/video-call-over-email/) .

---

_[View the full topic](https://forum.delta.chat/t/i-made-a-video-call-app-with-15-second-ping/2800)._
