1. Hey Guest, is it this your first time on the forums?

    Visit the Beginner's Box

    Introduce yourself, read some of the ins and outs of the community, access to useful links and information.

    Dismiss Notice

Problem to listen kag sound AND other sound

Discussion in 'Help' started by Zelkatshi, Nov 13, 2018.

Mods: makmoud98, Mazey
  1. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    Hello, i have problem, when i launch KAG (i'm Linux user), it's impossible for example to listen music with firefox, KAG block other sound output. Is it possible to change that ?
     
  2. Same problem in win10
     
  3. Furai

    Furai THD Team THD Team Administrator

    Messages:
    3,124
    That's a first...

    So it's hogging audio device for itself? Was it always like that or is it some recent change?
     
  4. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    Always. But it's the first time i repport this bug.
     
  5. vik

    vik THD Team THD Team Tester

    Messages:
    51
    Hmm.. in the windows preferences for sound devices there's always an option to allow apps to take over exclusive rights of that device. As far as I know KAG doesn't do it anwyay but you could try that. In Linux I don't know, there are many possible combinations of sound card, driver etc
     
    Blubahub likes this.
  6. Furai

    Furai THD Team THD Team Administrator

    Messages:
    3,124
    For linux it could be cork pulseaudio plugin detecting KAG wrongly as communication software. Just a wild guess. Try installing pavucontrol/alsamixer and checking sound output volumes there. Also in system sound applet per each application running. Do you see other applications muted?
     
    Blubahub likes this.
  7. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    That or for some reason KAG is somehow claiming the ALSA device for your speakers than just using the pulseaudio ALSA mixer. Did you ever touch such settings?
     
    Blubahub likes this.
  8. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    It's the same problem with other applications. And i have already checked volume in alsamixer, but all is in max. And i use pulseaudio.
     
  9. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    Does KAG show up in pavucontrol? Does anything odd happen in pavucontrol when KAG starts up?
     
  10. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    No, KAG isn't showing
     
  11. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    Yeah, sounds like KAG is claiming the entire sound card through ALSA for some reason instead of going through pulse. It could be due to bad defaults on your end maybe? What distro?
    We don't have much control over what happens under the hood because IrrKlang abstracts it. I wouldn't be surprised if it just did something weird.
     
  12. Furai

    Furai THD Team THD Team Administrator

    Messages:
    3,124
    Try playing with this setting in autoconfig.cfg:
    Code:
    s_system = 0  # Sets the sound system (0 autodetect; 1 DirectSound 8; 2 DirectSound; 3 Win MM; 4 ALSA; 5 Core Audio; 6 No sound.
    
    Still, no pulseaudio option. The autodetect thing should just work.
     
  13. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    I have Gentoo Linux.

    I have this setting, but i have again this problem. I have trying to set 4 for alsa, but the same problem, other sound application don't work if i don't stop kag.
     
  14. Furai

    Furai THD Team THD Team Administrator

    Messages:
    3,124
    Can you show me how it looks in the sound applet? Screenshot the tab showing application sounds when KAG is running? Do you run the game via Steam or standalone?
     
  15. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    You should check your ALSA defaults so the default is the pulse output then. This way KAG audio will go through the pulseaudio daemon and back to your speakers through its ALSA output.
    The reason is that (without dmix, etc.) only one process can access a hardware ALSA output at a time. If KAG tries to claim the ALSA hardware output directly then only either pulseaudio either KAG can use it, not both.
    I am not sure why would only KAG be affected by this issue on your end, but firefox for example uses pulseaudio directly by default (without going through the ALSA pulse output).
     
  16. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
  17. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    This is what I have on my arch linux box in /etc/asound.conf :
    Code:
    # Use PulseAudio by default
    pcm.!default {
      type pulse
      fallback "sysdefault"
      hint {
      show on
      description "Default ALSA Output (currently PulseAudio Sound Server)"
      }
    }
    
    ctl.!default {
      type pulse
      fallback "sysdefault"
    }
    
    # vim:set ft=alsaconf:
    Do you have anything similar in /etc/asound.conf? If not, backup that file and try copy pasting what I have here.

    You will not find options for this in KDE. The sound applet is a pulseaudio sound applet, it does not manage ALSA stuff.

    Just in case I will explain it over in french to make sure there is not a misunderstanding (better answer in english in forums though)
    // Le soucis n'est pas du côté de pulseaudio à priori mais de ALSA. Il faut qu'ALSA soit configuré pour utiliser par défaut la sortie pulse et non de tes hauts parleurs. Si KAG essaie d'utiliser la sortie des hauts parleurs directement via ALSA alors pulseaudio ne pourra plus l'utiliser et donc plus générer de son.
    --- Double Post Merged, Dec 12, 2018, Original Post Date: Dec 12, 2018 ---
    Also before trying that out since you are running Gentoo, make sure that you have this alsa-plugin USE flag set for pulseaudio and have media-plugins/alsa-plugins installed as described here:
    https://wiki.gentoo.org/wiki/PulseAudio#Global

    I am not familiar with Gentoo though.
     
  18. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    I have coppied your setting file, now it's okay, when i use kag and other sound, for example firefox, it's work together !

    But now i have other problem, just sound system don't work. For example, when i remove file to trash, system don't play any sound ...
     
  19. Asu

    Asu THD Team THD Team Forum Moderator

    Messages:
    1,580
    No idea about that one. Try to tweak audio settings in the KDE control panel.
     
  20. Zelkatshi

    Zelkatshi Shark Slayer

    Messages:
    14
    Asu likes this.
Mods: makmoud98, Mazey