please help me , i have tried some ways but does not work well
You can use ffmpeg to post-process and piece together the different parts of your video with respect to time. Additionally, you can fill in any gaps or silence with your looped image.
could you explain it with more details please
I’m not entirely certain about the scope and scale of your project, but if you’re dealing with videos which might contain extended blank (black) sections, there’s a cost-effective solution worth considering. For instance, if you’re recording a user who only activates their video feed at the beginning and end of a lengthy 2-hour meeting, it might be more efficient to save only those segments. By saving the initial and final minutes as separate files and seamlessly looping your image for the remaining duration, you can effectively piece them together, optimizing storage and resources in the process.
just like @Bdayz said try to :
1- stop ffmpeg process of producer pause (ex. segment-1.mp4)
2- start new ffmpeg process when same producer resumed again (ex. segment-2.mp4)
then end of your recording try to merge this segments and your image with it.
another solution i have for you is that do it client side maybe …
i mean in client-side when peer wants to pause producer actually don’t pause it. just put image in video ( for example in virtual backgrounds) and of resume revert it to normal .
i think you don’t have any other option server-side because mediasoup is a SFU. so you can not modify stream data.
Thank you so much ,
I already proceed this solution.
I also think this is only solution for this issue.