It is currently Fri May 16, 2025 2:06 pm

All times are UTC - 8 hours [ DST ]




Post new topic Reply to topic  [ 6 posts ] 
Author Message
Offline
 Post subject: KGS Linux sound issue
Post #1 Posted: Sun Apr 24, 2011 3:44 pm 
Lives with ko
User avatar

Posts: 269
Location: Seattle
Liked others: 127
Was liked: 123
Rank: AGA 12k
GD Posts: 292
KGS: RedBeard
DGS: Akahige
I have a dilemma. I am using Debian with Pulseaudio. I am trying to record some KGS lectures with RecordMyDesktop. When I start KGS, it shows in the pulse audio control panel as a OSS-compatible stream and I can record a game with all of the stone clicks and chimes recorded in sync. When I try to record a lecture, the sound effects come through but the lecture audio does not.

Is the lecture audio using a different driver than the sound effects audio? I have tried this by appending both "aoss" and "padsp" to the command to launch KGS. The only thing I have not tried is running the whole thing through JACK.

Any clues or suggestions?

Top
 Profile  
 
Offline
 Post subject: Re: KGS Linux sound issue
Post #2 Posted: Sun Apr 24, 2011 4:12 pm 
Lives in sente

Posts: 852
Location: Central Coast
Liked others: 201
Was liked: 333
Rank: KGS [-]
GD Posts: 428
Admittedly it's been a few years since I've run a linux box so I'm not sure if it will apply to you, but perhaps this link might be helpful? -- http://kgsfaq.free.fr/index.php?action= ... artlang=en

Top
 Profile  
 
Offline
 Post subject: Re: KGS Linux sound issue
Post #3 Posted: Sun Apr 24, 2011 6:09 pm 
Lives in gote

Posts: 355
Liked others: 52
Was liked: 43
Rank: AGA 2d
IGS: ethanb
Redbeard wrote:
I have a dilemma. I am using Debian with Pulseaudio. I am trying to record some KGS lectures with RecordMyDesktop. When I start KGS, it shows in the pulse audio control panel as a OSS-compatible stream and I can record a game with all of the stone clicks and chimes recorded in sync. When I try to record a lecture, the sound effects come through but the lecture audio does not.

Is the lecture audio using a different driver than the sound effects audio? I have tried this by appending both "aoss" and "padsp" to the command to launch KGS. The only thing I have not tried is running the whole thing through JACK.

Any clues or suggestions?


Pulseaudio is somehow simultaneously one of the coolest things to happen on the Linux audio backend in years, and one of the most frustrating pieces of software ever. Mostly it's not Pulse's fault though, at least on my computer - usually Adobe Flash is to blame.

I recommend closing all web browsers (and checking to make sure there aren't any nsplugin or java plugin threads that got orphaned somehow; it's never happened to me, but I really don't trust Flash, and I've seen Java steal the sound card before too.)

Follow that up with a "pulseaudio --kill" and IMMEDIATELY startup whatever you're doing that isn't playing sound properly. Immediately as in click on the icon before you get your prompt back, if at all possible. That should reset everything, and allow KGS or whatever to grab the sound card.

Hope that helps. I'm just waiting for YouTube to finish going HTML5 and/or Lightspark to become good enough that I can throw away adobe-flashplugin, and then I anticipate many fewer problems.

Another possibility that just occurred to me is that KGS may be opening a second stream for the audio - look at the client list once the lecture starts and see if there are two OSS clients instead of just one.

Top
 Profile  
 
Offline
 Post subject: Re: KGS Linux sound issue
Post #4 Posted: Sun Apr 24, 2011 6:23 pm 
Tengen

Posts: 4382
Location: Caldas da Rainha, Portugal
Liked others: 499
Was liked: 733
Rank: AGA 3k
GD Posts: 65
OGS: Hyperpape 4k
ethanb wrote:
Hope that helps. I'm just waiting for YouTube to finish going HTML5 and/or Lightspark to become good enough that I can throw away adobe-flashplugin, and then I anticipate many fewer problems.
In Mac circles, there's a nice trick going around that I think should also work on Linux or Windows. Google Chrome comes bundled with a copy of Flash that's distinct from the copy that other browsers use. You can then delete the systemwide/standalone version. Many sites will detect that your browser doesn't have Flash, and serve you html5 video, even if they'd normally serve Flash (as mobile grows, more websites are willing to show you something other than Flash, even if it's not their first choice). When you have to use Flash, you just load the URL in Chrome.

_________________
Occupy Babel!

Top
 Profile  
 
Offline
 Post subject: Re: KGS Linux sound issue
Post #5 Posted: Mon Apr 25, 2011 10:49 am 
Lives in gote
User avatar

Posts: 450
Location: Portland, OR USA
Liked others: 257
Was liked: 287
KGS: wms
I don't know anything about recordmydesktop, and very little about the current state of audio in general, but yes the sound effects and the audio stream are done through different mechanisms so they may be treated differently by the audio drivers.

Top
 Profile  
 
Offline
 Post subject: Re: KGS Linux sound issue
Post #6 Posted: Sun May 15, 2011 5:36 pm 
Lives with ko
User avatar

Posts: 269
Location: Seattle
Liked others: 127
Was liked: 123
Rank: AGA 12k
GD Posts: 292
KGS: RedBeard
DGS: Akahige
After spending an inordinate amount of time on this, I have been able to come up with a cause and work around. I always like to follow-up with the solution when I ask for help on forums for the sake of people looking for answers in the future (Hello future people! Greeting from the past!), so please bear with me.

It appears that Java 6 and pulseaudio do not like to play well together with the Audigy audio card I am using (module emu10k1). Even when starting java and javaws with pulseaudio by appending the padsp command (ie. padsp javaws path/to/KGS/client) Java will only play midi sounds through pulseaudio. Other sound formats are played directly through the preferred alsa/oss device, regardless of pulseaudio cofig.

In most situations, this probably does not cause a problem. However, since Java uses an oss driver for sound output, in order to get RecordMyDesktop to work I need to push everything through pulseaudio. This is why I could hear the stone click (midi) but not the lecture (sound file). I discovered this with the Java Sound Demo program. The "juke box" files would play through the sound card, but not get picked up in the RecordMyDesktop session. The midi and "grove box" files would play through the sound card and get recorded in the RMD capture file.

So, my work around is to remove the SB soundcard from the loop and use a USB headset instead. When I am ready to record the lecture I have to:

  • plug in the USB headset
  • kill the pulseaudio daemon
  • unload the kernel modules for the Audigy audio card (turning off the Audigy in pulseaudio alone did not work)
  • restart pulseaudio
  • start KGS with pulseaudio
  • start RecordMyDesktop with pulseaudio.

Once this is done the USB headset is the only sound device on my system. All of the sound coming from KGS is pushed through the USB driver and pulseaudio passes it to RMD. It may be a bit of overkill but it seems to work. This also may only be an issue with the emu10k1 Linux module, but I do not have access to a different sound card that I can try.

With all of this in mind I was able to record my class lecture today in glorious OGG format and don't have to beg those snooty Apple users for a copy of their nasty old MOV files. Hooray! :D


This post by Redbeard was liked by 3 people: judicata, pasky, wms
Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group