Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ts-sdk] Make react sdk run on browser #776

Merged
merged 7 commits into from
Oct 25, 2024
Merged

Conversation

noituri
Copy link
Member

@noituri noituri commented Sep 18, 2024

This PR adds bare minimum to make the wasm compositor work with our react sdk. It implements simple queue, mp4 input and canvas output. Not everything is fully implemented (i.e. Input state notifications) but I want to get the feedback early before proceeding further.

@noituri noituri force-pushed the @noituri/wasm-react-instance branch 9 times, most recently from d0b04a1 to 02c0d0a Compare September 25, 2024 15:20
@noituri noituri marked this pull request as ready for review September 25, 2024 15:31
ts/@live-compositor/web/src/compositor.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/fifo.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/input/input.ts Outdated Show resolved Hide resolved
ts/examples/vite-browser-render/src/examples/MP4Player.tsx Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/compositor.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/input/mp4/source.ts Outdated Show resolved Hide resolved
@@ -2,7 +2,8 @@ import * as Api from '../api';

export type RegisterInput =
| ({ type: 'rtp_stream' } & RegisterRtpInput)
| ({ type: 'mp4' } & RegisterMp4Input);
| ({ type: 'mp4' } & RegisterMp4Input)
| { type: 'bytes' };
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bytes is not a valid type, I assume this will be raw frames? in that case frames or raw_frames, frame_bytes

What about audio? Is this video only input?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently, it's only video input

ts/@live-compositor/web/src/compositor.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/manager/wasmInstance.ts Outdated Show resolved Hide resolved
ts/examples/vite-browser-render/src/App.tsx Outdated Show resolved Hide resolved
@noituri noituri force-pushed the @noituri/wasm-react-instance branch 2 times, most recently from 295d574 to f6471eb Compare October 1, 2024 10:53
@noituri noituri requested a review from wkozyra95 October 1, 2024 10:59
@noituri noituri force-pushed the @noituri/wasm-react-instance branch 3 times, most recently from 84100bb to bc13cb0 Compare October 3, 2024 13:41
@noituri noituri force-pushed the @noituri/wasm-react-instance branch 2 times, most recently from bc6a7e6 to 0ad79e0 Compare October 14, 2024 14:02
ts/@live-compositor/web/package.json Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/compositor.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/input/input.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/input/mp4/demuxer.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/input/mp4/demuxer.ts Outdated Show resolved Hide resolved
ts/@live-compositor/web/src/manager/wasmInstance.ts Outdated Show resolved Hide resolved
@noituri noituri force-pushed the @noituri/wasm-react-instance branch 4 times, most recently from 5669878 to bbd5018 Compare October 22, 2024 15:27
@noituri noituri merged commit e2c2372 into master Oct 25, 2024
5 checks passed
@noituri noituri deleted the @noituri/wasm-react-instance branch October 25, 2024 10:17
@WojciechBarczynski WojciechBarczynski removed their request for review October 29, 2024 01:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants