Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Midiman Audiophile 2496: App output format (Linux) (Read 3098 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Midiman Audiophile 2496: App output format (Linux)

Hi there!

I got an Audiophile 2496 in my computer. I dualboot, that's how I got to know foobar2000.

In the fb2k setup you can choose the output format. It seems that 24bit padded to 32bit is the preferred setting for my card.

Now, if this helps to improve the sound, should I use something like it in Linux, too? I tried with
Code: [Select]
mplayer -format s{24,32}le some.ogg
.

alsalib doesn't accept s24le, just s16le and s32le. And mplayer doesn't have an option for 24bit padded to 32bit.


Anyone with the knowledge to clear that up for a non-techie?



Thanks!


mic

Midiman Audiophile 2496: App output format (Linux)

Reply #1
Most Linux players will send 16 bit data to the soundcard for 16 bit material and 24 bit data for 24 bit marterial. Where the soundcard's native format differs from what an application sends, ALSA converts to the target format. On my card, playing 24 bit material, mplayer sends 24 bit samples to ALSA and ALSA sends S32_LE data to the card (which is the only format the ICE1712 supports).

You can force the format that ALSA sends to the sound card by editing your .asoundrc. I recommend you do this with KAsound, if you have KDE.

Midiman Audiophile 2496: App output format (Linux)

Reply #2
Quote
Most Linux players will send 16 bit data to the soundcard for 16 bit material and 24 bit data for 24 bit marterial. Where the soundcard's native format differs from what an application sends, ALSA converts to the target format. On my card, playing 24 bit material, mplayer sends 24 bit samples to ALSA and ALSA sends S32_LE data to the card (which is the only format the ICE1712 supports).

You can force the format that ALSA sends to the sound card by editing your .asoundrc. I recommend you do this with KAsound, if you have KDE.
[a href="index.php?act=findpost&pid=338049"][{POST_SNAPBACK}][/a]


Thanks!

I ran a few tests with aplay and a wav file and it seems in the end s32_le is used when I choose the default pcm device. aplay tells me it's using 24 msbits. So I think that means 24 bits per sample and therefore it's not really s32_le but 24bits padded to 32bits like in fb2k.

I actually use an ~/.asoundrc file that sets up the softvol plugin. But I wrote it in a way that it still uses the default plughw pcm device that is provided by alsa, so I don't have to specify s32_le (checked that with aplay also).

In case you're interested:

Code: [Select]
pcm.softvol {
       type softvol
       slave {
          pcm "plughw:0,0"
          }
       control {
          name PCM
          card 0
          }
}


I'm just wondering because in the fb2k case the media player itself changes the format to s32_le (24 bit padded to 32 bit anyway). And because people write about not needing to dither when using s32_le I asked myself if I should somehow tell mplayer and other players to do the same.

I'm not sure on this one, yet :-)

I mean fb2k uses my direct sound device. The way I see it the direct sound device is something like ALSA. So I assume that direct sound also changes the format to s32_le. And then why does fb2k have anything to do with changing the format if direct sound does it anyway?

If there's a point doing the format conversion in fb2k it should also be valid for other players, even in Linux.

Probably I just don't get it (admittedly I know very little about this format business).


If you guys could be so kind to clear that up I'll be happy :-)


Thanks


mic

 

Midiman Audiophile 2496: App output format (Linux)

Reply #3
Quote
I'm just wondering because in the fb2k case the media player itself changes the format to s32_le (24 bit padded to 32 bit anyway). And because people write about not needing to dither when using s32_le I asked myself if I should somehow tell mplayer and other players to do the same.
[a href="index.php?act=findpost&pid=338078"][{POST_SNAPBACK}][/a]
Dither is extremely unlikely to have an audible effect when applied once to 32bit or 24bit data.
Quote
I mean fb2k uses my direct sound device. The way I see it the direct sound device is something like ALSA. So I assume that direct sound also changes the format to s32_le. And then why does fb2k have anything to do with changing the format if direct sound does it anyway?[a href="index.php?act=findpost&pid=338078"][{POST_SNAPBACK}][/a]
Is there an audible difference between playing 16 bit data directly and extending to 24 (or 32) bits  then playing?

Midiman Audiophile 2496: App output format (Linux)

Reply #4
Quote
Quote
I'm just wondering because in the fb2k case the media player itself changes the format to s32_le (24 bit padded to 32 bit anyway). And because people write about not needing to dither when using s32_le I asked myself if I should somehow tell mplayer and other players to do the same.
[a href="index.php?act=findpost&pid=338078"][{POST_SNAPBACK}][/a]
Dither is extremely unlikely to have an audible effect when applied once to 32bit or 24bit data.
Quote
I mean fb2k uses my direct sound device. The way I see it the direct sound device is something like ALSA. So I assume that direct sound also changes the format to s32_le. And then why does fb2k have anything to do with changing the format if direct sound does it anyway?[a href="index.php?act=findpost&pid=338078"][{POST_SNAPBACK}][/a]
Is there an audible difference between playing 16 bit data directly and extending to 24 (or 32) bits  then playing?
[a href="index.php?act=findpost&pid=338125"][{POST_SNAPBACK}][/a]



Not to me

I should've kept my mouth shut, what do I know about the differences between the Linux and Windows sound systems anyway?!


Thanks for helping me!



Cheers


mic