Lou Logan
Forum Replies Created
-
Lou Logan
March 12, 2014 at 9:52 pm in reply to: Need support using ffmpeg to get in an out points of video!First make sure you’re using a recent build of ffmpeg. See the FFmpeg Download page for links to builds.
Since you did not include any information about your inputs I’m going to assume that your MOV files contain formats that are compatible with the MP4 container:
$ mkdir remuxed
$ for f in *.mov; do ffmpeg -ss 30 -i "$f" -t 30 -codec copy -movflags +faststart remuxed/"${f%.mov}.mp4"; doneThe first command will create a “remuxed” directory. The next command will use a bash “for loop” to process all files in the directory. It will skip the first 30 seconds of each input with “-ss”, and stream copy (remux) the default selected streams to MP4 files that have a duration of 30 seconds with “-t”. “-movflags +faststart” will relocate the “moov atom” after encoding is complete to allow the video to begin playback by the viewer before it is completely downloaded. The “.mov” is removed from the resulting output file using bash parameter expansion. I’m guessing that it should work on OS X, but I’m not sure.
If the MOV files contain additional incompatible streams such as some types of data, timecode, and subtitles, then you can be explicit about what you want to include with -map:
ffmpeg -i input -codec copy -map 0:v -map 0:a outputIf you must re-encode, such as if your video is ProRes and your audio is PCM:
$ for f in *.mov; do ffmpeg -ss 30 -i "$f" -t 30 -codec:v libx264 -crf 23 -preset medium -codec:a aac -strict experimental -pix_fmt yuv420p -movflags +faststart remuxed/"${f%.mov}.mp4"; done
Depending on your input and your version, ffmpeg may attempt to minimize chroma subsampling. This is technically good, but non-FFmpeg based players may not be able to decode the file properly. Using “-pix_fmt yuv420p” will result in a compatible chroma subsampling scheme.See the FFmpeg and x264 Encoding Guide and FFmpeg and AAC Encoding Guide for more details.
-
Please include the complete ffmpeg console output, and don’t forget the code button to format it.
-
[Jason Douglas] “how to create a 16-channel stream. Ideally, 0=0, 1=1, 2-15 muted…”
I don’t really understand. Why do you need 16-channels? Where is the audio data coming from for the 2-15 channels? Or do you just want to generate silent audio?
-
Lou Logan
December 17, 2013 at 1:02 am in reply to: Pls assist me to convert lxf files for local broadcast/Thanks![Bruce Pelley] ”
Please help me convert .lxf files to a more mainstream, less restrictive & more usable format.”You should show some information about these files. The complete ffmpeg console output will suffice assuming they are all similar:
ffmpeg -i an-example-input-file.lxf[Bruce Pelley] “I have access to over a 100 commercial grade programs which are about 5 gigs apeice which makes it challenging to post one online as an example or for help purposes.
My need is to make them broadcastable on cable tv.”
Are you trying to make videos for the web or for cable broadcast? Sounds like you’re trying to do both.
[Bruce Pelley] ”
Desirable mainstream formats for output would include MPEG, MPEG-2 and MP4.”You didn’t provide much information here. We need more than just “MPEG, MPEG-2 and MP4”. What exactly does the broadcaster require? What video, audio, and container formats do they want? Do they have any special restrictions? Why can you not just give them copies of the original files? ~500 gigs is not that much.
-
Lou Logan
November 27, 2013 at 7:01 pm in reply to: extract stream of images from video file using ffmpeg[Andrew Simpson] “so this is not the solution then? Totally confused. I still do not know if it can be done or not :)”
It’s up to you if it is the solution or not. Have you tried it?
It depends on your requirements and what you’re trying to achieve. You wanted to output jpeg as an output pipe. I gave some info on that. Does it work for you and fit your needs?
You wanted to extract the “original jpeg” images from the OGG file, but Theora video is lossy and is a completely different format meaning going from your mystery input (jpg?) -> Theora -> to jpg will not result in the “original jpeg” images. However, using the right options may provide a sufficient enough quality. Is this acceptable?
As I have no information about your inputs, your ffmpeg version, and your ffmpeg configuration I can only offer limited suggestions (again, the actual ffmpeg commands and console ffmpeg console outputs would be extremely useful and should be considered to be required information).
-
Lou Logan
November 26, 2013 at 8:25 pm in reply to: extract stream of images from video file using ffmpegWill “-codec:v” re-encode? No. Please read the documentation on stream copy mode.
You will experience quality loss going from your (unknown) input format to Theora and then to jpg (although you may not notice).
-
Lou Logan
November 26, 2013 at 7:55 pm in reply to: extract stream of images from video file using ffmpegI don’t quite follow you, but basically you want the output to be piped?
[Andrew Simpson] ”
A typical guess would be:-i pipe:0 -qscale 1 -f mjpeg pipe:1“Did this not do what you want?
If your input is already jpg you can stream copy with “-codec:v copy” instead of re-encoding.
Also see the documentation on the pipe protocol.
Note that going from whatever your input is (more guesswork here: one reason why the console output is always needed) to Theora, then to jpg will not provide the exact same frames.
-
Lou Logan
November 25, 2013 at 8:18 pm in reply to: extract stream of images from video file using ffmpeg[Andrew Simpson] “-i – -qscale 1 h:outimg-%05d.jpg”
Please show your actual ffmpeg command and the complete ffmpeg console output.
[Andrew Simpson] “But i would like to extract directly to a stream.
What would be the arguments to use please?”
What kind of stream? “stream” is somewhat an ambiguous term.
-
Why use two ffmpeg processes instead of one?