33

I ran my application and I can't get the sound working on the Android Emulator. I checked and enabled the audio playback boolean in the Eclipse AVD Manager. I also went into the sound options in the Android Emulator and put them up (no sound while putting them up). I checked the box that says all selections will make a noise(still no sound).

My application uses the MediaPlayer class and I am running win7 x64 if that has anything to do with it.

Help is appreciated.

Vivek Kalkur
  • 2,206
  • 2
  • 20
  • 40
user947659
  • 2,271
  • 4
  • 20
  • 22
  • A possible solution: https://stackoverflow.com/a/63433663/5765771 – Al Mamun Aug 16 '20 at 06:05
  • For me this worked https://stackoverflow.com/a/68392331/3636099 change hw.audioInput=yes hw.audioOutput=yes – Murali Mar 27 '22 at 11:09
  • Really dumb but for some reason focusing on the Android Virtual Devices window worked for me (and nearly gave me a heart attack) – Ryker Apr 27 '22 at 21:47

8 Answers8

32

For OS X the Android Emulator uses the settings for "Sound Effects" so this is what I had to do to fix my issue:

  1. Click the Apple icon in the top left, then click on System Preferences
  2. Click on Sound
  3. Click on "Sound Effects"
  4. Set "Play sound effects through" to "Selected sound output device"
  5. Set the Alert volume almost at max.

Somehow this had changed to use my monitors instead.

Torre Lasley
  • 7,115
  • 3
  • 23
  • 12
  • 21
    Do this settings *before* you start your avd. – einsA Nov 30 '16 at 15:47
  • Where is System Preferences? Is that in the emulator or somewhere Android Studio? – The Unknown Dev Mar 11 '17 at 03:29
  • It is located under the Apple menu in the top left. I updated my answer to clarify. – Torre Lasley Mar 16 '17 at 05:24
  • 2
    All my sound settings were already at max (even the ones described in this answer) for months, even restarting my mac and the emulator (even using new ones) and restarting android studio, the media sound in the emulator is still mute or almost inaudible... – Isan Campos Jan 20 '21 at 20:04
  • 1
    Did not work in macOs monterey. Tried this with the emulator off, cold booted it. No sound. Anyone have any steps from the past year or so that work? – Matthew Goodwin Mar 30 '22 at 17:13
15

In Ubuntu 16.04, start the emulator and go to the Ubuntu → System Settings → Sound → Applications. Uncheck the mute checkbox and set the cursor at the middle position.

Serge Stroobandt
  • 24,143
  • 8
  • 98
  • 91
doruMarinau
  • 161
  • 1
  • 3
  • I am on OpenSUSE Tumbleweed and I didn't have qemu-system-x86_64 at all. The cause appeared to be in Android Studio - the one installed from Snap was having this problem. When I downloaded it and ran the downloaded version - only then I had qemu... in pulseaudio GUI and had sound from emulator. – pesho hristov Feb 11 '21 at 18:38
7

The solution on Ubuntu 16.04 consists in going to the System Settings → Sound → Application tab.

Then, unmute the Qemu-system … and increase the volume

enter image description here

Serge Stroobandt
  • 24,143
  • 8
  • 98
  • 91
user3821178
  • 194
  • 3
  • 13
  • 3
    Where is this screen in Ubuntu 20? I don't see Qemu system anywhere in the System/Settings/Sound screen. – August Oct 28 '20 at 18:39
  • I am on OpenSUSE Tumbleweed and I didn't have qemu-system-x86_64 at all. The cause appeared to be in Android Studio - the one installed from Snap was having this problem. When I downloaded it and ran the downloaded version - only then I had qemu... in pulseaudio GUI and had sound from emulator. – pesho hristov Feb 11 '21 at 18:34
  • For those who are lost, try to run emulator from cmd, like -> ./emulator -avd my_emulator_name. This Qemu System will show in sound settings. – Luciano Brum Jun 22 '21 at 17:52
2

On Debian 8 , you should open qemu-system after android emulator launching enter image description here

cui cui
  • 71
  • 5
  • I am on OpenSUSE Tumbleweed and I didn't have qemu-system-x86_64 at all. The cause appeared to be in Android Studio - the one installed from Snap was having this problem. When I downloaded it and ran the downloaded version - only then I had qemu... in pulseaudio GUI and had sound from emulator. – pesho hristov Feb 11 '21 at 18:31
1

my apps working fine with sound suddenly it stop sound because of some code changed. all other app sound also stopped then i did below step now it is fine

try below

go to android emulator 1.close the program 2.setting -> sound -->volumes ->increase sound value in music video games and other media it will work

sujan
  • 11
  • 1
1

On On Kubuntu , you should increase the playback stream of qemu-system after android emulator launching enter image description here

0

I had the same problem : in a terminal, type pavucontrol (when emulator is running) and another application using sound, that works, is running too (on pause).

Check if quemu-system and the other application use the same soundcard... In my case, this was the problem :quemu system was using a non working internal soundcard.

-8

Try pressing F6. I had a hard time to figuring this out.

p.s.w.g
  • 141,205
  • 29
  • 278
  • 318
Lune
  • 213
  • 1
  • 3
  • 13