Details
-
Bug
-
Resolution: Out of scope
-
Not Evaluated
-
None
-
6.7.0
-
None
-
MacOS arm64
Description
Steps to reproduce:
- Run mictest.py
- Press record
- Talk into microphone
- Press record to stop
- Play sound file stored under ~/Music; check if sound is audible
Hello! So basically, when trying out the new WindowCapture feature on a QMediaCaptureSession, no audio works
So to be clear, I am able to record a screen capture alright, there's just no audio from my microphone which I set as the audio input
When using camera video capture instead of window capture, both video and audio work fine
Is this a bug? How do I get audio input to work while doing a window capture?
Example snippet:
self.captureSession = QMediaCaptureSession() self.windowCapture = QWindowCapture() windows = QWindowCapture.capturableWindows() for win in windows: print(win.description()) if "YouTube" in win.description(): self.windowCapture.setWindow(win) self.windowCapture.start() self.captureSession.setWindowCapture(self.windowCapture) self.captureSession.setAudioInput(self.m_audio) # This line seems to do nothing when using WindowCapture self.captureSession.setRecorder(self.m_mediaRecorder) self.m_mediaRecorder.record() // record for a bit self.windowCapture.stop() self.m_mediaRecorder.stop()
// resulting video has no sound, how do I fix that to either get sound from the window, or from my Microphone?