Go into Media menu, Convert/Save, and add the input file to the File Selection. Click Convert/Save to open the Profiles selector.
Create a new profile and choose:
Encapsulation = MPEG-PS
Video codec = MPEG-2 (set width and height for your player)
Audio codec = MP3, Sample Rate = 44100
Save the profile for future use.
Click Start
Command Line
Open a command line prompt and go to the VLC installation directory (default is C:\Program Files\VideoLAN\VLC\ ). Run the following command line:
vlc <input> :sout=#transcode{vcodec=mp2v,vb=600,width=<the width>,height=<the height>,
acodec=mp3,ab=128,samplerate=44100,audio-sync}:std{access=file,mux=ps,dst=<filename>.mpg}
Note: You'll need to add quotes around #transcode{....}:std{...} on Linux or OS X.
Note: For versions before 0.8.6 you will need to change ":sout" to "--sout" and "dst" to "url".
vb stands for "video bitrate in kbits/sec". 600 kbits/sec should be good enough for most targets ... you might want to try a lower value for small screens.
ab stands for "audio bitrate in kbits/sec" and samplerate is the audio samplerate in Hz. Currently (2nd January 2007), MPEGplayer only supports 44.1KHz audio.
Important: mpeg2 allows only some very specific framerates. If encoding fails, it's likely that your source framerate doesn't comply. To change the frame rate, add fps=25 or fps=29.97 in transcode{...}. (This applies to the following .bat file too)
A convenient way for Windows users to achieve the same result is to use VLC-transcode.bat. Simply save this file somewhere and drag&drop a video onto it and it will be transcoded using the above settings. You will probably want to edit the file to change width and height (default is 320x240).