Friday, July 27, 2012

Tips and Tricks for Linux

I am going to put down useful commands for Linux here and continuously update it. If you want to contribute to this page, please post your suggestion in comments.
1) Installing from a .iso file
Easiest thing to do is to mount the .iso in a tmp location and install it from there.
sudo mkdir /tmp/matlab 
sudo mount /<path to .iso file>/matlab.iso /tmp/matlab -t iso9660  -o loop=/dev/loop0
2) Using FFmpeg to break a video into parts
ffmpeg -i STOPS_20111214_CR1_02_C5.mov -sameq -ss 00:00:00 -t 00:00:30 videopart1.mov

So this code takes in a video named STOPS_20111214_CR1_02_C5.mov, uses all the parameters of video such as framerate, bit rate to make a new video and extracts all the frames from start time of 0 seconds to end time of 30 secs and writes it as videopart1.mov
3) Overcoming too many threads error of ffmpeg
http://crazedmuleproductions.blogspot.com/2007/10/multithreading-in-ffmpeg-and-mpstat.html

No comments:

Post a Comment