Open nguyenxuankiet262 opened 2 months ago
You have to add the right to have sound either the video result won't have sound.
You have to add the right to have sound either the video result won't have sound.
Hi! I just run the basic example and I allowed microphone permission.
When i switch to video camera and record in the first time, the video will have sound. Then i switch to photo camera and switch to video camera again, the next recorded video will have no sound.
You can try my steps
It's an urgent bug
Btw, your lib is very awesome
If anyone get this issue, update below codes and it'll work
- (void)setCaptureMode:(CaptureModes)captureMode error:(FlutterError * _Nullable __autoreleasing * _Nonnull)error {
NSLog(@"setCaptureMode");
if (_videoController.isRecording) {
*error = [FlutterError errorWithCode:@"CAPTURE_MODE" message:@"impossible to change capture mode, video already recording" details:@""];
return;
}
_captureMode = captureMode;
if (captureMode == Video) {
// [self setUpCaptureSessionForAudioError:^(NSError *audioError) {
// *error = [FlutterError errorWithCode:@"VIDEO_ERROR" message:@"error when trying to setup audio" details:[audioError localizedDescription]];
// }];
}
}
Steps to Reproduce
Expected results
The video must have sound