65 lines
2.0 KiB
Plaintext
65 lines
2.0 KiB
Plaintext
README for csc-media
|
|
Elana Hashman
|
|
November 3, 2014
|
|
--------------------
|
|
|
|
|
|
These FFMPEG scripts are intended to help you cut and compress assorted videos:
|
|
in particular, the MTS raw output from the CSC's video camera.
|
|
|
|
|
|
How to use the scripts
|
|
======================
|
|
|
|
1. First, prepare your video files. To merge files, if you are using MTS
|
|
format, simply cat the files together, i.e.
|
|
|
|
cat vid1.mts vid2.mts vid3.mts > the_whole_vid.mts
|
|
|
|
If you need to trim the files, you can use the cut-mts.sh script:
|
|
|
|
./cut-mts.sh vid.mts 00:05:00 00:10:00
|
|
input start-time length
|
|
|
|
2. Run encode.sh on the file you're interested in compressing. This will run a
|
|
two-pass compress and encode to produce a final video file.
|
|
|
|
Caveats:
|
|
- encode.sh must be run in the same directory as the video files
|
|
- encode.sh's dependencies need to be in the same directory
|
|
- Therefore, you should clone a copy of csc-media into any directory you
|
|
want to run the job.
|
|
- You can only run encode.sh on one file in one directory. Otherwise, the
|
|
video cues from the first pass will be overwritten. If you want to run
|
|
simultaneous encoding jobs, clone a copy of the scripts into each
|
|
directory with each file you want to encode.
|
|
|
|
Invoke the script like this, preferably in a screen session due to job
|
|
length:
|
|
|
|
./encode.sh vid.mts vid ""
|
|
input prefix, output files extra ffmpeg flags (usually null)
|
|
|
|
3. Wait.
|
|
|
|
4. Wait.
|
|
|
|
5. Check htop, keep waiting.
|
|
|
|
6. Wait.
|
|
|
|
6. Voila, your videos have been compressed and encoded! Additionally, the
|
|
scripts will even kindly provide you with jpg thumbnails for the website.
|
|
|
|
|
|
Notes
|
|
=====
|
|
|
|
All compression schemes except mp4 are currently disabled in ./encode.sh. None
|
|
of the other scripts are currently verified to be working.
|
|
|
|
These scripts use a copy of ffmpeg in Peter ``BOFH'' Barfuss' home directory.
|
|
If those become unavailable for some reason, you will need to set it to the
|
|
system-wide binary.
|
|
|