First of all I would like to share that we are now doing over 1 Mn minutes a month in production using this wonderful library, so Kudos to the team for building this tremendous platform. Now here is the challenge we have, how do we change the frame rate of producer while it is on, The use case is that we to decrease the resolution when there are more than a set number of participants in the room so that the CPU utilization does not go up. So if there are 4 people in the room we want the participant to get 1080p, when 5-8 760 and when more than 8 460, we want to do this with out turning off the producers and turning it back on and having to again subscribe to the stream… is there an elegant way to doing it? We are using simulcast and sending multiple streams, while it may not be a bandwidth constraint on the end user computer it is a CPU constraint and thats we want to lower the resolution.
You can have your simulcast configured for the required resolution set and then request to get the particular simulcast layer (mediasoup :: API)
So consumers will receive that specific layer of the entire simulcast set.
I don’t play with anymore than simple, what the broadcaster wants to produce for stream is it, I limit by bitrate and in a test of 12, 24, 48 broadcasts the results for clients CPU are following:
i7-4790K:
13-15% on brave browser (chromium based) for 12 broadcasts, all using VP8/OPUS 500KB/s
25-35% on brave browser (chromium based) for 24 broadcasts, all using VP8/OPUS 500KB/s
50-65% on brave browser (chromium based) for 48 broadcasts, all using VP8/OPUS 500KB/s
Samsung Galaxy S7:
Usage % unknown but it handled a 12 room broadcast no problem.
Usage % unknown but it handled a 24 room broadcast some lag, definitely processor overwhelmed but converted to audio only was fine!.
Not to be mean but hosting in production, I get many users that complain their poop computer can’t use the site… This is ongoing and when I assess the issue further, it turns out they’re trying to run a chrome book in a massive session or some pentium 4 type machine they kept around for 20 years.
A simple upgrade they’ll never complain, if my phone and older processor can keep up it’s the least of my worries.
If you want to absolutely drop the CPU % however, a fun trick would be to run a streamer for all broadcasts, assemble it into a box and send that entire stream as one but it’s major server work.
Subham… this may be the solution, I like Cosmosis Streamer but in our application we want the end users to pick and choose which streams they want to see so may be a bit difficult. My whatsapp number is +1-952-239-3646 would love to chat with you if you got a few minutes.
Thank you and I hear you, peple have older computers and want to run media streaming applications. The challenge is the domain we play in we cant ask the customer to change a few hundred computers…:). I love you idea something we should definitely consider if we can figure out the which consumers the subscriber wants to see and then get streamer on it.
Yes, for individual control which is what I wanted as well I never applied such but it’s an idea for fixed setups or say, if you were doing a twitch/youtube presentation to thousands.