Archive
VLC shows some codec error
Problem
After upgrading my Manjaro box, VLC started to show some error message about a codec error. The video and audio played correctly, but there was an error message.
Solution
sudo pacman -S vlc-plugins-all
Links
- VLC and firefox broken after latest updates.
- https://forum.manjaro.org/tag/stable (always check it before an upgrade)
vlc: start a video at a specific time
Problem
Using VLC, I wanted to start a video at a specific time from the command line.
Solution
Use this:
vlc --start-time=20 video.mp4
It will start the video at the 20th second. As can be seen, the time must be specified in seconds. If you have the time in hh:mm:ss format, you’ll have to transform it to seconds.
Here is a little Python snippet that will do the transformation. Let’s say we want to jump to position 09:04:41 .
>>> hour, minute, sec = 9, 4, 41 # it'll be a tuple
>>> sec + minute * 60 + hour * 3600
32681
>>>
streamlink
Streamlink is a command-line utility that allows you to watch online video streams in popular video players, such as VLC, MPlayer or mpv.
(Under Manjaro it’s installable with yaourt.)
Example:
$ streamlink twitch.tv/sscait [cli][info] Found matching plugin twitch for URL twitch.tv/sscait Available streams: 720p_alt, audio_only, 160p (worst), 360p, 480p, 720p (best) $ streamlink twitch.tv/sscait best
If you just want to listen to it, select “audio_only” instead of “best”. It has lots of options, see the man for more info. For scripting, there is also a “-j” switch to produce a JSON output instead of normal text.
When is it useful? For instance you have a favourite channel that is streaming right now, but you don’t want to open it in the browser. Just launch it from the command-line and watch it in VLC. Or, if it’s a talk show, you just want to listen to it (see “audio_only”).
VLC hotkeys that you must know
a - cycle aspect ratio (16:9, 4:3, etc.) b - cycle audio track g, h - adjust subtitle delay (down, up) f - fullscreen space - pause
Full list here.
Which media player to use?
When I started to use Linux, I played movies with mplayer. Then the development of mplayer seemed to slow down (stopped?) and I switched to VLC. VLC is very easy to use and it plays everything, so I’m very satisfied with this player.
A few days ago I discovered mpv, which is a fork of mplayer2 and MPlayer. It shares some features with the former projects while introducing many more.
It seems that mplayer and mplayer2 are dead, but mpv is developed actively (check it out on github).
I just ran through its feature list and I saw that if you quit with Shift-q (i.e. Q), then mpv will resume from that position next time you start the same movie. Cool.
So next to VLC you can keep mpv too.
black screen with VLC and mplayer
Problem
When trying to play a video, I get a black screen. It’s the same with VLC and mplayer.
Solution
mplayer:
alias mplayer='mplayer -vo x11'
VLC:
Go to Tools -> Preferences -> Video. At the Output, choose “X11 video output (XCB)” from the dropdown list. If it doesn’t work, untick the option “Accelerated video output (Overlay)”.
VLC gets stuck
Problem
On my Linux box, VLC gets stuck sometimes and only the good old “kill -9” can shoot it out. Is there a single command to kill it?
Solution
alias killvlc='kill -9 `ps ux | grep vlc | grep -v grep | tr -s " " | cut -d" " -f2`'
Play Youtube videos with VLC
Did you know that VLC media player can play Youtube videos? Neither did I. Try this:
vlc http://www.youtube.com/watch?v=Dmn4gtZWVzw
Does Flash break all the time? Use VLC :)
Tip from here.
Play an interlaced video without those funny lines

I wanted to watch a DVD but it was interlaced, thus it contained lots of disturbing horizontal lines. How to get rid of those lines? Is there a way to filter them out?
Solution
Mplayer has an option for that :) Try this:
mplayer -vf pp=lb interlaced_video.iso
This procedure is called deinterlacing.
Tip from here. Image borrowed from here.
Update
VLC can do this too. Available under Video -> Deinterlace. You can also choose the deinterlacing method under Video -> Deinterlace mode.
VLC 2.0 is out
How to install VLC 2.0 in Ubuntu
In short:
sudo add-apt-repository ppa:n-muench/vlc sudo apt-get update && sudo apt-get install vlc
You must be logged in to post a comment.