Sound tinkering

For test results, bug reports, announcements of new builds etc.

Moderators: winston, another_commander, Getafix

User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Sound tinkering

Post by Ponder »

Now I don't know if this is Oolite or the fact I've finally gone from OSS to ALSA but sound seems a bit choppy after today's rsync.

Has the sound code been tinkered with?

For example, the Witchspace Fuel Injector sound appears to loop following a quick decay to silence.
Image
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

The sound code has not been changed for months. It's probably your setup - more specifically, since you're building from source (or using the nightly) rather than the autopackage, it's most likely due to having older SDL libraries (especially since you mentioned moving from OSS to ALSA - the mainstream was using ALSA almost three years ago).

If your distro is a bit old, and doesn't have recent SDL libraries, you can always download the latest SDL source and build it (then make sure that the dynamic linker finds the newest version first). You can always try the Autopackage first since this bundles up known good SDL libraries.

The SDL libraries supplied with distros circa Fedora Core 2 had sound 'choppiness' problems (various things like clicking noises, bad latency, broken up sounds). These went away as soon as SDL was updated to the latest version.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

Yeah, I did suspect it may be due to this.

I'll look into getting the latest SDL libs tomorrow, after all, this solved the Windows problem :-)

* Edit: Couldn't wait. Swapped sdl-oss for sdl-alsa and installed a bunch of other alsa and sdl related stuff to no effect. Downloaded, built and installed latest sdl, no effect. Got latest dev autopackage, no effect.

BTW, my distro is Debian Sarge (3.1) Stable.

You mentioned making sure the dynamic linker finds the correct version, I'm at a loss to do this so can you point the way please? :)

Going to bed now, too tired to work on this any more ;)
Image
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

Go into the oolite.app directory then

ldd oolite

This will tell you exactly what libraries it's trying to link to. It's quite possibly trying to link to the SDL libs that come with Sarge rather than the new ones you built. You can set LD_LIBRARY_PATH to change this (or modify /etc/ld.so.conf) and make sure /usr/local/lib (or wherever you put the newer library versions) is first. If you modify /etc/ld.so.conf you'll need to run ldconfig after doing so.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

Well it's definitely using the newer libs:

babylon5:/usr/lib/Oolite/oolite.app# ldd oolite
libGLU.so.1 => /usr/X11R6/lib/libGLU.so.1 (0x4002b000)
libGL.so.1 => /usr/lib/libGL.so.1 (0x400a6000)
libSDL-1.2.so.0 => /usr/lib/libSDL-1.2.so.0 (0x4011f000)
libpthread.so.0 => /lib/tls/libpthread.so.0 (0x401c5000)
libSDL_mixer-1.2.so.0 => /usr/lib/libSDL_mixer-1.2.so.0 (0x401d4000)
libSDL_image-1.2.so.0 => /usr/lib/libSDL_image-1.2.so.0 (0x40244000)
libgnustep-base.so.1.12 => not found
libobjc.so.1 => not found
libm.so.6 => /lib/tls/libm.so.6 (0x40260000)
libc.so.6 => /lib/tls/libc.so.6 (0x40282000)
libstdc++.so.5 => /usr/lib/libstdc++.so.5 (0x403b7000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x40471000)
libGLcore.so.1 => /usr/lib/libGLcore.so.1 (0x4047a000)
libnvidia-tls.so.1 => /usr/lib/tls/libnvidia-tls.so.1 (0x40bcb000)
libXext.so.6 => /usr/X11R6/lib/libXext.so.6 (0x40bce000)
libX11.so.6 => /usr/X11R6/lib/libX11.so.6 (0x40bdc000)
libdl.so.2 => /lib/tls/libdl.so.2 (0x40ca3000)
libasound.so.2 => /usr/lib/libasound.so.2 (0x40ca6000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
libvorbisfile.so.3 => /usr/lib/libvorbisfile.so.3 (0x40d59000)
libvorbis.so.0 => /usr/lib/libvorbis.so.0 (0x40d61000)
libogg.so.0 => /usr/lib/libogg.so.0 (0x40d89000)
libsmpeg-0.4.so.0 => /usr/lib/libsmpeg-0.4.so.0 (0x40d8e000)
libtiff.so.4 => /usr/lib/libtiff.so.4 (0x40de7000)
libjpeg.so.62 => /usr/lib/libjpeg.so.62 (0x40e37000)
libpng12.so.0 => /usr/lib/libpng12.so.0 (0x40e55000)
libz.so.1 => /usr/lib/libz.so.1 (0x40e7a000)

But sound is still weird. Restarted ALSA with no effect. Now I'm totally lost.

It's not spoiling my enjoyment of the game but it's something I'd like to get working properly ;)
Image
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

Well, switch back to OSS is really the only thing I can suggest. Have you checked that SDL is configured to use ALSA not OSS? (Otherwise it'll be using the OSS emulation in ALSA). There is a way to configure this at runtime, but I'm sorry - I've forgotten how it's done.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

ALSA has too many good points to go back to using OSS so I guess I'll live with it for now.

I've removed all traces of OSS from the installed packages and it's definitely got the ASLA Options installed. Really not sure which way to go now.

If anyone has any ideas please don't be afraid to mention them :)
Image
User avatar
winston
Pirate
Pirate
Posts: 731
Joined: Mon Sep 27, 2004 10:21 pm
Location: Port St. Mary, Isle of Man
Contact:

Post by winston »

Yes. Switch to Ubuntu. It's debian based, but much more up to date (and the laptop I use for testing oolite on runs Ubuntu; my main development system runs Fedora Core 5). IMHO, Debian is what you want to run on servers rather than desktops - but that's just IMHO.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

This is my server, that's why it's running Debian :-)

Being a Sempron 2200+ with 80GB HD space and 1GB RAM is a bit of overkill though, and as I had a spare TFT monitor due to a new purchase I decided to use it as a workstation too.
Image
eddyp
Competent
Competent
Posts: 63
Joined: Tue May 02, 2006 2:44 pm

Post by eddyp »

Could you try the "semi official" Debian packages?
eddyp
Competent
Competent
Posts: 63
Joined: Tue May 02, 2006 2:44 pm

Post by eddyp »

eddyp wrote:
Could you try the "semi official" Debian packages?
Oh, wait, you are running Debian Sarge, right?

I will have to backport the package, in that case.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

Yes, Sarge on a Sempron 2200+ (i686).

I won't hold my breath on a new release getting only the apt-list though, it's still on KDE 3.3.4 ;)
Image
eddyp
Competent
Competent
Posts: 63
Joined: Tue May 02, 2006 2:44 pm

Post by eddyp »

Ponder wrote:
Yes, Sarge on a Sempron 2200+ (i686).

I won't hold my breath on a new release getting only the apt-list though, it's still on KDE 3.3.4 ;)
And it will stay like that. That is the Debian way of dealing with the stable releases.

I was talking about an unofficial package.
User avatar
Ponder
Dangerous
Dangerous
Posts: 64
Joined: Fri Mar 31, 2006 2:03 pm
Location: Cardiff, UK

Post by Ponder »

I know, I'm prepared to put up with it because it's mainly a server, but I wish they'd at least make some progession with KDE, its datedness is causing many other compilation dependency problems.
Image
eddyp
Competent
Competent
Posts: 63
Joined: Tue May 02, 2006 2:44 pm

Post by eddyp »

Ponder wrote:
I know, I'm prepared to put up with it
That's why I said I should backport the package ;-)
Post Reply