Would this be doable with mediasoup?

Hello there! I was thinking of making myself a nice little project with mediasoup but wanted to see
if it was really possible what I was thinking.

Every user should be a producer so they will send the stream to the server.
Then when someone goes near a other user (or multiple) the other users will consume his stream.
Same other way around, so the other users are also producing and he also consumes their stream.
But when one user walks away he still needs be a producer but obviously there should be no consumers and he shouldnt be a consumer anymore of the other people.

Thanks in advance.

Please read the mediasoup API documentation. Of course your scenario can be implemented, but as you may understand mediasoup doesn’t care about who is close or far to others, so that’s up to your application logic.

1 Like

Oh yeah it was just an example with the close or far to eachother. I already made that and only need mediasoup to connect the people! Really nice to hear that this is possible and thanks for the quick answer.

I think the following project could give you some inspiration: https://github.com/Crowd-Wire/ProjectDocumentation

At least I believe what they’ve built is similar to what you described.

Ahh thank you, I’ll look into that.