# [audio] problem with xine

## niin

Until now I used an alsa module compiled out of the kernel, and everything was fine. But now I tried to compile the kernel with built-in alsa module (I unmerged alsa-driver), but it seems that some audio codecs are not working on xine. I noticed that I can read AC3, but no other codec. By the way, mp3 is working fine on Beep MP, and I can read any video on mplayer. I tried to re-compile xine-lib and xine-ui but nothing has changed, and I'd really like to make it work, it's really annoying.

Thank You.

----------

## taipan67

Is it anything like the as-yet unresolved problem i posted about on this thread? If so, i'd like to keep tabs on your progress, in case it helps me...  :Wink: 

My problem cropped up again a couple of days ago on a rental copy of 'Hitch' (the Will Smith movie). It seems to be something to do with dts-soundtracks.  :Confused: 

I'm now running kde instead of gnome, & 'kaffeine' has the same problem as 'totem' & 'xine-ui', so it would appear to be a 'xine-lib' issue - but to-date i haven't gotten to the bottom of it...

Your thoughts, & anyone else's, would be appreciated, & of course i'll certainly let you know if i make any progress (it's been on the back-burner for a while...  :Embarassed:  ).

----------

## niin

Well I've just tried to launch a dvd on xine and it didn't work at all ; xine just crashed, as mplayer did. I tried as root, but the same thing happened :/

----------

## taipan67

 *niin wrote:*   

> Well I've just tried to launch a dvd on xine and it didn't work at all ; xine just crashed, as mplayer did. I tried as root, but the same thing happened :/

 

Didn't they output any error-messages, at all..?  :Shocked: 

How about if you start each player from the command-line? If they crash, the xterm/console ought to list what went on, before it returns to the prompt...

I don't have either player installed at the moment, but a look through the thread i linked to has the command for 'xine' listed as :-

```
xine -p dvd:/4
```

...to go to a specific title on the disc. Typing 'xine --help' would probably display other, more appropriate options.

----------

## niin

there is something weird ; now I can play DVD, it show menus, but when I launch the movie, it freeze, without any error message.

 *Quote:*   

> niin@desktop ~ $ xine
> 
> Voici xine (X11 gui) - un lecteur vidéo libre v0.99.4.
> 
> (c) 2000-2004 L'Equipe de xine.
> ...

 

----------

## taipan67

 *niin wrote:*   

> there is something weird ; now I can play DVD, it show menus, but when I launch the movie, it freeze, without any error message.
> 
>  *Quote:*   niin@desktop ~ $ xine
> 
> Voici xine (X11 gui) - un lecteur vidéo libre v0.99.4.
> ...

 

I'm not sure if this is right, & i'm not sure if it matters, but that output looks like you've mounted the dvd before playing it - you don't need to do that for dvd-movies (or audio-cd's, for that matter).

If your dvd-drive is cdrom1, i'm guessing you have two optical-drives; cdrom0 & cdrom1. Each should be a symlink to the real device - something like /dev/hdc & /dev/hdd, depending on how you connected them up to your motherboard. They both ought to be in the 'cdrom' group, as should your username - i mention this because another thread i saw recently had a drive owned by the 'disk' group, & that was the source of the problem there.

As long as your xine & mplayer configuration-files list one of the symlinks to the correct drive, you should just be able to put a dvd-movie disk in the drive & start playing it...  :Confused: 

----------

## niin

I've mounted the drive because last time i linked on /dev/cdrom1, xine told that the link wasn't good and there was nothing on it. Now I've just tried again and it worked... !!!! So the CSS authentification is clear and the DVD read is good. I don't even know why it didn't work before.

Now for the sound problem on playing video files (avi, wmv, mpeg...), there is no error message on console, but It still can't play audio. Only AC3 works fine and I don't know what is wrong.

----------

## taipan67

 *niin wrote:*   

> ...Now for the sound problem on playing video files (avi, wmv, mpeg...), there is no error message on console, but It still can't play audio. Only AC3 works fine and I don't know what is wrong.

 

As i said before, i'm currently using 'kaffeine', but that still runs on 'xine-lib', so the options should be the same...

I don't seem to be able to break mine.  :Wink: 

I do remember accidentally breaking the audio-output when i was using 'totem' - it's graphical config-menu listed 'Stereo 2.0', 'Surround 5.1', & 'PCM Direct' as options, if memory serves. I tried the latter two to see if my DVD problem would be fixed (it wasn't), then discovered i couldn't change back to 'Stereo 2.0', except by manually editing the config-file stored in my home-directory (different players store them in different sub-directories).

I mention this because i think AC3-passthrough would still work under those circumstances, so maybe the equivalent setting needs altering on your system...  :Confused: 

----------

## niin

As nothing seemed to work with kernel module, i emerged alsa-driver, and now i encounter this problem :

 *Quote:*   

> desktop linux # /etc/init.d/alsasound start
> 
>  * Loading ALSA modules ...
> 
>  *   Loading: snd-card-0 ...                                                           [ ok ]
> ...

 

I first edited the /etc/modules.d/alsa myself and then used alsaconf, but both end with this message. What's up ?

By the way, the sound works, but with xine, only ac3 is played, as for the alsa kernel module.

----------

## taipan67

 *niin wrote:*   

> As nothing seemed to work with kernel module, i emerged alsa-driver, and now i encounter this problem...

 

The thing about using drivers that don't come with the kernel (alsa-drivers, ati-drivers, etc...) is that if you change your kernel in any way, you then have to re-compile the drivers whilst running the kernel they need to work with.  :Evil or Very Mad: 

If you want to use 'alsa-drivers', i think you'll have to build a kernel with nothing but 'soundcore' enabled, boot it, then emerge 'alsa-drivers' while that new kernel's running...

...But, i've always used the drivers from the kernel, so a second-opinion might be advisable...  :Wink: 

----------

## niin

That's how I do it ; before I used to emerge alsa-driver instead of using the kernel driver ; it's since I tried the kernel module that I have some problem  :Sad: 

----------

## taipan67

 *niin wrote:*   

> That's how I do it ; before I used to emerge alsa-driver instead of using the kernel driver ; it's since I tried the kernel module that I have some problem 

 

It might be that the old alsa-modules from the kernel are still in the /lib/modules directory, & are conflicting with the new 'alsa-drivers' modules. To overcome this, you could try the following procedure :-

1. Unmerge 'alsa-drivers' (just to be on the safe side).

2. Rebuild the kernel with just 'soundcore' support, as you did before, BUT change the 'Local version' option in 'menuconfig' to something like "-noalsa" - don't include the quotes, but do include the leading hyphen. This way, when you run 'make && make modules_install', your kernel-modules are installed into a new directory under /lib/modules.

3. Reboot to this new kernel, & 'emerge alsa-drivers' as you have in the past.

The 'Local version' option in 'menuconfig' is the first option in the 'General setup' section.

After you 'cd /usr/src/linux', it's advisable to run 'make clean', so that your old compilation is removed, but your configuration-file is retained. Then, follow the familiar 'make menuconfig ---> make && make modules_install' procedure.

----------

## niin

I did all what you explain and I still get the message

 *Quote:*   

> desktop ~ # /etc/init.d/alsasound start
> 
>  * Loading ALSA modules ...
> 
>  *   Loading: snd-card-1 ...                                              [ ok ]
> ...

 

By the way, I can play sound, but still have the same problem with xine :/

I live in despair by now >_<

----------

## niin

I think I got something new ; in the xine configuration menu, in the "audio" part, there are some settings for audio device :

device.alsa_default_device : default

device.alsa_front_device : default

device.alsa_mixer_name : PCM

device.alsa_passthrough_device : iec958...

device.alsa_surround40_device : plug:surround40:0

device.alsa_surround51_device : plug:surround50:0

So as the AC3 works, i guess it's because the 5.1 device is set correctly, but if mp3, wmv... doesn't work, it's because the default device (for front device (stereo)) isn't well configured. But I don't know what to set instead of "default" so that it would work :/

edit : i used plug:surround40:0 ; it works fine but maybe there is a loss so i don't know if there is a better setting.

----------

