While capturing the screen, can we mix in microphone input? Taking that further, is it possible to capture from camera at the same time?
Is it possible to simultaneously record from microphone and camera?
You would use multiple different APIs for this purpose. For both microphone and camera input, you could use AVCapture
, and then use ScreenCaptureKit's synchronizationClock
to make sure everything is synched. Alternatively, something like AVAssetWriter
should handle synchronization automatically.
I see the same error getSubtractiveDecodeDuration signalled err=-16364 (kMediaSampleTimingGeneratorError_InvalidTimeStamp) (Decode timestamp is earlier than previous sample's decode timestamp.)
occasionally. Most of the time using AVAssetWriter seems to work fine. @LiYanan04818 did you ever figure out a solution