Skip to content

This Unity package provides an example script and scene for recording audio input from a microphone in Unity.

Notifications You must be signed in to change notification settings

DeanAviv/unity-microphone-input-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

Unity Microphone Example

This Unity package provides an example script and scene for recording audio input from a microphone in Unity.

Functionalities

The package provides the following functionalities:

  • Record audio input from microphone
  • Stop recording audio
  • Play recording
  • Clear last recording

Dependencies

To use this package in your Unity project, follow these steps:

  • TMP for the text components and buttons
  • Unity 2019 and above

Installation

To use this package, you can follow these steps:

  • Clone or download this repository to your computer.
  • Open your Unity project and import the package by selecting Assets -> Import Package -> Custom Package from the main menu.
  • Locate the downloaded package file and select it to import.

Usage

After importing the package, you can open the example scene to see how the microphone recording works. The example scene is located in the Scenes folder and is called MicrophoneExample.unity.

The example scene includes a simple user interface that allows you to record, stop, play, and clear the last recording. The example script is attached to a game object called Microphone Controller.

To use the microphone recording functionality in your own project, you can copy the MicrophoneController game object and script to your own scene. You can then customize the script to fit your specific needs.

Inside the package

  • A Unity Audio mixer (Can be used to edit the recording if needed)
  • MicrophoneController.cs - A script with the basic functionalities for recording, pauseing and playing
  • An example scene with UI buttons used for testign functinalities
  • An example prefab for the Microphone Controller handler & Canvas

Credits & Licenss

This package is released under the MIT License, which means it is free for commercial and non-commercial use, modification, and distribution, subject to the following conditions:

The Software is provided "as is," without warranty of any kind, express or implied, including but not limited to the warranties of merchantability, fitness for a particular purpose, and noninfringement. In no event shall the authors or copyright holders be liable for any claim, damages or other liability, whether in an action of contract, tort or otherwise, arising from, out of or in connection with the Software or the use or other dealings in the Software. This means that you can use this package for free in your own projects, modify it to suit your needs, and even distribute it to others. However, please note that the MIT License does not come with any warranty, so use the package at your own risk.

About

This Unity package provides an example script and scene for recording audio input from a microphone in Unity.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages