Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by ByteSheep · Feb 27, 2013 at 03:26 AM · audionetworkqualitymic

Sending Microphone Input over Network

There seems to be very little on the web regarding sending your mic input to another client over a network. This is a link I found on the unity forum.. The script rooch84 posted was pretty helpful and I have managed to setup the connection between the server and client, as well as successfully record/send the audio from the mic input to the other client.

This is great however the audio quality isn't very good; it makes your voice "sound like a robot".
When recording the mic input directly to an audio source and playing it back afterwards the sound is fine (without sending it through a network)..

So my question is does anyone know how to improve the script or where I can find a tutorial on this subject? The current script I am using seems to be:
• Recording the mic input to an audio source
• Reading the audio clip from the audio source component frame by frame
• and finally sending that data during each frame through an RPC to the other client

This does leave the audio on the other clients side sounding "choppy" though :( Has anyone had this problem before and what did you do to fix it?

If you know more about this it's be great if you contribute because there really doesn't seem to be much on this subject on the web yet - Perhaps someone would like to make a tutorial ;)
Thanks for the help!

Comment
Add comment · Show 4
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ByteSheep · Feb 28, 2013 at 04:27 AM 0
Share

Anyone? ;)

avatar image whydoidoit · Feb 28, 2013 at 04:37 AM 0
Share

Have you checked locally whether playing back the encoded/decoded byte array is crackly?

avatar image ByteSheep · Feb 28, 2013 at 04:41 AM 0
Share

Oh good idea, I hadn't thought of that yet :) I've tested the mic but that was without the encoding/decoding.. I will test this without the network and see what the quality is like when playing back on the same device.

avatar image ByteSheep · Feb 28, 2013 at 05:00 AM 0
Share

Ok, I turned the RPC function into a regular function and called it each frame.. The audio quality is slightly improved, however it still is more crackly than when recording a full audio clip with the mic and then playing it back.
Is there a way to increase the amount of times that the data from the audio clip is sampled to create a less crackly recording?
P.s. On a side note; hertz is a measurement for frequency (i.e. how many times per second), but what exactly does it mean if the frequency is at 44100khz?
It can't be how many times per second my computer is reading the data from my mic. I am guessing the frequency is referring to how quickly the recorded sound waves are vibrating i.e. the pitch.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by Ahisical · Feb 28, 2013 at 04:19 PM

Check out the asset store, there is a new package that allows speech over network.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image avidProgrammer · Jan 18, 2017 at 02:36 PM 0
Share

What is the name of the package?

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

12 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

AudioClip sync across a network: help needed! 0 Answers

Playing Audio Over Network -1 Answers

Get the device audio volume 0 Answers

Network Audio. Why doesnt max distance work over network? 0 Answers

Getting Real-Time Continuous Audio from the Mic 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges