File recording with MediaMixer and StreamRecorder yields strange .mp4 file (video after audio) #1869
Unanswered
GitUserMarkus
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Question
I use ReplayKit to capture the screen of my iOS app and feed the CMSampleBufferRefs provided by startCaptureWithHandler into a MediaMixer. Attaching a RTMPStream as output, everything works as expected (you can watch the stream online). However, using a StreamRecorder as output to the MediaMixer (or the stream), the created output mp4-file has the following strange conditions: If played, e.g. in iMovie, it starts with the audio only (full length of original recording session) without any video visible. Afterwards, the video-content is played but without any sound. So it seems that for whatever reason, both media types are not interleaved but are concatenated one after the other within the mp4.
Any ideas how to fix this? All hints are very welcome.
Many thanks in advance!
Background / Tried Steps
It might be helpful information for experts that I have made the following observation: If starting ReplayKit's capturing a user is asked to allow video grabbing and audio recording. If only allowing video, the RTMP-streaming still works (video can be viewed online) but no mp4-file is created at all.
No response
Environment
No response
Beta Was this translation helpful? Give feedback.
All reactions