[Ffmpeg-devel-irc] ffmpeg.log.20140518

burek burek021 at gmail.com
Mon May 19 02:05:01 CEST 2014


[00:21] <zybi1> hi
[00:21] <zybi1> is there a command to merge audio to a (soundless) video without?
[00:22] <c_14> ffmpeg -i sound -i video -codec copy outfile
[00:22] <zybi1> I got a mov-video and a wav-audio, converting the audio to any working format (i.e. aac I guess) is fast
[00:23] <zybi1> So which audio codec should I use for the following video type: MPEG-4 QuickTime Apple QuickTime Format AVC
[00:23] <zybi1> is wav working with that?
[00:24] <zybi1> can ffmpeg deal with that format well?
[00:25] <iive> avc is probably advanced video coding, aka h264
[00:25] <zybi1> yes
[00:25] <zybi1> Advanced Video Codec
[00:27] <iive> it should work with mp2/3, ac3, dca, aac
[00:27] <c_14> alac too
[00:27] <iive> probably...
[00:27] <iive> do we have alac encoder?
[00:28] <c_14> ye, think so
[00:28] <iive> alac was lossless, afair.
[00:28] <c_14> it's in ffmpeg -encoders anyway
[00:28] <zybi1> Unrecognized option 'codec'
[00:29] <c_14> try -c:v copy -c:a $audio-codec
[00:29] <zybi1> is -codec = -h264enc
[00:29] <zybi1> ?
[00:29] <iive> there is no h264enc in ffmpeg, we use libx264 like everybody else.
[00:35] <zybi1> thanks
[00:36] <zybi1> sorry: Failed to set value 'copy' for option 'libx264'
[00:36] <c_14> paste your commandline
[00:36] <zybi1> ffmpeg -i SOUND -i VIDEO -libx264 copy OUTPUT
[00:37] <c_14> eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeh, what are you trying to do?
[00:37] <c_14> Do you want to convert the video or the audio or just copy them?
[00:39] <zybi1> convert the video by adding the audio
[00:40] <c_14> just try ffmpeg -i sound -i video -c:v copy -c:a aac output
[00:41] <c_14> If I'm understanding you correctly, you just want to mux the two streams together into an mp4 without actually reencoding the video, but since mp4 doesn't support wav (afaik), you'll have to encode the audio stream
[00:43] <c_14> Or since you're using wav input, if you want the audio stream to remain lossless, use alac
[00:44] <c_14> assuming the wav is actually lossless
[00:56] <zybi1> Failed to set value 'copy' for option 'c:v'
[00:56] <zybi1> if wav or aac is now not too important to me
[00:56] <zybi1> sorry c_14
[00:57] <zybi1> http://pastebin.com/nhZe9jKE
[00:58] <c_14> you're using libav, not ffmpeg. can you download one of the static binaries and try it with that?
[01:04] <zybi1> success!
[01:04] <zybi1> http://pastebin.com/iPL2PAY8
[01:04] <zybi1> but alac produced no audio
[01:05] <zybi1> only copy audio with an existing ac3-file worked perfectly
[01:06] <zybi1> thanks a lot!!
[01:06] <c_14> np
[04:01] <wlritchi> Say I'm splitting a video file with ffmpeg -acodec copy -vcodec copy. I've noticed that this produces weird artifacts around the start and end.
[04:01] <wlritchi> I'm assuming this is because of block sizes of the audio codec, and non-keyframes in the video
[04:02] <wlritchi> Purely for reasons of "because I can", I want to preserve as much quality as possible (ie no transcoding to lossy formats when not strictly necessary)
[04:03] <wlritchi> I'm okay with transcoding the audio to FLAC because it's still a small enough part of the video file, but is there any way to keep -vcodec copy without these artifacts at the start?
[04:04] <wlritchi> (example solution: re-encode the first frame only)
[04:10] <c_14> You shouldn't be getting weird artifacts, ffmpeg should seek to the nearest keyframe and cut from there when used with -codec copy
[04:21] <wlritchi> c_14: The problem is that the audio doesn't get seeked to match
[04:22] <wlritchi> So I end up with video that (in most players, including ffplay) plays audio alongside timescaled video for the first few seconds
[04:22] <wlritchi> Not sure whether the timescaling is done in encoding or decoding
[04:23] <wlritchi> In any case, if possible, I'd like the split to not be seeked forward
[08:15] <hendry> http://video.stackexchange.com/questions/10772/converting-intervalometer-photos-into-a-movie
[08:51] <waressearcher2> anyone ?
[08:51] <waressearcher2> hi
[08:55] <waressearcher2> I have 15 minutes video with 1500k bitrate, and its resolution is 600x337, and the size is 161615KB, I converted it to video with smaller resolution 500x281 and now the size is 161463KB, so its quite the same size, why ? I mean, size of the picture decreases 30% but size of the file decreases just 0.01%, why ?
[09:09] <wlritchi> waressearcher2: What other encoding options did you specify?
[09:10] <wlritchi> If one of those was 1500k bitrate, I found your problem...
[09:11] <wlritchi> (file size is a function of bitrate)
[09:38] <waressearcher2> wlritchi: for both files I used that commands: "ffmpeg -i 1.avi -vcodec mpeg4 -vb 1500k -s 600x337 -y -f avi 2.avi" and "ffmpeg -i 1.avi -vcodec mpeg4 -vb 1500k -s 500x281 -y -f avi 3.avi", now 2.avi is 161615KB in size and 3.avi is 161463KB in size, they practically same size but resolution second one is 30% less, why ?
[09:39] <waressearcher2> shouldn't there be difference in size of about 50MB ?
[09:43] <blippyp> it's just like he said, it's because you didn't change the video bitrate, you got a smaller resolution out of the second video, but it did a higher quality encoding because of it (less artifacts).
[10:01] <waressearcher2> sort of understood
[10:02] <waressearcher2> so the encoder just used more bytes of data to encode ?
[10:02] <blippyp> basically...
[10:02] <blippyp> it's like takinga blu-ray
[10:02] <waressearcher2> even if resolution is smaller there is more bytes per pixel encoded ?
[10:02] <blippyp> then encoding it at say 60% quality (same resolution)
[10:02] <blippyp> it's going to degrade the video in order to encode that
[10:03] <blippyp> now resize the video - say to 80% of the original size
[10:03] <blippyp> and encode it with the same settings, it's still going to degrade the video, but it will do a much better job at it...
[10:03] <blippyp> both files end in the same size
[10:03] <blippyp> this is what happened to you - because you kept the video bitrate the same
[10:04] <blippyp> it probably wants it higher to do a perfect encoding, so it's keeping the size the same
[10:05] <blippyp> long story short, to get a smaller filesize you will need to lower the bitrate, but your video quality will suffer for it
[10:59] <smalltock> Hello, am ffmpeg noob. No matter what I do, I can't get ffmpeg to capture x11grab with the libvpx codec at a high framerate. It usually sticks around 5-6 FPS. If I specify a higher rate, it still captures at 5-6 FPS and the video file plays through them fast. My latest attempt was with the following command&
[10:59] <smalltock> ffmpeg -f x11grab -r 16 -s 1920x1080 -i :0.0+0,0 -q:v 1 -b:v 3M -c:v libvpx -an /tmp/nope.webm
[11:00] <smalltock> Am I doing something wrong or expecting too much performance or what? I appreciate all help.
[11:01] <waressearcher2> smalltock: try "ffmpeg -r 30 -s 1920x1080 -f video4linux2 -i /dev/video0 output.flv"
[11:02] <smalltock> No /dev/video0
[11:02] <waressearcher2> then you f**ed
[11:02] <waressearcher2> go create one, search google for how-to
[11:02] <smalltock> :3 Alrighty thank you
[11:14] <smalltock> waressearcher2: What is the video0 device supposed to do? According to what google search has brought up, it's supposed to be a camera. Is X supposed to be recognized as a camera? Apologies for the silly question
[11:15] <Mavrik> waressearcher2, uh, what are you talking about
[11:15] <Mavrik> you don't have video0 for screen grabbing
[11:15] <Mavrik> smalltock, the performance depends on how fast your computer is and how you grab it
[11:15] <Mavrik> smalltock, in your case you're telling ffmpeg to "think" that desktop input is recorded at 16fps
[11:15] <Mavrik> if you want it smoother set it to 30 but you will need enough CPU horsepower to encode it
[11:16] <waressearcher2> smalltock: you can always turn your camera on you desktop and record it, no pun intended
[11:16] <Mavrik> smalltock, also, I suggest you try with a fast x264 preset for starters to see if it's encoding CPU that's the limiting factor for you (e.g. -c:v libx264 -crf 22 -preset ultrafast something.mp4)
[11:17] <waressearcher2> yes, I mistakenly suggested wront solution, haven't noticed he want's to grab a desktop not webcamera
[11:17] <smalltock> I can grab from x11grab at 30 FPS if I specify it, just not when encoding with libvpx. If I use libx264, it's perfect, but I want libvpx output and don't want to encode more than necessary. Is libvpx encoding just that much more intensive?
[11:18] <Mavrik> smalltock, yes, libvpx is significantly less optimized than libx264
[11:18] <Mavrik> smalltock, make sure you have the latest update of it and ffmpeg
[11:18] <Mavrik> smalltock, there's also "quality" and "cpu-used" parameter
[11:19] <smalltock> is cpu-used limited much by default? I have a decent CPU, FX 8350 if I recall correctly.
[11:19] <Mavrik> try something like
[11:19] <Mavrik> -quality rt -cpu-used 2
[11:19] <Mavrik> and play with it
[11:19] <Mavrik> see http://www.webmproject.org/docs/encoder-parameters/
[11:20] <Mavrik> and https://www.virag.si/2012/01/webm-web-video-encoding-tutorial-with-ffmpeg-0-9/
[11:20] <blippyp> wow - good thing there was a life guard on duty... haha
[11:20] <smalltock> Alrighty, I'll read through those. Thank you very much!
[11:21] <Mavrik> smalltock, if that won't work... you'll just have to dump raw / lossless
[11:21] <Mavrik> and encode it later
[11:22] <Mavrik> which is usually a better approach anyway, since your system hiccups won't corrupt video
[11:23] <blippyp> Ya, I highly recommend that as well - You need a pretty good setup to not go lossless or near lossless x264 will give you some fair encoding while barely slowing you down... It will at least save some space while recording...
[11:24] <Mavrik> yeah, I used the ffmpeg lossless format or huffyuv
[11:24] <Mavrik> because I noticed that when recording raw the HDD sometimes tends not to follow
[11:24] <blippyp> yup, me too
[11:24] <Mavrik> and you need at least some compression to keep the I/O bandwidth down
[11:25] <blippyp> exactly - it's just a better approach in my opinion as well....
[11:25] <smalltock> That seems to have done it! Getting the specified 16FPS now. Managed 24 a few moments ago when rate was unspecified. Thank you guys for the help!
[11:26] <blippyp> my systems are pretty old, and even I can get away with encoding with a crf 17 with a preset of ultrafast
[11:36] <ReX> Hi Guys, I am using libmp3lame with ffmpeg to convert video to mp3 using this (ffmpeg -i input -vol %volume% -y -acodec libmp3lame -ab %quality%k output)  Is there a way to add an album art to the output?
[11:38] <ReX> I tried using the lames's --ti command after libmp3lame but it doesnt work.
[11:41] <ReX> could anyone please help me with this?
[11:43] <blippyp> ReX, I don't think you can do that with mp3's - but you can probably attach the album art with a different container if you're not picky about that. Something like mkv can have attachments I think, but I've never used it, I could be sending you off in the wrong direction, just trying to give you a bone to chew on...
[11:43] <ReX> Thanks blippyp, I can do this by (ffmpeg -i input.mp3 -i cover.jpg -map_metadata 0 -map 0 -map 1 output.mp3)
[11:44] <blippyp> cool
[11:44] <ReX> but this is not I want. I want to conver video to mp3 and add an album art to the output with 1 command
[11:44] <ReX> is it possible? with libmp3lame?
[11:44] <blippyp> I doubt it - mp3 is an audio only format as far as I know (thought)
[11:45] <blippyp> You'd have to google libmp3lame to find out for sure I guess
[11:45] <ReX> yes mp3 is only audio .. but it can have meta tags like album artist, title, genre .. album art etc right?
[11:46] <blippyp> Unless someone else who actually knows otherwise comes on - give it time, I don't know what time it is where you are, but it's really early in the morning where I am
[11:46] <blippyp> I don't think you have have art - just tags
[11:46] <ReX> I tried googling libmp3lame but there is not much info on its uses with ffmpeg, can you put me into right directions?
[11:46] <ReX> but this is not I want. I want to conver video to mp3 and add an album art to the output with 1 command
[11:46] <ReX> blippyp, how do I use tags then?
[11:47] <blippyp> you did it already with the map_metadata command
[11:47] <ReX> I mean how to change tages with libmp3lame?
[11:47] <blippyp> with the map_metadata command as far as I know???
[11:47] <ReX> the lame options doesnt work :(
[11:48] <blippyp> I honestly don't think you can do what you're trying - I'm pretty sure you would need to accept a video container to do this
[11:49] <blippyp> but there might be some other audio containers that will do what you want???
[11:49] <ReX> how to use map_metadata after libmp3lame? please give me some documentation if you know of any.
[11:49] <blippyp> man ffmpeg-filters
[11:49] <blippyp> search for metadata
[11:50] <blippyp> or http://www.ffmpeg.org/ffmpeg-filters.html  (same as the man page)
[11:51] <ReX> Thanks .. trying that
[11:51] <blippyp> good luck
[11:52] <ReX> No manual entry for ffmpeg-filters  :(
[11:55] <blippyp> I posted it
[11:55] <blippyp> search for metadata
[11:57] <mithodin> Hi.
[11:57] <ReX> :(
[11:58] <ReX> is it possible to do using any other encoder?
[11:58] <mithodin> I'm trying to put multiple images over a video with ffmpeg. They each get faded in and then faded out, so effectively it's only one image at a time. Is there a way to concatenate these images and then overlaying only one stream on the main movie?
[11:59] <ReX> for example, how do I use lame with ffmpeg?
[11:59] <mithodin> currently, I'm doing this: http://bpaste.net/show/285161/
[12:00] <ReX> i am getting unknown encoder when I try to use lame with ffmpeg. I have compiled ffmpeg with libmp3lame. Also I have lame installem
[12:00] <ReX> *installed
[12:00] <blippyp> mithodin: lookup concat in the man pages
[12:02] <mithodin> blippyp: Yes, I'm aware of concat. The question is, when I concat two of my overlay streams, is the timing preserved?
[12:03] <blippyp> I don't think so - it's a feature ffmpeg is missing as far as I'm aware... you would probably need to make 'short' clips and then concatenate them seperately afterwards...  :(
[12:03] <blippyp> If I'm understanding you correctly....
[12:04] <blippyp> but at least it's fairly easy to script
[12:04] <mithodin> blippy: So export the first 15 seconds with the first overlay, do the same with the other two and then concat these files?
[12:04] <blippyp> that's what i would do - someone else might know of a better way - I'd definately like to hear about it myself...  :)
[12:05] <mithodin> Okay, will this be seamless? I absolutely need a seamless result
[12:06] <blippyp> wait, I'm not thinking clearly - I don't see why you couldn't concatenate this....??? you have specififed fade-in and fade-out times - concat isn't working for you?
[12:07] <mithodin> I have not tried it yet... let me test it...
[12:07] <blippyp> yeah, I would try it - I think it will work for you
[12:09] <mithodin> so the synax is [v0] [v1] concat=n=2 ?
[12:09] <blippyp> you should be able to get away with just [0:v][1:v] concat [out1] .....
[12:11] <mithodin> while it's streaming... does ffmpeg make use of multiple cores by default?
[12:12] <blippyp> I think it depends on the codec being used, but I could be wrong
[12:13] <mithodin> okay, I'v tried it like this: http://bpaste.net/show/285192/ and it doesn't work
[12:13] <mithodin> in that I can see the first overlay appearing and disappearing, but not the second
[12:14] <blippyp> I'm trying it myself - just give me a couple of minutes
[12:17] <mithodin> maybe with select: http://ffmpeg.org/ffmpeg-filters.html#select_002c-aselect
[12:24] <Mavrik> mithodin, not setting encoding parameters for video is usually a very horrible idea
[12:24] <mithodin> I'm testing right now
[12:24] <Mavrik> but yes, ffmpeg will use multiple cores if en/decoder uses that
[12:24] <Mavrik> filters usually aren't multithreaded
[12:25] <Mavrik> also alot of decoders aren't.
[12:25] <mithodin> I see
[12:26] <mithodin> select does not seem to work. Enconding just stops at frame 500
[12:27] <mithodin> which is where the select of the first overlay stops
[12:27] <blippyp> it's enoding for me now, so I should see it soon
[12:28] <blippyp> I'm past frame 500 if that means anything to you though???
[12:29] <mithodin> can you paste your code?
[12:29] <blippyp> wait till we actually see the results....  doesn't look like it's working for me - all I get is audio
[12:30] <mithodin> ok
[12:30] <blippyp> let me look at the filter - explain what you want exactly
[12:30] <blippyp> it looks like you have a video
[12:30] <blippyp> and you want to overlay images from time to time on it right?
[12:30] <mithodin> yes, that is exactly what I'm trying to do
[12:31] <blippyp> k, let me play with it again
[12:32] <mithodin> the thing is that overlaying all the (faded) images over the stream one by one is not very efficient and gives me a low encoding fps
[12:33] <blippyp> that's because you have to re-encode the whole thing, all the while applying filtering to it
[12:33] <Mavrik> honestly I think you should use a software made for video production
[12:33] <Mavrik> not try to retrofit a video transcoder for production use :)
[12:33] <mithodin> the thing is that I have tried using openshot and others and got a/v desyncing every time
[12:34] <mithodin> with ffmpeg it works
[12:36] <blippyp> actually ffmpeg is great for filtering some times...  :)
[12:36] <blippyp> now you do have the alpha channels setup on the images right?
[12:36] <blippyp> or are you guessing/playing around with that not really understanding what it's doing?
[12:38] <mithodin> well, what I'm doing is fading in each image (so from zero visibility to 1) and after a time fade it back out again. Each image is a png with transparency that puts some text or an image over the video
[12:38] <Mavrik> blippyp, yeah, great for filtering but terrible for composition
[12:38] <mithodin> I'm not sure I get your question
[12:39] <blippyp> actually I find it's great for composition if you KNOW what you want beforehand and are willing to setup the scripts for it - then your video editing is a one-click process...  ;)
[12:41] <blippyp> my experience with alpha channels is that you basically need to convert everything to qrtle (if I remember that correctly) first to get it to work properly....  It's what I've always had to do for alphamerging....  Same issue here...
[12:41] <blippyp> the format of the video likely needs to be converted first
[12:41] <blippyp> are you getting any video at all with your attempts?
[12:42] <mithodin> yes, and it looks fine
[12:42] <mithodin> I can give you an example I'm getting with the slow approach
[12:42] <blippyp> sure
[12:43] <mithodin> (it will take a little moment to upload somewhere)
[12:43] <blippyp> no problem
[12:48] <mithodin> files.treffenstaedt.de/test.mp4
[12:49] <mithodin> http://files.treffenstaedt.de/test.mp4
[12:52] <blippyp> I'm such a dumb ass - my video was popping up behind my browser window for some reason!
[12:52] <mithodin> :-D
[12:52] <blippyp> it was working for me too - but like you it dies after 30 seconds
[12:53] <blippyp> Mavrik is right though, something like this is done much easier in a video editor...  ;)
[12:54] <mithodin> can you recommend one (except openshot, because that one creates a/v desyncing over the video)?
[12:54] <mithodin> for linux, of course
[12:55] <blippyp> Yeah, I hate the video editors in linux, they absolutely disgust me - It's actually why I used ffmpeg for nearly everything now myself.
[12:55] <mithodin> and here we are again ;-)
[12:55] <blippyp> At least with ffmpeg I have no one else to blame but myself for my stupidity in my scripting...  haha  :P
[12:56] <blippyp> I don't know, your command looks good from what I can tell - you're sure your timing is right in it for the fade-in/outs?
[12:57] <mithodin> yeah, pretty sure.
[12:58] <blippyp> wait - you're aware that YOU cut off video at 30 seconds right?
[12:58] <mithodin> yes. but not at 20
[12:59] <blippyp> the video you sent me is 31 seconds long?
[13:00] <mithodin> yeah, that used the other script that exports 60s, I killed it because 31 was enough to show what I want
[13:01] <blippyp> ok, so I'm confused then - what's the problem?
[13:01] <mithodin> I tried this: http://pastebin.com/tpvkdJkX
[13:02] <mithodin> and encoding just seems to freeze at frame 500
[13:02] <mithodin> which is exactly where the first overlay stops (see line 6)
[13:04] <blippyp> okay, but the filter was working fine wihtout the select in there? why do you want to use that?
[13:05] <mithodin> because without it, the concat does not work
[13:06] <mithodin> in that the second overlay does not appear at 20s
[13:07] <blippyp> the [so][start] overlay?
[13:08] <mithodin> no, the second part of the [start] overlay
[13:08] <mithodin> so [titel] appears, but not [ortzeit]
[13:10] <blippyp> okay, so you're happy with the first three fades yes?
[13:11] <blippyp> (ignoring before you started playing with the select filter)
[13:11] <mithodin> yes
[13:11] <dloo> hello
[13:11] <blippyp> then you want to get rid of everything and just have the video and the logo.png overlay
[13:12] <dloo> if i want to record : vlc v4l2:///dev/video0 :v4l2-standard=SECAM :input-slave=alsa:// :v4l2-chroma= :v4l2-input=1 :v4l2-audio-input=-1 :v4l2-width=768 :v4l2-height=576 :v4l2-aspect-ratio=4\:3 :v4l2-fps=0 :no-v4l2-use-libv4l2 :v4l2-tuner=0 :v4l2-tuner-frequency=-1 :v4l2-tuner-audio-mode=-1 :no-v4l2-controls-reset :v4l2-brightness=-1 :v4l2-brightness-auto=-1 :v4l2-contrast=-1 :v4l2-saturation=-1 :v4l2-hue=-1 :v4l2-hue-auto=-1 :v4l2-white-
[13:12] <dloo> balance-temperature=-1 :v4l2-auto-white-balance=-1 :v4l2-red-balance=-1 :v4l2-blue-balance=-1 :v4l2-gamma=-1 :v4l2-autogain=-1 :v4l2-gain=-1 :v4l2-sharpness=-1 :v4l2-chroma-gain=-1 :v4l2-chroma-gain-auto=-1 :v4l2-power-line-frequency=-1 :v4l2-backlight-compensation=-1 :v4l2-band-stop-filter=-1 :no-v4l2-hflip :no-v4l2-vflip :v4l2-rotate=-1 :v4l2-color-killer=-1 :v4l2-color-effect=-1 :v4l2-audio-volume=-1 :v4l2-audio-balance=-1 :no-v4l2-audio-
[13:12] <dloo> mute :v4l2-audio-bass=-1 :v4l2-audio-treble=-1 :no-v4l2-audio-loudness :v4l2-set-ctrls= :live-caching=300 --sout 'file/ps:testbfm.mpeg' --ts-es-id-pid --no-video --audio-track-id=1005 , can i do the same with ffmpeg?
[13:12] <dloo> hmm sorry, too much lines
[13:12] <dloo> it : :v4l2-standard= :input-slave=alsa:// :v4l2-input=1 :v4l2-audio-input=-1 :v4l2-width=768 :v4l2-height=576 :v4l2-standard=SECAM
[13:13] <mithodin> no, logo.png should be there always
[13:13] <blippyp> okay
[13:13] <blippyp> so what do you want to happen after the 3 fades?
[13:13] <mithodin> there are 7 more fades later, but I wanted to get it right with the first three
[13:14] <mithodin> the only thing I'm trying to fix is that the fps get very low when I just use overlays on top of overlays all the time
[13:14] <mithodin> for encoding
[13:15] <blippyp> so this is just a 'takes too long to encode' issue?
[13:15] <mithodin> and so I thought that since overlays 1 - 3 don't really show up at the same time but sequentially, I could maybe concatenate them and have only two overlays, one of logo.png and one of the other ones combined
[13:15] <waressearcher2> dloo: thats a lot of text
[13:16] <mithodin> blippyp: basically, yes.
[13:17] <waressearcher2> to get 360 seconds of silence I use "ffmpeg -f lavfi -i aevalsrc=0:0:0:0:0:0::duration=360 -ac 2 -ar 44100 -ab 320k -y -f ac3 s_360.ac3" is it correct command to generate silence ?
[13:17] <mithodin> I'm at ~5 fps for as it is now, and as I said, I need 7 more overlays
[13:17] <blippyp> I don't think you can solve that - I can give you a 'sort of quick fix' - but you'll still likely want to encode it again after the face (without the filtering required though)
[13:17] <blippyp> face=fact
[13:18] <blippyp> like right now you haven't specified the codecs you want to use at all...
[13:18] <mithodin> yes
[13:18] <blippyp> if you changed the -c:a copy test.mp4 to:
[13:18] <waressearcher2> how to mix 10 audio files ? so far I use command "sox -m 1.mp3 2.mp3     10.mp3" but is it possible to use ffmpeg instead of sox ?
[13:18] <mithodin> In the end I need one output for DVD and one for Youtube
[13:18] <blippyp> -c:v libx264 -crf -qp 0 -preset ultrafast -c:a ac3 test.mp4
[13:19] <blippyp> it would decrease the encoding time, but it will still need to go through the 'filtering'
[13:19] <blippyp> and your file size would be large
[13:19] <mithodin> large as in 80 GB or large as in 20?
[13:20] <blippyp> you'd still need to re-encode the final video afterwards to drop the file size down (i normally change -qp 0 to -crf 17) for my final videos
[13:20] <blippyp> depends on the length of the video
[13:20] <blippyp> how long is your main video?
[13:20] <waressearcher2> I have 26 minutes audio with voice that read text and 3-4 seconds in between pauses, is there a way to remove those silent pauses ? some filter maybe ?
[13:20] <mithodin> about 40 minutes
[13:20] <blippyp> that will take a while regardless...
[13:21] <blippyp> you might as well use -c:v libx264 -crf 17 -c:a ac3 to begin with and be done with it...
[13:21] <mithodin> can't I still use -c:a copy?
[13:21] <iive> audacity is non-linear audio editor, it might be better than linux video editors.
[13:21] <blippyp> setup your filter with shorter times (so that you're only playing with a couple of minutes)
[13:22] <mithodin> what do you mean, shorter times?
[13:22] <blippyp> and get it working the way you like and then when it's the way you want change your fade times to what they should be, double check, triple check, and encode....???
[13:23] <blippyp> or you can probably set your PTS - that should drastically increase things for 'testing' it until you get it right
[13:24] <blippyp> basically you could encode the 40 minutes into a 5 minute video instead - leaving all your fades and everything the way you want it - it would SHOW the fades as they should appear, but they will come and go quickly
[13:24] <mithodin> ah, I see what you mean
[13:24] <blippyp> but the entire video would be there (kind of like fast-forwarding through a movie)
[13:24] <blippyp> setpts i the filter
[13:24] <blippyp> i=is
[13:25] <mithodin> good idea, thanks
[13:25] <blippyp> to be honest, I'd probably go the pts route...
[13:25] <blippyp> no problem
[13:25] <blippyp> always glad to help (it doesn't always work out that way)  haha  ;)
[13:26] <blippyp> but to be honest, with a project like this you'd be much better off with an actual video editor
[13:26] <mithodin> if there was one which actually worked, I would agree
[13:27] <waressearcher2> no video editor for linux ?
[13:27] <blippyp> ya, there's a few
[13:27] <blippyp> mostly lame, but they should work for what he wants
[13:27] <blippyp> which one did you say you were using?
[13:27] <mithodin> openshot does what I need
[13:27] <mithodin> but it breaks the a/v sync
[13:28] <blippyp> maybe try kdenlive?
[13:28] <blippyp> I don't like it, but lots of people apparently do
[13:28] <waressearcher2> last one I checked when you open video file that editor first convert it to pictures jpg or png, after that I gave up on video editors for linu
[13:28] <waressearcher2> x
[13:29] <mithodin> I don't want to have kde programs installed on my computer. They always pull a ton of useless stuff I don't need
[13:29] <blippyp> ya, that's my issue with them as well
[13:30] <blippyp> I've used kdenlive, it was alright - but in the end ffmpeg is much faster for my general needs, so I pretty much stick with ffmpeg
[13:30] <blippyp> I think I even still have it installed, not sure though
[13:30] <blippyp> it was a little buggy, but it was alright for a basic editor
[13:31] <mithodin> is there a video editor based on ffmpeg maybe?
[13:31] <blippyp> most of them pretty much are I think....  :P
[13:31] <blippyp> kdenlive has ffmpeg options
[13:31] <blippyp> actually they were probably x264 options
[13:33] <blippyp> cinelerra looks someone decent
[13:34] <mithodin> I tried it and I could not even figure out how to import a clip
[13:34] <blippyp> really? looked like a nice easy editor......???
[13:35] <blippyp> I would guess clicking on file or video would give you an import option in the menu?
[13:35] <mithodin> yeah I found it eventually, but still... for me it was utterly confusing
[13:35] <mithodin> then again, I do prefer terminal programs ;-)
[13:36] <blippyp> I miss premiere
[13:36] <mithodin> what's that?
[13:36] <blippyp> adobe premiere?
[13:36] <mithodin> ah, I see
[13:37] <blippyp> there are basically three decent video editors that I'm aware of - premiere, vegas and (I can't remember the other one - it's REALLY popular though, many consider it to be the only real professional app of the three)
[13:37] <blippyp> I think it starts with an f
[13:38] <mithodin> final cut?
[13:38] <blippyp> yeah
[13:38] <blippyp> never used it myself though
[13:38] <mithodin> a friend of mine has it
[13:38] <blippyp> I honestly can't imagine it having much more options that premiere - premiere does everything
[13:38] <mithodin> seems to like it a lot
[13:39] <blippyp> yeah I find people are usually fans of one of those three and of course the final cut guys hate the premiere guys as much as the windows guys hate the linux guys... yadda yadda yaddda - whatever
[13:39] <blippyp> they all basically do the same damn thing...  ;)
[13:39] <blippyp> the great part of premiere though is the integration with the other apps in the suite along with the database for managing your videos - it's pretty cool
[13:40] <blippyp> I imagine they all have the ability to have basically the same filters, so it pretty much likely comes down to person preference on the user interface
[13:40] <mithodin> of course, with Adobe CS you get great interation, it's one package
[13:41] <blippyp> yeah, but I wouldn't touch an adobe app for anything these days, I hate the whole cloud nonsense - I just threw my hands up over the idea (not that I'm using it anymore anyways, but still)
[13:44] <blippyp> well, it's really late for me - I'm gonna go catch a few hours of sleep before my kid wakes up - good luck with your video mithodin - hope the pts idea helps you out
[13:44] <mithodin> thanks, see you
[13:44] <blippyp> bye bye *gone*
[13:45] Action: blippyp vanishes without a trace
[13:48] <waressearcher2> blippyp: sup
[14:15] <dloo> anyones know how to change the v4l2 input?
[15:30] <iive> dloo_: try -f v4l2 -i /dev/video1
[16:26] <dloo_> iive: already tried it :(
[18:21] <socksandsandals> hi all
[18:22] <socksandsandals> I am receiving some VP8 frames from another source that I want to write to a file and then turn into a video file when its all over
[18:22] <socksandsandals> sometimes there are gaps in the frames, however, when the source is not sending any frames
[18:23] <socksandsandals> would I have to fill in those gaps with a YUV black frame in order to make it video file-able?
[18:23] <socksandsandals> and if so, do I write just one black frame and just set the timestamp of the next real frame to the size of the gap in time?
[18:25] <socksandsandals> I guess what I'm asking is, do I have to have a frame written in the video file for every frame I would have received had it not been interrupted? or can a video file have a frame that's "repeated" until the next one comes along?
[18:42] <nyuszika7h> hi, I'm using a fairly recent build for Windows, but the -to option doesn't seem to work as expected
[18:42] <nyuszika7h> it seems to work about the same as -t
[18:43] <nyuszika7h> okay, will do that when I get to my laptop soon
[19:27] <nyuszika7h> https://gist.github.com/anonymous/1cca6444a980928a3f9d
[19:28] <nyuszika7h> the end doesn't even get stripped
[19:30] <c_14> If you use -ss as an input option, the startpoint of the video file is adjusted by that time. So, with what you have, you will copy everything from (00 to 42:25) adjusted forward by 40 seconds.
[19:31] <c_14> So in reality everything from 00:40 to 43:05
[19:31] <nyuszika7h> yeah, that's with -t, isn't -to supposed to solve that?
[19:32] <c_14> Only if you use -ss as an output option
[19:32] <nyuszika7h> ah, so put it after -i
[19:32] <c_14> If you use -ss as an input option, ffmpeg seeks $time seconds into the file before applying any output options therefore -to believes that the start point of the video file is wherever the beginning seek point is.
[19:33] <nyuszika7h> I see
[19:35] <c_14> Whether or not that is a bug or a feature is up for debate, but that's how it currently works.
[19:35] <Schrostfutz> hi, I want to make a screencap with ffmpeg, but it is too fast, what am I doing wrong?: "ffmpeg -f x11grab -r 30 -s 1916x1041 -i :0.0+0,24 -vcodec libx264 -threads 0 video.mkv"
[19:36] <nyuszika7h> Windows Media Player likes to get the total time wrong when I cut a video with ffmpeg
[19:36] <nyuszika7h> mpv gets it right
[19:39] <c_14> nyuszika7h: If the timestamps in the file are correct, I'd probably blame wmp for being shit at decoding.
[19:40] <c_14> Schrostfutz: try -r 25
[20:27] <ChocolateArmpits> Or -r 15
[20:46] <Zeranoe> Does FFmpeg have a command line option to determine if it supports multithread (-threads)?
[20:48] <fajung> ned help recording my desktop with speakers(system) audio, ffmpeg just records the mic  and I don't know how to fix this: http://s2.postimg.org/jv6bmdgh5/Captura_de_pantalla_de_2014_05_18_15_49_09.png
[20:50] <klaxa> fajung, are you running pulseaudio?
[20:50] <klaxa> i would think so, because you are running ubuntu
[20:50] <klaxa> if my guess is correct, try using pulse instead, use -i pulse instead of -i default
[20:50] <fajung> don't know, new in Linux, how can I check it?
[20:51] <klaxa> then open pavucontrol and select the monitor device for the ffmpeg recording stream in the recording tab
[21:05] <fajung> I think that I get it now, thanks. why when I start ffmpeg it echo "configuration: --extra-libs=-ldl --prefix=/opt/ffmpeg --enable-avresample --disable-debug --enable-nonfree --enable-gpl --enable-version3 --enable-x11grab --enable-libpulse --enable-libx264 --enable-libfdk-aac --enable-libvorbis --enable-libmp3lame --enable-libopus --enable-libvpx --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libspeex --enable-libass --enable-avisynth --en
[21:05] <fajung> able-libsoxr" ?
[21:06] <c_14> It just does that. Consider it a feature.
[21:08] <fajung> if I compile it in my ubuntu14.04, if I upgrade my kernel I'll have to re compile it again?
[21:09] <c_14> nah, why should you?
[21:09] <fajung> ok, thanks for the help
[21:25] <troyp> Hello. I'm compressing a mp4 to H.264 and it keeps rotating the video. Is there anyway to tell it to "leave it alone" lol
[21:33] <c_14> rotating the video?
[21:34] <troyp> ok one sec
[21:39] <troyp> c_14: http://pastebin.com/KErZGTNq
[21:39] <c_14> That transpose part is rotating the video.
[21:40] <troyp> right, so let me explain. Without that, when I film in "portrait" mode on iPhone. It's rotated to "landscape" mode. This fixes that, but it breaks it for the other formats
[21:41] <troyp> so i guess I need to detect when the file is filmed like this, and only add this command
[21:42] <c_14> pretty much
[21:42] <troyp> ok
[21:44] <troyp> what's the best way to get this information?
[21:44] <troyp> ffmpeg -i?
[21:45] <c_14> probably
[21:45] <troyp> it has some very interesting metadata it says "rotate 90"
[21:46] <troyp> so i guess if i could extract that
[21:46] <troyp> then i'll know
[21:49] <troyp> very strange. There's multiple Metadata sections listed under input #0. Why is that?
[21:50] <c_14> Magic?
[21:50] <c_14> Can you paste it?
[21:50] <troyp> http://pastebin.com/KErZGTNq line 28
[21:51] <c_14> The first one is for stream 0:0 the audio stream, the second one is for stream 0:1 the video stream
[21:51] <troyp> http://pastebin.com/UgHtsAmh
[21:51] <troyp> so it looks like it's returning only the audio stream with this command. Anyway to specify video?
[21:52] <troyp> or maybe it's not the audio, but the overall metadata
[21:57] <c_14> Hm, it should dump all the metadata by default, but you could always just dump the ffprobe output to a file ffprobe $file 2>out
[21:57] <troyp> so they're calling it global metadata
[21:58] <troyp> let me try an updated version and see if it's an old bug, one sec
[21:58] <troyp> nope, same results. weird
[21:58] <troyp> what are you saying about ffprob?
[22:00] <c_14> ffprobe $file 2>outfile should dump all the output from ffprobe to a file and that should  have the info as well
[22:01] <troyp> ahh yeah
[22:01] <troyp> nice
[22:01] <troyp> ffprobe -v quiet -print_format json -show_format -show_streams 07E87390DD3011E3931EDDA6A0A26CF9.mp4
[22:01] <c_14> that works too
[22:01] <troyp> this works
[22:01] <troyp> thanks
[22:03] <troyp> c_14: am i mistaken or is the input file already H.264?
[22:03] <troyp> based on what i'm reading here
[22:03] <c_14> it is h264
[22:03] <troyp> the only thing i'm trying to do is turn HD into SD...
[22:03] <troyp> doing this takes makes the file-size 80% smaller
[22:04] <troyp> so i guess it's really the other stuff i'm doing like bitrate
[22:04] <c_14> yep
[22:04] <troyp> got it, thanks!
[23:29] <waressearcher2> is anyone ready to answer my questions ?
[23:29] <waressearcher2> questions, plural
[23:29] <c_14> just ask and if someone can help you, they will
[23:30] <waressearcher2> I allready asked 3 of them yeasterday, no one bothered
[23:31] <waressearcher2> c_14: can you scroll back for about 16 hours ?
[23:32] <waressearcher2> anyway, I have mp3 file, 26 minutes, with voice, that is read text, phrases, and after each phrase there is 3-4 seconds pause, how to remove pauses ? is there any filter or something ?
[23:33] <c_14> You might want to use audacity for that. That's not exactly ffmpeg's territory.
[23:34] <waressearcher2> c_14: you mean by hand ? I have dozens such mp3 files and there are hundreds of pauses I need to cut out, can audacity do that ?
[23:34] <waressearcher2> there should be some filter
[23:35] <c_14> http://audacity.238276.n2.nabble.com/remove-silences-td293043.html
[23:35] <c_14> not sure if audacity has some scriptable interface, but it might
[23:35] <waressearcher2> another one, to generate 360 seconds of audio silence I use that command: "ffmpeg -f lavfi -i aevalsrc=0:0:0:0:0:0::duration=360 -ac 2 -ar 44100 -ab 192k -y -f ac3 s_360.ac3", is it correct one or is there a better method to get silence ?
[23:37] <c_14> I think you can just use aevalsrc=0:duration=360, but that should be fine
[23:38] <c_14> waressearcher2: For your first problem, apparently you can use sox: https://stackoverflow.com/questions/11834297/how-can-i-remove-silence-from-an-mp3-programmatically
[23:48] <vdm> I have file with raw audio data in G.711 MULAW codec format. how i can play the file data using ffmpeg?
[23:49] <c_14> try ffplay?
[23:51] <vdm> c_14, ffplay?
[23:51] <vdm> i'm using linux, ffmpeg is installed but i have no ffplay command
[23:52] <c_14> You sure you have ffmpeg not libav?
[23:55] <vdm> c_14, i tried use ffplay, here is the error output: http://pastebin.com/hp6Ltgsh
[00:00] --- Mon May 19 2014


More information about the Ffmpeg-devel-irc mailing list