initLocalCameraStream method

Future<void> initLocalCameraStream()

Implementation

Future<void> initLocalCameraStream() async {
  try {
    var hasCameraPermission = await _hasCameraPermission();
    if (!hasCameraPermission) {
      return;
    }

    var hasMicrophonePermission = await _hasMicrophonePermission();
    if (!hasMicrophonePermission) {
      return;
    }

    await _initLocalCameraStream();
  } catch (e) {
    webRtcLogs.fire(WebRtcLoggerEvent(
        loggerType: LoggerType.exception,
        message: e.toString(),
        className: runtimeType));
  }
}