RecordRTC example (and other examples) doesn't work on iOS 12
See original GitHub issueExpected Behavior
Record audio multiple times.
Current Behavior
Recording audio is possible only 4 times. On 5th try there is an alert with error.
Failure Information
null is not an object (evaluating 'context.createMediaStreamSource')
Steps to Reproduce
- Open https://www.webrtc-experiment.com/RecordRTC/ using iOS 12 (or any other example like https://www.webrtc-experiment.com/RecordRTC/simple-demos/audio-recording.html ).
- Use default recording parameters.
- Click on “Start recording” and “Stop recording” 4 times.
- On 5th try you will see an error.
Context
- Operating System: iOS 12.1.4
- Browser: latest Safari
Screenshot
Issue Analytics
- State:
- Created 5 years ago
- Comments:11
Top Results From Across the Web
Audio+Video+Screen Recording using RecordRTC
I am using web RTC audio recorder. It works great on all browsers on PCs and all browsers on Android. It does not...
Read more >Guide to WebRTC with Safari in the Wild (Chad Phillips)
Chad Phillips provides a detailed list of Safari caveats and gotcha's for WebRTC developers ranging from media capture, device management, ...
Read more >180748 – Audio sometimes fail to capture in WebRTC
On an iPad, go to https://webrtc.github.io/samples/ 2. Select sample "Audio-only getUserMedia() output to local audio element" 3.
Read more >Recording video in Safari using WebRTC or RecordRTC
It seems that safari doesn't support MediaRecorder by default, so we can't record video by using webRTC or RecordRTC .
Read more >Media Capture and Streams - W3C
This specification does not specify any such cases, but other specifications using the MediaStream API may. One such example is the WebRTC ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

@Tayyaba03 I went to PROJECT_FOLDER/node_modules/recordrtc/RecordRTC.js and applied this instead of lines 2879-2890 (RecordRTC version is 5.5.4):
This is not a good approach, because there is also RecordRTC.min.js that may probably be used for production bundle creation. What is more, “npm install” command may remove these temporary changes. So it is better to use pull request directly (https://stackoverflow.com/questions/33181297/npm-install-from-github-pull-request) or wait @muaz-khan to update the library. But for my current development purpose it works like a charm.
Hi everyone, I had exactly the same issue with my project.
@thaihau the example audio-recording.html mentioned by @alexbazilev use StereoAudioRecorder on Safari browser which is working well, except the context problem which is limiting the number of uses.
I managed to solve this by using RecordRTC.Storage within StereoAudioRecorder, so the audio context can be closed when calling RecordRTC.destroy().
I created a pull request for this : https://github.com/muaz-khan/RecordRTC/pull/504