3 Ways to Join/Merge .AVI video files in Linux:


3 Ways to Join/Merge .AVI video files in Linux:



1.) avimerge

Issue the avimerge command as such:

$ avimerge -i b1.avi b2.avi b3.avi b4.avi b5.avi b6.avi b7.avi -o output.avi



2.) mencoder

Issue the mencoder command as such:

$ mencoder -oac copy -ovc copy file1.avi file2.avi file3.avi -o output.avi




3.) cat & mencoder

Issue the cat command to string together or concatenate the binary .avi files:

$ cat foo1.avi foo2.avi foo3.avi > output.avi

(this will string all binary .avi files first but the sync of audio and video might likely be broken, so follow the next instructions below to fix it.)

after issuing the cat command and getting the final file output from it, issue the following meconder command from the mplayer package:

$ mencoder -forceidx -oac copy -ovc copy input.avi -o output.avi




*NOTES:
- Where input is the source file and output the outcome file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- The order you set the files to be joined or merged from left to right will be the sequence it will playback as one video file.
- Though for me avimerge is my preferred tool for this task.
- If the header file is broken in the final .avi use the avifix command part of the transcode package, as such:

$ avifix -i input.avi

/or

$ avifix -i input.avi -f 30,1

(this changes the header of the file input.avi and sets the frame rate to 30 fps.)

2 Ways to Disable Laptop Touchpad in Linux:


2 Ways to Disable laptop touchpad in Linux:

1.) Disable Touchpad with PSMOUSE Kernel Module

Sometimes when using a laptop the touchpad is too sensitive for typing that simply typing fast causes misstypes due to vibrations because of it, or you can be hitting it by accident, or that you dont need the touchpad as your using a mouse instead, to disable the touchpad issue command -

$ sudo /sbin/modprobe -r psmouse
/or
$ /sbin/modprobe -r psmouse
/or
# modprobe -r psmouse

to re-enable the touchpad again issue command -
$ sudo /sbin/modprobe psmouse
/or
# /sbin/modprobe psmouse
/or
# modprobe psmouse


2.) Disable Touchpad with SYNCLIENT

 - Using synclient utility, you can disable the laptop touchpad.
Disable touchpad, issue the command below:
 $ synclient TouchpadOff=1

For enabling touchpad, you need to set value to 0 and run this command in terminal as in below. 

 $ synclient TouchpadOff=0

- You can also put it in a startup bash script or config script so that it disables the touchpad on startup


*NOTES:
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- the # sign at the start of the command is to signify the Root user's terminal's prompt, no need to type this in.

Convert Image files within current Directory to .MPG video in Linux with FFMPEG


Convert Image/Picture files within current Directory to .MPG video in Linux with FFMPEG:

$ ffmpeg -r 10 -b 1800 -i %03d.jpg output.mp4



*NOTES:
- Where output is the outcome file.
- The $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- For this to work the files must start with 001.jpg and count from there in order, be careful not to miss a sequence number for example 001.jpg 002.jpg 003.jpg 005.jpg missing 004.jpg wont count the rest after, 005.jpg and if there are more after wont be added.


Convert an .MPG video to Picture files in Linux with FFMPEG


Convert an .MPG video to Picture files in Linux with FFMPEG:

$ ffmpeg -i input.mpg image%d.jpg

This command will generate the files named image1.jpg, image2.jpg, …

Picture files supported: PGM, PPM, PAM, PGMYUV, JPEG, GIF, PNG, TIFF, SGI.



*NOTES:
- Where input is the source file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.

Convert .AVI video to PSP friendly .MP4 video file in Linux with FFMPEG


Convert .AVI video to a PSP friendly .MP4 video file in Linux with FFMPEG:

$ ffmpeg -i input.avi -b 300 -s 320x240 -vcodec xvid -ab 32 -ar 24000 -acodec aac output.mp4

*NOTES:
- Where input is the source file and output the outcome file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.

Extract Audio from .AVI video to an .MP3 file in Linux with FFMPEG:


Extract Audio/Music from .AVI video to an .MP3 file in Linux with FFMPEG:

$ ffmpeg -i input.avi -vn -ar 44100 -ac 2 -ab 320k -f mp3 output.mp3

*NOTES:
- Where input is the source file and output the outcome file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.

Create VCD/SVCD/DVD from an .AVI in Linux with FFMPEG


Create VCD/SVCD/DVD from an .AVI in Linux with FFMPEG:



$ ffmpeg -i input.avi -target ntsc-dvd /tmp/output.mpg

*NOTES:
- Where input is the source file and output the outcome file.
- the $ sign at the start of the command is to signify the terminal's prompt, no need to type this in.
- ffmpeg can make DVD video files using -target option,
the target can be any of the following "vcd", "svcd", "dvd", "dv", "pal-vcd", "ntsc-vcd", "ntsc-dvd", "ntsc-svcd in the example above ntsc-dvd is used