How to use the recordrtc.StereoAudioRecorder function in recordrtc

To help you get started, we’ve selected a few recordrtc examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ralscha / blog / speechsearch / client / src / app / home / home.page.ts View on Github external
headers,
            method: 'POST',
            body: recordedBlob
          };
          const response = await fetch(`${environment.serverUrl}/uploadSpeech`, requestParams);
          const searchTerms = await response.json();
          this.movieSearch(searchTerms);
      });
  }
      this.isRecording = false;
    } else {
      this.isRecording = true;
      const stream = await navigator.mediaDevices.getUserMedia({video: false, audio: true});
      const options = {
        mimeType: 'audio/wav',
        recorderType: RecordRTC.StereoAudioRecorder
      };
      this.recorder = RecordRTC(stream, options);
      this.recorder.startRecording();
    }
  }
github AASHISHAG / DeepSpeech-API / frontend / src / app / app.component.ts View on Github external
successCallback(stream) {
        var options = {
            mimeType: "audio/wav",
            numberOfAudioChannels: 1
        };
        //Start Actuall Recording
        var StereoAudioRecorder = RecordRTC.StereoAudioRecorder;
        this.record = new StereoAudioRecorder(stream, options);
        this.record.record();
    }
github quanglam2807 / translatium / src / state / pages / home / speech / actions.js View on Github external
navigator.getUserMedia({ audio: true, video: false }, (stream) => {
        recorder = new RecordRTC(stream, {
          recorderType: RecordRTC.StereoAudioRecorder,
          type: 'audio',
          audioType: 'audio/wav',
          mimeType: 'audio/wav',
          sampleRate: 44100,
          numberOfAudioChannels: 1,
        });

        recorder.setRecordingDuration(DURATION).onRecordingStopped(() => {
          dispatch(stopRecording());
        });

        recorder.startRecording();
      }, () => {
        dispatch(openAlert('cannotActivateMicrophone'));

recordrtc

RecordRTC is a server-less (entire client-side) JavaScript library that can be used to record WebRTC audio/video media streams. It supports cross-browser audio/video recording.

MIT
Latest version published 4 years ago

Package Health Score

64 / 100
Full package analysis