LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices



Reply
 
Search this Thread
Old 09-03-2004, 02:21 PM   #1
lixy
Member
 
Registered: Apr 2004
Posts: 120

Rep: Reputation: 15
Convert wma to ogg


Hey,

Does anyone know some program that converts wma file into ogg format? I've been recently converted to linux and don't like the idea of keeping proprietary files on my HDD;

Thanks,
 
Old 09-03-2004, 02:49 PM   #2
fsbooks
Member
 
Registered: Jan 2002
Location: Missoula. Montana, USA
Distribution: Slackware (various)
Posts: 449

Rep: Reputation: 31
I use a two step process:

mplayer -ao pcm -o fileout.wav filein.wma
oggenc -o freeatlast.ogg fileout.wav
 
Old 07-05-2006, 02:24 PM   #3
rwc_zippy
Member
 
Registered: Jul 2006
Posts: 31

Rep: Reputation: Disabled
Quote:
Originally Posted by fsbooks
I use a two step process:

mplayer -ao pcm -o fileout.wav filein.wma
oggenc -o freeatlast.ogg fileout.wav
YAY! This helped out a ton!

but one addition, I recieved this when I ran that command

Code:
> MPlayer 2:0.99+1.0pre7try2+cvs20060117-0ubuntu8 (C) 2000-2006 MPlayer Team
> CPU: Advanced Micro Devices Sempron/Athlon MP/XP/XP-M Barton,Thorton (Family: 6, Stepping: 0)
> CPUflags:  MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 0
> Compiled with runtime CPU detection.
>
>
> Option -o has been renamed to -vo (video-out), use -vo.
> 91 audio & 204 video codecs
so simple change the command to:

Code:
mplayer -ao pcm -vo fileout.wav filein.wma
happy converting!
 
Old 03-03-2007, 08:07 PM   #4
elsabio
LQ Newbie
 
Registered: Mar 2005
Location: england
Distribution: handbuilt (reliable), FC3 (flakey as a piecrust)
Posts: 9

Rep: Reputation: 0
Unfortunateley, life is not always so simple ...

mplayer -ao pcm -vo 1\ -\ Vespers\ Introit\ Hymn.wav 1\ -\ Vespers\ Introit\ Hymn.wma
MPlayer 1.0rc1-rpm.livna.org-4.1.1 (C) 2000-2006 MPlayer Team
CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 4800+ (Family: 15, Model: 35, Stepping: 2)
CPUflags: MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.

Playing 1 - Vespers Introit Hymn.wma.
ASF file format detected.
Clip info:
name: Vespers (Introit & Hymn)
author: Philip Pickett
copyright: Linn Records
==========================================================================
Requested audio codec family [wma9dmo] (afm=dmo) not available.
Enable it at compilation.
Requested audio codec family [wmadmo] (afm=dmo) not available.
Enable it at compilation.
Cannot find codec for audio format 0x163.
Read DOCS/HTML/en/codecs.html!
Audio: no sound
Video: no video


Exiting... (End of file)
 
Old 12-11-2007, 11:12 PM   #5
hobbes1069
LQ Newbie
 
Registered: Dec 2007
Posts: 4

Rep: Reputation: 0
Quote:
Originally Posted by rwc_zippy View Post
YAY! This helped out a ton!

but one addition, I recieved this when I ran that command

Code:
> MPlayer 2:0.99+1.0pre7try2+cvs20060117-0ubuntu8 (C) 2000-2006 MPlayer Team
> CPU: Advanced Micro Devices Sempron/Athlon MP/XP/XP-M Barton,Thorton (Family: 6, Stepping: 0)
> CPUflags:  MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 0
> Compiled with runtime CPU detection.
>
>
> Option -o has been renamed to -vo (video-out), use -vo.
> 91 audio & 204 video codecs
so simple change the command to:

Code:
mplayer -ao pcm -vo fileout.wav filein.wma
happy converting!
I found this worked find for me (after reading the man page for mplayer):

Code:
mplayer -ao pcm:file=filename.wav filename.wma
It's probably possible to have it go to stdout and pipe it to stdin for oggenc and do it in one step but I only had 5 files to convert...

Richard

Last edited by hobbes1069; 12-11-2007 at 11:22 PM.
 
Old 02-25-2008, 11:22 PM   #6
andrew.46
Member
 
Registered: Oct 2007
Distribution: Slackware
Posts: 651

Rep: Reputation: 92
Hi,

I am a huge fan of mplayer but it is perhaps not the best tool for this job. Try:

Code:
$ ffmpeg -i sample.wma -acodec vorbis -aq 100 sample.ogg
I have just run a few samples through and it is blindingly fast and great sound quality.

Andrew
 
Old 03-29-2008, 11:03 AM   #7
svante
LQ Newbie
 
Registered: Nov 2006
Posts: 3

Rep: Reputation: 0
I want to automate this for doing multiple files.
first I convert all spaces to _ in all subdirectories and files
Code:
find -depth -print0 | xargs -0 rename '1 while s: ([^/]*)$:_$1:'
then I run
Code:
for i in *.wma; do ffmpeg -i $i -acodec vorbis -aq 100 ${i%.wma}.ogg; done
to convert wma to ogg. but this does the job only for the current directory.
How do I modify it to run in all subdirectories?
 
Old 03-30-2008, 08:47 AM   #8
hobbes1069
LQ Newbie
 
Registered: Dec 2007
Posts: 4

Rep: Reputation: 0
Quote:
Originally Posted by svante View Post
I want to automate this for doing multiple files.
first I convert all spaces to _ in all subdirectories and files
Code:
find -depth -print0 | xargs -0 rename '1 while s: ([^/]*)$:_$1:'
then I run
Code:
for i in *.wma; do ffmpeg -i $i -acodec vorbis -aq 100 ${i%.wma}.ogg; done
to convert wma to ogg. but this does the job only for the current directory.
How do I modify it to run in all subdirectories?
I'm not a shell expert so I can't give you specifics, but I bet you could replace your "for i in *.wma" to use find instead of a standard *.wma glob.

Richard
 
Old 06-25-2008, 11:47 PM   #9
freephile
LQ Newbie
 
Registered: Jan 2005
Distribution: debian
Posts: 5

Rep: Reputation: 0
one step, all files

From the current working directory, this finds all .wma files (including sub-directories) and converts them (without removing or overwriting the originals) to Ogg-Vorbis at 128KB bitrate
Code:
find -name '*wma' -exec ffmpeg -i {} -acodec vorbis -ab 128k {}.ogg \;
 
Old 07-16-2008, 04:48 PM   #10
Mechfly
LQ Newbie
 
Registered: Feb 2006
Location: Eugene, OR
Distribution: Xubuntu, Ubuntu Server
Posts: 8

Rep: Reputation: 0
I just have to say that this was sweet. I was just wondering how to batch-op a whole bunch of wma's. thanks soo much.

btw, the file name when all is finished is xxx.wma.ogg , any hints on how to remove the 'wma' out of the final file name ?

 
Old 07-16-2008, 06:52 PM   #11
freephile
LQ Newbie
 
Registered: Jan 2005
Distribution: debian
Posts: 5

Rep: Reputation: 0
cut the .wma. from the file name

I could have eliminated the .wma with sed in the one-liner (sorry). But now that you have all these files with .wma. in it, you could use a convenient tool like the GUI krename [1] or the command-line 'rename' [2] to rename all files.

to test
Code:
rename --no-act --verbose 's/\.wma//' *\.wma\.ogg
to do
Code:
rename 's/\.wma//' *\.wma\.ogg

[1] http://www.krename.net/
[2] $ man rename
 
Old 07-18-2008, 01:10 AM   #12
Mechfly
LQ Newbie
 
Registered: Feb 2006
Location: Eugene, OR
Distribution: Xubuntu, Ubuntu Server
Posts: 8

Rep: Reputation: 0
its like music to my ears.....
again thank you.
 
Old 07-19-2008, 12:39 AM   #13
freephile
LQ Newbie
 
Registered: Jan 2005
Distribution: debian
Posts: 5

Rep: Reputation: 0
Preserve ID3 tags in conversion from wma to ogg

I found that ffmpeg will not preserve your ID3 tags, which is a big problem for me since the orginal wma files were completely tagged.

Using Synaptic, I innstalled Sound Converter (soundconverter)[1]. This will give you a GUI to do conversions, with the added benefit that it uses a tag reader to preserve all tags -- except that it didn't preserve the tags. Sound Converter (and Amarok) read the tags from the .wma files just fine.

Check for more tools at http://linuxappfinder.com/multimedia/audiotageditors


install soundconverter using the command line
Code:
# update your local repository info
sudo apt-get update
# see if your repositories know about it
apt-cache search soundconverter
# install the app
sudo install soundconverter
[1] http://soundconverter.berlios.de/
 
Old 07-19-2008, 01:45 AM   #14
1kyle
Member
 
Registered: Feb 2004
Location: 'Ol Blighty
Distribution: SLED 10, SUSE 10.3
Posts: 722

Rep: Reputation: 32
Why not convert to FLAC (free lossless codec). You can convert WMA to FLAC directly --even on Windows and if you are in Windows Winamp (free) can play FLAC files directly.

I Don't recommend converting to PCM first as a WAV file has a maximimum size of 4GB -- might seem large but if say you make a high quality recording this could be as little as 70 mins. Editing large WAV files is also a pain however FLAC editors do this much more easily.

Flac compresses nicely and is LOSSLESS. There are loads of converters around once you've got your file into FLAC so you can convert to whatever format you need.

FLAC is good for archiving your music and you can share the disk with Windows / other computers etc etc.

I agree that you don't want to store your music in ANY Proprietary form -- and under no circumstances do you want to add any DRM crud to your own music.

BTW most FLAC converters preserve ID3 tags etc etc so you won't lose titling or whatever even if you convert some files later again to mp3 for playing on a portable music device.

cheers

-K

Last edited by 1kyle; 07-19-2008 at 01:48 AM.
 
Old 05-24-2010, 03:28 AM   #15
tonya00henson
LQ Newbie
 
Registered: May 2010
Posts: 3

Rep: Reputation: 0
invitation

you can also visit this site to convert OGG file to any of the following MP3, AAC, FLAC, OGG, WMA, M4A and WAV.
 
  


Reply

Tags
audio, conversion, convert, format, ogg, wma


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Converting from .wma to .mp3/.ogg Napalm Llama Linux - Software 2 09-10-2005 12:18 PM
mp3 and wma to ogg, how can I do that? TruongAn Linux - Software 6 08-30-2005 04:04 AM
mp3 / wma / ogg ...etc crazibri Linux - Software 8 07-04-2004 02:42 PM
how to convert a wma to mp3?? yenonn Linux - General 2 04-26-2004 08:25 PM
Where can I find a WMA to Mp3 (or Ogg) converter? Pcghost Linux - Software 3 07-23-2003 05:16 PM


All times are GMT -5. The time now is 06:25 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration