Mplayer for a Windows warrior?

1 July 2007

Gregory left an interesting comment on a previous post. He had an interesting disclaimer and a question, lets deal with the question first.

I am on holiday and won't be able to access a Windows box for a while so if someone could actually try this and let me know how it works out then that would be very helpful.

> Do you know of a step by step tutorial for at least loading MPlayer and all of its prerequisite software for Windows XP?

As well as not having access to a Windows box at the minute, I have never used Mplayer on Windows (when I have been forced to use Windows I have tended to listen to music with VLC) , but I would start by downloading the Windows binaries from the mplayer homepage. It has a command line version and a GUI version also, so download both versions and see what you like best.

There are also User created packages that might be helpful.

For both versions, download the zip, extract the files and click on the exe file. There are three files that end with .exe . gmplayer in the GUI version is the graphical version which I assume is obvious how to use so I won't mention it again. The command line version has mplayer.exe which is the player, and mencoder which is the file encoding/recoding tool.

So follow this guide for how to use the command-line mplayer, and this for memcoder. It being Windows, do not forget to add .exe to the commands.

So the plan is that you would just open a DOS box (on XP it was Start then Run then type cmd then press Enter) then you type mplayer.exe filename to play a song or a video.

Path problems?

I do not claim to be a Windows expert (post Windows 98 at least), but for some reason I seem to know more than many Windows users - in the sense of know thine enemy ;).

One horrific limitation of the Windows XP command line is that it has no automatic path management, (or if it has then it is completely dumb), you often have to do this manually yourself via the Control Panel for every command line tool that you install. Yet another reason why Windows is a woeful exuse for an Operating System. Since at least the last couple of years, Linux is easier to use than Windows, especially if you try to go beyond typing a letter.

Therefore, you need to add the location of mplayer to the Windows path in order to be able to call mplayer.exe from any directory (which is what you need).

Lets assume you are a tidy boy and have put the files in C:Program FilesMplayer. Therefore I would create a variable called MplayerPath which corresponds to C:Program FilesMplayerthen add this variable to the PATH variable. Windows experts will know what to do already.

For people using Windows without really knowing anything about it, I provide an explanation below. If you are in this category, consider switching to Linux. Windows is really horrible when you get into it and changes from one bad design to another so often that you waste time learning about it; compare the fact that knowledge learned in the 1970s about Unix will still be useful for a Linux system in 2007 - good design is timeless.

Adding Mplayer to your PATH environment variable

The PATH environment variable is a list of directories (and other variables), separated by semicolons (';'). PATH is searched each time a command, executable or script is invoked without an absolute path.

So the plan is to add a new variable to your path. Note the emphasis on add, if you delete what is already there then all hell will break lose, and you may even have to reinstall Windows. So do not do this in a rush. Note. If you are heavy handed and kill your system or cause the end of the world as we know it then it is your own fault. It is at your own risk. If you pay attention then you probably will not cause any problems but do not blame me if you are an idiot and remove other things from your path.

Here is how it works on Windows XP. The 2000, NT versions should be similar, while older Windows are completely different. I have no idea how Vista works.

  1. Press the Start button, click settings and open the Control Panel.

    Next open the ‘System’ dialog.

  2. Switch to the Advanced tab, then click on the Environment Variables

    button at the bottom.

  3. This brings up another dialog. Within System Variables, click on New.

  4. In the New System Variable dialog, enter the following values:

  • Into Variable name enter MplayerPath
  • Into Variable value enter C:Program FilesMplayer
  1. Press OK. Here comes the fun part. You need to add this new variable

    to your system path. Basically the different entries in the path are separated by semicolons. In the next step you will need to add your new variable into the list. So if the last entry does not end with a semicolon then add one now.

  2. Now type the variable %MplayerPath%. Notice that it has a %percent

    sign% at the %start% and at the %end%. Then press okay, Windows may think for a little while, unless your computer is very new, then it might think quicker then you notice!

1 Brett says...

Or you could try this:

http://smplayer.sourceforge.net/windows/index_en.php

Seems to work well enough without tinkering - just a thought!

Posted at 11:34 a.m. on July 1, 2007


2 dbr says...

Or... http://mpui.sourceforge.net/ It's got a really simple UI, decent shortcuts (c for compact mode, t for always on top, then the arrow keys for skipping about, s to save a screenshot of the current video frame), and a few options like forcing other aspect ratios, and deinterlacing.. And thats it, none of the other unnecessary rubbish all these other media players have. And, it consists of about 3 files in total (the mpui binary, the mplayer binary, and the mplayer config, which can be deleted since there's no settings saved)

For videos, it's about the only application I use now, aside from for Quicktime H.264 videos (Which I use the Quicktime player for, as they had a weird overlay that screwed the colours up - But that's probably fixed now, since I've not updated it for quite a while)

Posted at 12:05 p.m. on July 1, 2007


3 Brett says...

Agreed, mpui is also excellent (just tried it out)...

Posted at 2:54 p.m. on July 1, 2007


4 Bug says...

Tell me about it. I got used to wget, then when I went back to windows for whatever reason, I was really annoyed by not being able to just simply wget stuff.

Posted at 11:58 a.m. on July 2, 2007


What do you have to say?

Show Editing Help

About

Hello, my name is Zeth, I'll be your host here.

Command Line Warriors is about taking control of your own technology, it looks at our experiences of computing; especially using GNU/Linux, the Python programming language, the command-line and issues such as techno-ethics, best practices and whatever is cool now. If you take control of your technology then you are a Warrior too!

This site is your site too which means that you can contribute and get involved. You can leave comments using the facility provided. For me, the comments and discussions are by far the best part of the site. So please do have your say!

Latest Discussions

Zeth

November 29, 2009
Hi Jordan, yes that URL is gone now. I have a new contact form on this site.
Python CGI contact forms

Jordan

November 29, 2009
Zeth attention! Your form, http://zeth.me.uk/contact/, is not working The explorer says connecting ..but nothing happens Sorry for my poor English: I am Spanish Regards
Python CGI contact forms

Jordan

November 26, 2009
Sorry: tell me , not tellme (I'm spaniard) And http://zeth.me.uk/contact/ don't work
You got the touch, you got the power

David Jones

November 25, 2009
Your mad skillz are too l33t! for me. I specifically switched to Google Reader so that I could show people what blogs I read. But I couldn't work out how ...
How to find the fashionable blogs quickly

Brian R. Hickey

November 20, 2009
Symantec picked it up too.
How to bring down Internet Explorer with six words

Zeth

November 17, 2009
Thanks djm, I am the moose here. Christian, assuming one actually does Internationalise the countries, it should still work I guess, as the gettext stuff will happen before the list ...
Countries in Django

Phillip Temple

November 17, 2009
Good start, but: a) wouldn't I want None back rather than 'ZZ'? b) why not add a 'shortcut' boolean, then prepend flagged fields (plus usual '-----' separator) to the actual ...
Countries in Django

djm

November 17, 2009
Am I being a moose or did you mean: from whatever.countries import CountryField instead of from whatever.countries import CharField ? Good post though, cheers.
Countries in Django

Christian Joergensen

November 17, 2009
Wouldn't the ordering get messed up after i18n?
Countries in Django

Steve - Electronic Cigarettes Fan

November 17, 2009
Very well done. Is your blog just you writing? Nicely done, Steven.
Blogger vs Wordpress

vetetix

November 15, 2009
Sorry to bother you nearly two years after you wrote this blog article, but I can't manage to find how to modify an existing field. I am trying to change ...
Three Useful Python Bindings - ClamAV, Apt and Evolution

Manju

November 4, 2009
I am transferring some files using psftp to other device's FAT partition. But the filestamp of the file being transferred is modified to that of FAT device, after the transfer. ...
PuTTY Series: Using PSFTP

iki

November 2, 2009
or simpler: socket.gethostbyname_ex(socket.gethostname())[2]
How to find out your IP address in Python

iki

November 2, 2009
local_ip = set([ i[4][0] for i in socket.getaddrinfo(socket.gethostname(), None) if i[0] == 2 ])
How to find out your IP address in Python

Fred

November 2, 2009
testing rst ------------- - point 1
An Introduction to ReStructuredText

Ano

October 27, 2009
"You simply found the license of the StumbleUpon Toolbar for Internet Explorer." That's possible. I've got some more interesting information to add. Firstly, go to this page: https://addons.mozilla.org/en-US/firefox/addon/138 - this ...
Are your Firefox extensions proprietary software?

Ken

October 21, 2009
Stumbled in here at lunch. This is the best find of the week. Thanks.
Three classic command line tips

Jim

October 19, 2009
Thanks for the rtsp:// post - that's something that has been bugging me for a while!
Three classic command line tips

Zeth

October 18, 2009
Thanks for the comments guys. Great to see the all the gang are still here!
Three classic command line tips

Bubba

October 18, 2009
Is there any way psftp can return the true transfer rates oberved during the actual transfer?
PuTTY Series: Using PSFTP