Commit f790ee7
authored
feat(react): Support for Background Filters and Background Blurring (#1283)
Adds API for registering video filters, default plugin based on TensorFlow Lite, and a sample integration in our Demo app.
**New APIs:**
- `camera.registerFilter(async (mediaStream) => mediaStream)` the core
part. It allows you to chain multiple video and audio filters.
- `@stream-io/video-filters-web` - a new lib that is responsible for the
ML part and WebGL rendering
- `BackgroundFiltersProvider` - a component in the React SDK that helps
you to manage the applied filters.
Our dogfooding app integrates these new APIs and provides the necessary input (background images) and styling.
### Notes
Because of our deployment setup, this PR contains the changes done as part of #1271 and #1276 :)1 parent 67c738e commit f790ee7
File tree
88 files changed
+4941
-341
lines changed- .github/workflows
- packages
- client
- docusaurus/docs/javascript/02-guides
- src
- devices
- __tests__
- gen/coordinator
- helpers
- store
- react-bindings
- react-native-sdk
- react-sdk
- docusaurus/docs/React
- 02-guides
- 10-advanced
- src/components
- BackgroundFilters
- styling
- src/BackgroundFilters
- video-filters-web
- src
- helpers
- webgl2
- tf
- models
- tflite
- sample-apps
- client/ts-quickstart
- react-native
- dogfood
- expo-video-sample
- react
- audio-rooms
- cookbook-participant-list
- egress-composite
- livestream-app
- messenger-clone
- react-dogfood
- components
- Settings
- hooks
- pages/join
- public
- backgrounds
- tf
- models
- tflite
- style
- CallControls
- stream-video-react-tutorial
- zoom-clone
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
88 files changed
+4941
-341
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
50 | 52 | | |
51 | 53 | | |
52 | 54 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
| 29 | + | |
29 | 30 | | |
30 | 31 | | |
31 | 32 | | |
| |||
51 | 52 | | |
52 | 53 | | |
53 | 54 | | |
54 | | - | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
55 | 58 | | |
56 | 59 | | |
57 | 60 | | |
| |||
70 | 73 | | |
71 | 74 | | |
72 | 75 | | |
73 | | - | |
74 | | - | |
| 76 | + | |
| 77 | + | |
75 | 78 | | |
76 | 79 | | |
77 | 80 | | |
Lines changed: 43 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
251 | 294 | | |
252 | 295 | | |
253 | 296 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
| 13 | + | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
15 | 17 | | |
16 | 18 | | |
17 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
47 | | - | |
48 | | - | |
| 47 | + | |
| 48 | + | |
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
33 | 34 | | |
34 | 35 | | |
35 | 36 | | |
| |||
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
| 52 | + | |
| 53 | + | |
51 | 54 | | |
52 | 55 | | |
53 | 56 | | |
54 | 57 | | |
| 58 | + | |
55 | 59 | | |
56 | 60 | | |
57 | 61 | | |
| |||
509 | 513 | | |
510 | 514 | | |
511 | 515 | | |
512 | | - | |
513 | | - | |
514 | | - | |
515 | | - | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
516 | 520 | | |
517 | 521 | | |
518 | 522 | | |
| |||
1582 | 1586 | | |
1583 | 1587 | | |
1584 | 1588 | | |
| 1589 | + | |
| 1590 | + | |
| 1591 | + | |
| 1592 | + | |
| 1593 | + | |
| 1594 | + | |
| 1595 | + | |
| 1596 | + | |
| 1597 | + | |
| 1598 | + | |
| 1599 | + | |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
| 1609 | + | |
| 1610 | + | |
| 1611 | + | |
1585 | 1612 | | |
1586 | 1613 | | |
1587 | 1614 | | |
| |||
1859 | 1886 | | |
1860 | 1887 | | |
1861 | 1888 | | |
| 1889 | + | |
| 1890 | + | |
| 1891 | + | |
| 1892 | + | |
| 1893 | + | |
| 1894 | + | |
| 1895 | + | |
| 1896 | + | |
| 1897 | + | |
| 1898 | + | |
| 1899 | + | |
1862 | 1900 | | |
1863 | 1901 | | |
1864 | 1902 | | |
| |||
0 commit comments