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: Need A Wma Lossless Decoder For Streaming (Read 9062 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Need A Wma Lossless Decoder For Streaming

hello, I am looking for a command line WMA lossless decoder for my netjukebox that can decode to stdout. I've found a decoder on the MS's site (wmal2pcm.exe), but it only decodes to a file

Need A Wma Lossless Decoder For Streaming

Reply #1
You might try the slimserver's wmadec:

wmadec

Need A Wma Lossless Decoder For Streaming

Reply #2
wmadec produces data that isn't really useful :/. If I run
Code: [Select]
wmadec -o test.wav test.wma
, then the resulting file test.wav cannot be played in foobar2000 or winamp and cannot be encoded by oggenc . It can be "opened" in wavelab, but it offers a "special file format" dialog, which then makes a mono wave that sounds ok.

Need A Wma Lossless Decoder For Streaming

Reply #3
It would have been more helpful if I included some options:

try

wmadec -o test.wav -r 44100 -b 16 -n 2 test.wma

Need A Wma Lossless Decoder For Streaming

Reply #4
with your options it's the same (the parameters are default anyway). Do you have a link to the wmadec sources?

Need A Wma Lossless Decoder For Streaming

Reply #5
yes, the sources are here

Need A Wma Lossless Decoder For Streaming

Reply #6
OK thx, I'll take a look at them

Need A Wma Lossless Decoder For Streaming

Reply #7
I just saw a bug report about wmadec - that all the output is in mono. This seems to be related to some recent changes. Apparently an an older version of wmadec works fine for one person. Maybe you can give that a try? Sorry for the trouble.

Need A Wma Lossless Decoder For Streaming

Reply #8
this version works better, wavelab reads the output as raw data and it's stereo then. But the output .wav file is rather raw data than PCM WAV, it's missing the header (lame and oggenc fail to compress it correctly). I'll try to modify the source so that the headers get attached (just copy them from a real .wav file or maybe take code from LAME).

EDIT: I've modded wmadec to accept -w as a parameter and write the wave header when set (code taken from LAME), here is a link for those who are interested: http://home.arcor.de/superlexx/files/wmadec.zip . It contains the new wmadec.cpp and the binary.

Need A Wma Lossless Decoder For Streaming

Reply #9
Thanks (again) Superlexx 

 

Need A Wma Lossless Decoder For Streaming

Reply #10
I have been using the GBPVR video/music center along with the hauppage MVP 1000 for accessing the content over the network.

One piece that is missing is the ability to stream WMA since it needs to be converted to MP3.

From reading this post it sounds as though wmadec will decode the wma file and we could then using something like LAME to create the MP3.  Is this correctg?

Also....it wasn't clear in the post as to if there was in fact a bug in wmadec that was only producing mono output.  Was the altered code you provided above a fix for this problem?

Need A Wma Lossless Decoder For Streaming

Reply #11
My modification is based on the 0.5.3 branch that didn't have the mono bug

Wmadec can decode the WMA for LAME encoding like "wmadec -w input.wma | lame - -"

Need A Wma Lossless Decoder For Streaming

Reply #12
Thanks Superlexx.....I am checking with one of the plugin developers fof GBPVR to see if this can be integrated into the My Music plugin.

Need A Wma Lossless Decoder For Streaming

Reply #13
Quote
My modification is based on the 0.5.3 branch that didn't have the mono bug

Wmadec can decode the WMA for LAME encoding like "wmadec -w input.wma | lame - -"
[a href="index.php?act=findpost&pid=280552"][{POST_SNAPBACK}][/a]


I am trying to run wmadec and I keep getting the following error message:

Opening stream failed with error code 0x80070002

What would a valid command line look like if I have a file named test.wma?

Thanks.

Need A Wma Lossless Decoder For Streaming

Reply #14
Code: [Select]
D:\bin\codec>wmadec -w test.wma | lame - test.mp3
LAME version 3.96 MMX  (http://www.mp3dev.org/)
CPU features: MMX (ASM used), 3DNow! (ASM used), SSE
Using polyphase lowpass filter, transition band: 17249 Hz - 17782 Hz
Encoding <stdin> to test.mp3
Encoding as 44.1 kHz 128 kbps j-stereo MPEG-1 Layer III (11x) qval=3
If you use "-" instead of "test.mp3", lame will output into stdout instead of a file.

Need A Wma Lossless Decoder For Streaming

Reply #15
Thanks.....I hate to say it but my only error was not to use the correct name of my input file.....I was using the song title as the name when in fact it was actually named 02 trackname.wma....

Need A Wma Lossless Decoder For Streaming

Reply #16
Hi,

I've updated wmadec so it can passthrough the length of decoded data, it must be provided like "wmadec -l 12345 test.wma | ..." where 12345 is length in bytes. Then the length will be written into the WAV header, making tools that hang in the pipe work better.

download (sources and the binary)