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

Implementation for WebRTC based Video Calling #47

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

HarshNarayanJha
Copy link
Contributor

@HarshNarayanJha HarshNarayanJha commented Nov 8, 2024

This PR implements simple WebRTC based Video Calls. When in a chat, click the attachment button at the top (limited UI design right now), this sends a call request on the other side, showing an incoming call banner with accept and decline buttons. Declining just dismisses the banner (no events sent over, probably a good idea to add one)

Accepting starts sending a series of events to exchange offers, answers, and setups local cameras on both sides. All that event handling is added to the src/hooks/useWebRTC.tsx hook. Reconnections and Hangups are still left to be implemented.

Newly added client events are:

REQUEST_VIDEO_CALL = 'request_video_call',
DECLINE_INCOMING_CALL = 'decline_incoming_call',
END_VIDEO_CALL = 'end_video_call',
SEND_OFFER = 'send_offer',
SEND_ANSWER = 'send_answer',
SEND_CANDIDATE = 'send_candidate',

The VideoChat component is also pretty limited UI.

Related Backend PR: Suyious/purrr.backend#14

Closes #12

Copy link

netlify bot commented Nov 8, 2024

👷 Deploy request for purrrchat pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 512283e

Copy link

vercel bot commented Nov 8, 2024

@HarshNarayanJha is attempting to deploy a commit to the suyious' projects Team on Vercel.

A member of the Team first needs to authorize it.

@HarshNarayanJha HarshNarayanJha marked this pull request as draft November 8, 2024 06:21
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.

video calling feature
1 participant