Is it possible to mix several threads into one using modules?

Hello, everybody! Need to know if it is possible to mix several rtmp threads into one using modules? By Picture-in-Picture type, or simply there is a main stream, and additional streams add sound. It’s the mixing that I need so that all the streamers can be heard at the same time.

I need to see if that’s possible in principle, so I don’t have to spend time on investigating if that’s not possible. And what skills does a specialist need to have in order to create a module like this?

I’m primarily interested in PiP.

PiP with Wowza is a challenge, because there’s no good solution for merging two videos, except via heavy customization of the transcoder process, and it requires the original streams to have same frame rate, etc. It would be better if you can do PiP before you send the stream to Wowza.

Not sure if you are talking about PiP or about audio mix. Do you mean to mix multiple audio tracks into a single (mono or stereo) track, or do you want an output stream with multiple audio choices? Or do you mean video PiP?

PiP with Wowza is a challenge, because there’s no good solution for merging two videos, except via heavy customization of the transcoder process, and it requires the original streams to have same frame rate, etc. It would be better if you can do PiP before you send the stream to Wowza.

Audio mix is a totally different question. It’s not simple either; during the transcoding process you can get the raw audio samples and store them in buffers, then mix them manually or with a 3rd party library and add the mixed samples to the output stream.

I see, PiP is complicated in implementation, and what about the situation when there is a main thread and there are additional threads, but only sound is needed from them. And you only need to mix the sound streams.