@cloudflare/realtimekit-virtual-background 0.0.2-staging.1 → 0.0.2-staging.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/README_DEV_HELP.md +0 -33
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudflare/realtimekit-virtual-background",
|
|
3
|
-
"version": "0.0.2-staging.
|
|
3
|
+
"version": "0.0.2-staging.2",
|
|
4
4
|
"description": "A Package that allows ease of use for RealtimeKit's video middlewares",
|
|
5
5
|
"main": "./dist/index.cjs.js",
|
|
6
6
|
"module": "./dist/index.es.js",
|
package/README_DEV_HELP.md
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
### How it is made?
|
|
2
|
-
|
|
3
|
-
We are using https://github.com/Volcomix/virtual-background (Demo: https://volcomix.github.io/virtual-background/) WebGL pipeline for Chrome & Firefox, whereas using 2d canvas rendering pipeline for Safari and other such Webkit based browsers.
|
|
4
|
-
|
|
5
|
-
Commit at which RealtimeKit has branched from this repo is: `99dfe4a912573a1440236a9762dcb415b86d216a`, of main branch.
|
|
6
|
-
|
|
7
|
-
We have 2 pipelines because WebGL pipeline is performant whereas 2d Canvas rendering is comparatively not performant, however 2d canvas rendering based pipeline is able to draw to canvas even when tab is backgrounded in Safari which is not the case with WebGL thus making WebGL pipeline useless in Safari once user's tab is backgrounded.
|
|
8
|
-
|
|
9
|
-
There are very minimal changes made to the core of Volcomix repo. If you want to check the difference between our files and theirs, diff can be checked at https://www.diffchecker.com/. We have kept the file names mostly the same for ease of use.
|
|
10
|
-
|
|
11
|
-
We have mostly ignored the linting in Volcomix repo files to ensure minimum diff if we ever want to import more changes. React code was stripped to ensure compatibility with all JS frameworks.
|
|
12
|
-
|
|
13
|
-
Repo's tflite models are hosted at `https://dyte-plugins.s3.ap-south-1.amazonaws.com/tf-assets/models/*`.
|
|
14
|
-
|
|
15
|
-
### Caveats
|
|
16
|
-
|
|
17
|
-
1. For WebKit based browsers, we would be using 2d canvas rendering instead of webgl because Safari doesn't support WebGL canvas rendering in the backgrounded tab.
|
|
18
|
-
|
|
19
|
-
2. For local development, please uncomment the following line in index.html.
|
|
20
|
-
```
|
|
21
|
-
<!-- <script type="module" src="/src/index.ts"></script> // For local -->
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
And comment out the following.
|
|
25
|
-
|
|
26
|
-
```
|
|
27
|
-
<script src="./dist/index.iife.js"></script>
|
|
28
|
-
```
|
|
29
|
-
|
|
30
|
-
This was done so that the repo could be deployed to Vercel without any issues.
|
|
31
|
-
|
|
32
|
-
If you don't want to change index.html, you will have to perform `npm run build` after every code change.
|
|
33
|
-
|