[Ffmpeg-devel-irc] ffmpeg.log.20131030
burek
burek021 at gmail.com
Thu Oct 31 02:05:01 CET 2013
[01:34] <everald> Hello. I want to record video and audio from a USB video frame grabber device.
[01:34] <everald> ffmpeg -threads 2 -f alsa -i hw:1,0 -f video4linux2 -i /dev/video0 myvid.mp4
[01:35] <everald> seems to do it except 1-2 seconds into the recorded stream, there is a skip (loss of video) and from thereon audio is not in sync anymore either.
[01:35] <everald> Any suggestions?
[01:36] <everald> Also, the above uses about 120% cpu, perhaps I should choose a lighter codec? But I don't understand enough, and it seems ffmpeg chooses the codec or something from the file suffix, too, which messes up my attempts.
[01:36] <everald> Also, it would be nice to use an encoding that allows me to play the file before recording is finished.
[01:37] <everald> Also, suggestions for a suitable front end are welcome (VLC is the only program I got running with both video and audio, but it didn't allow me to set deinterlacing (gave some error msg, or menu was greyed out)).
[01:42] <everald> http://pastie.org/8441479
[02:09] <llogan> everald: that's not ffmpeg
[02:10] <llogan> we didn't make that so we can't support it here
[02:11] <llogan> http://trac.ffmpeg.org/wiki/UbuntuCompilationGuide
[07:35] <Jerky> Hi everyone, ffmpeg -r 1/15 -i img%1d.png -r 30 test.mpg doesn't working, why? -r = 1/15, and -r = 30, so why there is no 1 image every 15 seconds?
[07:36] <Jerky> "ffmpeg -r 1/15 -i img%1d.png -r 30 test.mpg"
[07:59] <hendry> hmm, I'm getting Undefined constant or missing '(' in 'auto', Unable to parse option value "auto"
[07:59] <hendry> only place I use "auto", is in `-threads auto`
[09:17] <relaxed> hendry: threads are auto by default
[09:17] <relaxed> for libx264
[09:49] <hendry> relaxed: ok, I've made that assumption and just removed them https://github.com/kaihendry/recordmydesktop2.0/commit/b09fa9e1a0494d3f817a59f996618e0a3f90d069
[10:01] <relaxed> the setting used to be -threads 0
[10:27] <hendry> relaxed: -threads auto worked for me until a recent upgrade
[11:28] <vl4kn0> Hi, let's say I've got two videos that are exactly the same except one is in worse quality than the other. Is it possible to set a constant value for either qscale, qmin, qmax, crf... In order to convert both videos to have exactly the same quality?
[11:28] <zap0> quality is subjective.
[11:29] <zap0> you want #art #philosophy
[14:13] <dreamhawk> Is it possible to add #EXT-X-KEY:METHOD=AES-128 +URI-line while ffmpeg segments m3u8 ?
[14:28] <dreamhawk> Nobody knows? Ffmpeg + hls #EXT-X-KEY? :)
[14:36] <zap0> if you say so.
[14:41] <spaam> yes?
[14:41] <spaam> it worked last year IIRC
[14:42] <dreamhawk> What do i have to type to make ffmpeg add it ? I've googled for long time and re-checked manual several times..
[14:45] <spaam> ah you want to encrypt it.. that i dont know. only for decode
[14:47] <dreamhawk> spaam: not encrypt really, another script has to do that i think, but to enable encrypted playback, the #EXT-X-KEY:METHOD=AES-128,URI="" has to be in the m3u8-file. I could add it manually, but since it is live-encoding ffmpeg rewrites the m3u8 from time to time, and then it disappears
[14:48] <spaam> ffmpeg can decrypt files if the m3u8 file have that EXT-X-KEY thing.
[14:49] <dreamhawk> spaam: i do not want to decrypt :)
[14:51] <dreamhawk> ffmpeg creates like, allow-cache, targetduration, media-sequence, version. there must be some way to define method too
[15:11] <oooxff> any body here ?
[16:14] <jarr0dsz> hi everyone i tried compressing mp4 with amazing results i cannot hardly believe! from 130kb to 20kb
[16:14] <jarr0dsz> i added -vcodec libx264 -crf 20 -acodec mp2 but are there any implications? is there some directive api site for ffmpeg to review what these commands do?
[16:14] <jarr0dsz> the size was still the same
[16:16] <JEEB> the mp2 audio encoder is the only weird part, I would guess even libavcodec's aac encoder is better than that one?
[16:16] <jarr0dsz> anyone can help me understand those commands?
[16:16] <jarr0dsz> JEEB im not sure im very new user i found it on wiki post and just tried
[16:17] <jarr0dsz> perhaps i can better ask how to minimize size of .mp4 file optimal without loosing to much quality?
[16:17] <JEEB> -c:v or -vcodec just sets the video encoder to libx264, pretty much the best thing you can use right now
[16:17] <JEEB> -crf sets the constant rate factor rate control for value 20, this is closest to what one could call "constant quality" within the things we have available nowadays
[16:18] <JEEB> lower value leads to more file size and possibly better quality, higher value leads to more compression and possibly worse quality. You just pick the highest value that still looks good to you.
[16:19] <JEEB> also since generally the video track takes most of the size, you might as well just copy the audio track from input unless it's huge
[16:19] <JEEB> -c:a copy
[16:19] <JEEB> you can also set -preset for the speed VS general compression ratio
[16:19] <jarr0dsz> JEEB i combine 2 videos + the audio streams with this command ffmpeg -i stream1.mp4 -i stream2.mp4 -filter_complex "[0:v]setpts=PTS-STARTPTS, pad=iw*2:ih[bg]; [1:v]setpts=PTS-STARTPTS[fg]; [bg][fg]overlay=w; amerge,pan=stereo:c0<c0+c2:c1<c1+c3" -vcodec libx264 -crf 20 -acodec mp2 output.mp4
[16:19] <JEEB> http://mewiki.project357.com/wiki/X264_Settings#preset
[16:20] <JEEB> oh, if you're doing something for the audio then you naturally can't just copy it :P
[16:20] <jarr0dsz> its like 5 times compression from the orginal 2 flv files its amazing
[16:20] <JEEB> s/for/to/
[16:28] <yairgo> I'm trying to segment a file for hls, the segments will play in chrome on my ubuntu laptop if I hit them individually, but if I try to hit them with my iPad individually they will not play. can anyone help me out here? I can put a gist on github with all of the different commands I've tried to use if needed
[17:08] <Ulfalizer> got video recording working in my emu, but the video and audio streams drift out of sync after a while. still pondering what the best synchronization strategy is. how common is it for encoders to not return PTS values?
[17:31] <Paradisal> hello
[17:31] <Paradisal> I want to decode speex files using ffmpeg?
[17:32] <Paradisal> is there any code sample about it?
[17:32] <Paradisal> I saw libspeex's function's in FFmpeg, but i don't know how to use it
[21:10] <Xx_pk_XX> Hello. Does anyone know if it is possible to find out if some sequence of frames is in a video? What I need to do is find in lot of videos exact times of commercials. Commercial is always same (same audio/video), and I need to know when commercial starts in video. It doesn't matter how I will do it - by sound comparison, image comparison etc. I didn't find anywhere a possibility to do something like that. Is it even possible?
[21:11] <Xx_pk_XX> I have even tried cutting video into frames, and than using java I was comparing images. But it was either very slow, or too much inexact
[21:15] <llogan> Xx_pk_XX: you're the third person to ask for such a feature in a week. i can only think of one way you can do it with ffmpeg alone but only if the desired frame or audio packet are *exactly* the same in both sources
[21:16] <llogan> using framemd5 muxer or such
[21:16] <llogan> http://ffmpeg.org/ffmpeg-formats.html#framemd5
[21:16] <Xx_pk_XX> third? wow...
[21:17] <llogan> consider making a feature request on the bug tracker, or even better submitting a patch
[21:17] <Xx_pk_XX> ah well, I'm not sure if it will be exactly same, but thanks, I will try it out
[22:07] <Mista_D> What's the first step in effort to call DSP from ffmpeg?
[00:00] --- Thu Oct 31 2013
More information about the Ffmpeg-devel-irc
mailing list