video showing on one end
This commit is contained in:
@@ -42,8 +42,8 @@
|
|||||||
[
|
[
|
||||||
"@electron-forge/plugin-webpack",
|
"@electron-forge/plugin-webpack",
|
||||||
{
|
{
|
||||||
"port": "4001",
|
"port": "4000",
|
||||||
"loggerPort": "9001",
|
"loggerPort": "9000",
|
||||||
"mainConfig": "./webpack.main.config.js",
|
"mainConfig": "./webpack.main.config.js",
|
||||||
"devContentSecurityPolicy": "default-src * self blob: data: gap:; style-src * self 'unsafe-inline' blob: data: gap:; script-src * 'self' 'unsafe-eval' 'unsafe-inline' blob: data: gap:; object-src * 'self' blob: data: gap:; img-src * self 'unsafe-inline' blob: data: gap:; connect-src self * 'unsafe-inline' blob: data: gap:; frame-src * self blob: data: gap:;",
|
"devContentSecurityPolicy": "default-src * self blob: data: gap:; style-src * self 'unsafe-inline' blob: data: gap:; script-src * 'self' 'unsafe-eval' 'unsafe-inline' blob: data: gap:; object-src * 'self' blob: data: gap:; img-src * self 'unsafe-inline' blob: data: gap:; connect-src self * 'unsafe-inline' blob: data: gap:; frame-src * self blob: data: gap:;",
|
||||||
"renderer": {
|
"renderer": {
|
||||||
|
|||||||
@@ -447,6 +447,8 @@ function Room({
|
|||||||
audio: true,
|
audio: true,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
console.log(localMediaStream);
|
||||||
|
|
||||||
setUserLocalStream(localMediaStream);
|
setUserLocalStream(localMediaStream);
|
||||||
|
|
||||||
// ?will there be race condition where this room component is rendered but we don't have the latest
|
// ?will there be race condition where this room component is rendered but we don't have the latest
|
||||||
@@ -460,8 +462,6 @@ function Room({
|
|||||||
);
|
);
|
||||||
toast.success('calling bunch of people');
|
toast.success('calling bunch of people');
|
||||||
|
|
||||||
setUserLocalStream(localMediaStream);
|
|
||||||
|
|
||||||
// for each person, create peer object
|
// for each person, create peer object
|
||||||
allOtherUserIds.forEach((otherUserId) => {
|
allOtherUserIds.forEach((otherUserId) => {
|
||||||
const connectingToast = toast.loading('calling peer for a snappy experience');
|
const connectingToast = toast.loading('calling peer for a snappy experience');
|
||||||
@@ -643,7 +643,7 @@ function Room({
|
|||||||
|
|
||||||
// find our local connection to this peer in the room contents
|
// find our local connection to this peer in the room contents
|
||||||
setConversationMap((draft) => {
|
setConversationMap((draft) => {
|
||||||
const localPeerForMasterAndMe = draft[res.lineId]?.room[res.lineId];
|
const localPeerForMasterAndMe = draft[res.lineId]?.room[res.masterUserId];
|
||||||
|
|
||||||
if (localPeerForMasterAndMe) {
|
if (localPeerForMasterAndMe) {
|
||||||
localPeerForMasterAndMe.peer.signal(res.simplePeerSignal);
|
localPeerForMasterAndMe.peer.signal(res.simplePeerSignal);
|
||||||
@@ -655,7 +655,7 @@ function Room({
|
|||||||
$ws.removeAllListeners(mastersAnswerReceivedChannelNameForRoom);
|
$ws.removeAllListeners(mastersAnswerReceivedChannelNameForRoom);
|
||||||
$ws.removeAllListeners(someoneJoinedChannelNameForRoom);
|
$ws.removeAllListeners(someoneJoinedChannelNameForRoom);
|
||||||
};
|
};
|
||||||
});
|
}, [userLocalStream]);
|
||||||
|
|
||||||
// go through all of the peers and destroy and update conversation map
|
// go through all of the peers and destroy and update conversation map
|
||||||
useUnmount(() => {
|
useUnmount(() => {
|
||||||
|
|||||||
Reference in New Issue
Block a user