0.1.7 • Published 5 months ago

expo-audio-streaming v0.1.7

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

expo-audio-streaming

This module is designed to play dynamic audio streams and record audio streams from the microphone. It's an ideal solution for apps that require real-time audio processing and streaming capabilities.

Disclaimers

Early Stage Development

Please note that this package is in its early stages of development. It has not been extensively tested across all environments and use cases. Users should integrate this package into their projects at their own risk.

iOS-Only Support

Currently, expo-audio-streaming supports iOS only. Future updates are planned to extend support to Android platforms. Feel free to contribute.

API documentation

Example Usage

Refer to the example folder to see how the player and recorder are utilized in a practical scenario. It is recommended to directly use the useRecorder and usePlayer hooks provided in the example. (useRecorder.tsx, usePlayer.tsx)

Using the Player

Integrating the audio player into your application is straightforward. Here's a basic example:

const { addToBuffer, play, pause, playing } = usePlayer();

// Use these methods to control the audio player

Using the Recorder

Similarly, incorporating the audio recorder is just as simple. Here's a quick guide:

const { start, stop, recording, buffer } = useRecorder({
  onNewBuffer: (event) => event.buffer,
});

// 'buffer' will be the base64 representation of your audio stream

Installation in managed Expo projects

For managed Expo projects, please use this command:

npx expo install expo-audio-streaming

Installation in bare React Native projects

For bare React Native projects, you must ensure that you have installed and configured the expo package before continuing.

Add the package to your npm dependencies

npm install expo-audio-streaming

Configure for iOS

Run npx pod-install after installing the npm package.

Configure for Android

Contributing

Contributions are very welcome! Please refer to guidelines described in the contributing guide.

0.1.7

5 months ago

0.1.6

5 months ago

0.1.5

5 months ago

0.1.4

5 months ago

0.1.3

5 months ago

0.1.2

5 months ago

0.1.1

6 months ago

0.1.0

6 months ago