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

burek burek021 at gmail.com
Tue Dec 13 03:05:01 EET 2016


[00:02:02 CET] <kerio> ._.
[00:02:39 CET] <JEEB> ffms2 also recently dropped support for a bunch of FFmpeg/Libav versions
[00:29:25 CET] <furq> distributing static binaries for people on old distros is probably the least painful way of doing it
[03:45:02 CET] <kyleogrg> I'm doing scene detection with ffmpeg: http://www.ffmpeg.org/ffmpeg-filters.html#select_002c-aselect
[03:47:15 CET] <kyleogrg> How can I combine the scene threshold parameter (select='gt(scene,0.1)' ) with the minimum time interval parameter ( select='isnan(prev_selected_t)+gte(t-prev_selected_t\,10)' )?
[03:50:56 CET] <kyleogrg> Right now, the only way I know is to write "select" twice: -vf "select=(blahblah),select=(whatever)"
[04:46:43 CET] <k_sze[work]> I need some help optimizing ffmpeg and vlc for immediacy.
[04:47:38 CET] <k_sze[work]> So right now I have a program that pipes raw video data to ffmpeg command, which in turn pipes encoded H.264 in mpegts stream to vlc, which serves the video over RTSP.
[04:48:27 CET] <k_sze[work]> If I open the RTSP stream on another computer, I notice that there is about 3~5 seconds of lag between capture and display.
[04:48:39 CET] <k_sze[work]> (the video is captured from a webcam)
[04:50:38 CET] <k_sze[work]> What command line options can I pass to ffmpeg and vlc to shorten the lag?
[05:53:58 CET] <ferdna> anyone using apache web server to stream content? if so, what are your cache settings?
[06:44:04 CET] <markvandenborre> ferdna: most people are using nginx-rtmp I guess...
[06:44:20 CET] <ferdna> markvandenborre, :(
[06:44:25 CET] <ferdna> i really need to use apache
[07:16:25 CET] <markvandenborre> ferdna: you could use it as a frontend I guess?
[07:16:43 CET] <markvandenborre> or fake the headers :-)
[07:17:15 CET] <markvandenborre> ferdna: nginx-rtmp is dead simple really
[07:17:28 CET] <markvandenborre> and it isn't exactly costly to set up
[07:17:52 CET] <markvandenborre> but of course if you have a boss/client telling you to use apache...
[07:18:07 CET] <markvandenborre> you might get away with part of the stack running apache really
[07:35:09 CET] <ferdna> markvandenborre, i think i did it already... on the directory directive
[08:23:09 CET] <laserbled> Hi. Does the framerate parameter do anything. because no matter what i do i cant increase the fps above 11 or 12.
[08:23:21 CET] <laserbled> ffmpeg -f gdigrab -framerate 30 -i desktop -q:v 0 -g 25 -maxrate 16000k -bufsize 8000k -f mpegts udp://192.168.1.5:5000 this is what i used
[08:26:31 CET] <laserbled> can you please let me know what is wrong
[08:30:37 CET] <laserbled> its like the framerate parameter is not doing anything
[08:33:54 CET] <nonex86> just use obs for desktop capture...
[08:39:12 CET] <laserbled> its actually inside program. its for streaming desktop...i just used commandline to test it
[08:39:46 CET] <laserbled> i need to use ffmpeg to get this working.
[08:46:38 CET] <nonex86> well, command you provided works well for me
[08:46:59 CET] <nonex86> at least media info said 60 fps (i put 60 fps as parameter)
[08:49:37 CET] <nonex86> also i just output it to avi, so the output codec was mpeg4
[08:50:55 CET] <laserbled> does the realtime log in the cosole show fps=60 ?
[08:51:04 CET] <laserbled> let me share my console. 1 sec
[08:53:08 CET] <laserbled> http://pastebin.com/zFW8yrbx
[08:53:26 CET] <laserbled> the last line ...frame=  149 fps=7.7 q=0.0 ...
[08:53:59 CET] <laserbled> even though the framerate parameter is set as 30 the output is never above 11
[08:54:25 CET] <nonex86> why do you care fps in console? are you sure your desktop rendered at constant rate and its really high?
[08:54:54 CET] <nonex86> as far as i remember dwm renders desktop at high rate only if its really needed
[08:54:56 CET] <laserbled> because the stream at the other end is very choppy.
[08:55:07 CET] <nonex86> try this
[08:55:15 CET] <nonex86> capture your desktop to file
[08:55:21 CET] <nonex86> if the file is ok
[08:55:30 CET] <nonex86> then you have a problem with your streaming
[08:55:33 CET] <nonex86> not with capture
[08:55:46 CET] <laserbled> ok. let me check
[08:56:54 CET] <nonex86> divide and conquer :3
[09:00:07 CET] <laserbled> ok. did that. the media info shows 30 fps but when playing the video it is very choppy, same as the one recieved on the stream. format used was same mpegts and file was .mpeg
[09:01:12 CET] <laserbled> consolve fps as before shows the same ~10 - 11 fps
[09:08:00 CET] <ferdna> laserbled, i believe it is -r 30
[09:08:17 CET] <ferdna> framrate is deprecated isnt?
[09:13:17 CET] <laserbled> ferdna: tried that too. infact i tried without frame rate param also. it defaults to some 29.something but still the output is capped at 11 fps
[09:13:34 CET] <ferdna> put it before the -i
[09:13:40 CET] <ferdna> and after the -f
[09:16:26 CET] <laserbled> used this minimal command ffmpeg -f gdigrab -r 30 -i desktop -f mpegts udp://192.168.1.5:5000
[09:16:40 CET] <laserbled> http://pastebin.com/DydZaidp
[09:16:44 CET] <laserbled> similar out
[09:17:14 CET] <nonex86> i used 3.1.4 for capture, and it doesnt says framerate is deprecated
[09:17:17 CET] <nonex86> so guess its not
[09:18:05 CET] <nonex86> at least till the 3.1.4
[09:23:12 CET] <ferdna> nonex86, the paramater -framerate is deprecated! not -r!
[09:24:11 CET] <nonex86> ferdna, once again, 3.1.4 says nothing about -framerate deprecation
[09:24:19 CET] <ferdna> As an input option, ignore any timestamps stored in the file and instead generate timestamps assuming constant frame rate fps. This is not the same as the -framerate option used for some input formats like image2 or v4l2 (it used to be the same in older versions of FFmpeg). If in doubt use -framerate instead of the input option -r.
[09:24:51 CET] <ferdna> nonex86, no it is not... but framerate is something else different than -r
[09:24:56 CET] <ferdna> i got confused
[09:25:12 CET] <laserbled> ferdna: tried both. posted pastebin above
[09:25:45 CET] <laserbled> ffmpeg capture that parameter and set it as 30 fps but when the actual out is generated it caps at some 11 fps
[10:00:06 CET] <ferdna> laserbled, are you on windows?
[10:02:08 CET] <ferdna> laserbled, https://antumdeluge.wordpress.com/2014/02/19/recording-screen-windows-desktop-using-ffmpeg/
[10:03:57 CET] <nonex86> surely on windows because of -gdigrab parameter
[10:05:00 CET] <ferdna> yeah i notice
[10:15:21 CET] <laserbled> ferdna: thanks. the reason i tried to stick with gdigrab was so that it wil be there by default. let me try with dshow as well. but the reason of not getting the desired fps after setting the parameter is a bit baffling.
[10:15:34 CET] <ferdna> ok
[10:15:41 CET] <laserbled> i wonder if mpegts has something to do with it
[10:15:51 CET] <ferdna> laserbled, that is just a format
[10:15:59 CET] <ferdna> *video format
[10:16:24 CET] <laserbled> ya so what else could be problem. any thoughts ?
[10:17:35 CET] <ferdna> yeah windows
[10:18:31 CET] <laserbled> vide driver could also be messing with it i suppose..hmm
[10:23:31 CET] <nonex86> video driver? doubt ffmpeg can dig low to the driver level
[10:27:11 CET] <ferdna> good ngiht
[10:27:17 CET] <nonex86> also i think ffmpeg is not a special software for capture desktop/application as you know, so the excelent result in this field is not ffmpeg priority
[10:27:36 CET] <nonex86> as last resort you can capture desktop yourself inside your software
[10:27:49 CET] <nonex86> and then feed it to encoder ffmpeg api
[11:03:13 CET] <Kadigan> Hey. When I'm converting 59.94 material to 60fps, I get (understandable) clicks in audio, wherever a new frame had to be inserted. Any switch I can give to ffmpeg to fix this audio relation, or possibly stretch the audio that 0.1% to fit?
[11:03:32 CET] <Kadigan> (so far I've been simply extracting the audio and running a second track in my NLE of choice)
[11:05:58 CET] <DaVyper> Is there a way to use metadata directly in a filter without executing ffmpeg twice?  Basicly what i am trying to accomplish is a video with some of the metadata info displayed as an overlay (kinda like MTV/Etc music videos) ideally in a single pass/execution
[11:19:52 CET] <Kadigan> DaVyper: if you're on Linux, you can always nest.
[11:27:46 CET] <iive> DaVyper: not sure what exactly you (want to) do, but ffmpeg supports complicated graph for connecting filters. e.g. you can split a stream in two, do different processing and merge it back.
[11:30:06 CET] <DaVyper> brb, gotta grab my script from other machine
[15:42:05 CET] <tyrel_wellick> hi, is there anyone who could help me with qt ref ?
[15:44:04 CET] <tyrel_wellick> y like this? Skipped opening external track: stream 1, alias: path='/Avid MediaFiles/MXF/AVID001.502/Edit Pgm 5 Part 1 +57AA1E6E.mxf', dir='AVID001.502', filename='Edit Pgm 5 Part 1 +57AA1E6E.mxf', volume='test', nlvl_from=3, nlvl_to=4.Set enable_drefs to allow this.
[16:51:52 CET] <alex88> what means Value 0.000000 for parameter 'colorspace' out of range?
[16:52:01 CET] <alex88> that the input value is out of the colorspace?
[17:22:06 CET] <alex88> how do I tell ffmpeg that the input is in yuyv422 ?
[17:25:25 CET] <kerio> alex88: which kind of input?
[17:27:10 CET] <alex88> kerio: so, I'm using https://gist.github.com/alex88/71828941e4c2b182648ba418bc74ad8c to get a/v from webcam and save to file, however colors are shifted, my hand is blue in the video
[17:27:53 CET] <alex88> I've tried to use https://gist.github.com/alex88/4e2d23ce1cacbd9a723166783d6d354d but I'm getting a lot of alsa buffer xrun and the audio is very bad that way
[17:28:02 CET] <kerio> yeah i was about to say
[17:28:41 CET] <kerio> well i mean
[17:28:42 CET] <alex88> thing is that with gst, ffmpeg shows yuyv420p as input but 'avconv -f video4linux2 -list_formats all -i /dev/video0' shows yuyv422 as possible format
[17:29:10 CET] <kerio> gstreamer is not outputting the correct pixel format
[17:29:20 CET] <alex88> anyway, without using mp4 and using an avi file as output, things work better, but still I think it's a borderline
[17:29:33 CET] <kerio> (why ac3 audio?)
[17:30:56 CET] <alex88> not a real reason, just trying
[17:31:00 CET] <alex88> is it cpu-intesive?
[17:31:26 CET] <alex88> *intensive
[17:31:42 CET] <alex88> I'm actually just trying and retrying to find the best way
[17:31:55 CET] <alex88> that doesn't throws alsa buffer issues but works
[17:41:34 CET] <alex88> my best option now is https://gist.github.com/alex88/901b4ee89669ff8a1527dc5fa3abff38 the problem is that audio starts a couple seconds later with a lot of 'Non-monotonous DTS in output stream This may result in incorrect timestamps in the output file.;
[17:41:39 CET] <alex88> in fact the audio is out of sync
[17:44:07 CET] <alex88> maybe the gst's queue max-size-buffers=0 max-size-time=0 max-size-bytes=0 helped with that?
[18:04:31 CET] <alex88> I got it partially solved using arecord to pipe to ffmpeg, the problem is that ffmpeg starts after a couple seconds and so there is still a shifting with the audio
[18:04:47 CET] <kerio> alex88: why can't you just use gstreamer?
[18:04:58 CET] <alex88> kerio: video colors are wrong
[18:05:06 CET] <kerio> surely it's got encoders
[18:05:18 CET] <alex88> kerio: gstreamer?
[18:05:31 CET] <kerio> the thing you're using with gst-launch
[18:06:02 CET] <alex88> the gst-launch command?
[18:06:18 CET] <alex88> I don't understand what you mean
[18:06:19 CET] <kerio> what do you think "gst" is for? :^)
[18:07:06 CET] <alex88> capturing
[18:07:07 CET] <alex88> ?
[18:08:08 CET] <alex88> or, maybe there's a way to fix those audio problems with ffmpeg
[18:08:14 CET] <alex88> the alsa issues
[18:16:39 CET] <kerio> alex88: i'd work on that tbh
[18:16:44 CET] <alex88> gst?
[18:17:09 CET] <debianuser> alex88: maybe you just don't have enough cpu for encoding? Try something like: `ffmpeg -f video4linux2 -i /dev/video0 -f alsa -i plughw:CinemaTM -vcodec libx264 -preset ultrafast -tune zerolatency -acodec libvorbis somefile.mkv` It should be fast enough for most CPUs, except maybe embedded ones.
[18:17:38 CET] <alex88> debianuser: in fact I'm using it on an RPI :(
[18:17:53 CET] <debianuser> ah..
[18:18:30 CET] <alex88> anwyay, it uses half of the 4 cores, all 4 cores are used at 50%
[18:19:15 CET] <alex88> debianuser: with my command, copying video stream, cpu usage is < 25%
[18:19:19 CET] <alex88> in 1 core
[18:19:25 CET] <alex88> (others are idle)
[18:19:51 CET] <alex88> if I use arecord it works perfectly, it's just that the audio is shifted because ffmpeg starts a little bit after arecord
[18:19:53 CET] <debianuser> It's just "alsa issues" usually means "buffer overrun", i.e. the soundcard writes to the buffer faster than the application can actually process, so after some time the buffer overruns and alsa library notifies about that. It's not alsa to blame, it's the application to blame as it doesn't read fast enough.
[18:20:43 CET] <alex88> gotcha, maybe lowering sample rate?
[18:21:55 CET] <alex88> meh, it improves but not that much
[18:22:11 CET] <alex88> but why with arecord it works? since the device is the same
[18:22:17 CET] <alex88> sampling and channels too
[18:23:01 CET] <debianuser> What do you mean "it works"? It has same alsa issues, you just don't see it, because alsa doesn't notify you. But you still hear it - as video+audio are out of sync. :)
[18:23:12 CET] <debianuser> It depends on what your bottleneck is. If it's video encoding cpu - you can try lowering framerate, if it's audio encoding - try changing audio codec. If it's disk - try smaller bitrate or smaller frame size, etc. Basically, what happens with my command? `ffmpeg -f video4linux2 -i /dev/video0 -f alsa -i plughw:CinemaTM -vcodec libx264 -preset ultrafast -tune zerolatency -acodec libvorbis somefile.mkv`
[18:25:18 CET] <alex88> debianuser: with avconv audio is just out of sync, with your command it's out of sync, skips etc
[18:25:25 CET] <alex88> with arecord I mean
[18:25:35 CET] <alex88> with arecord audio is just out of sync, with your command it's out of sync, skips etc
[18:28:04 CET] <alex88> anyway, cpu is at 20-25% in one core and the others are idle with my command, with yours because of the video codec it's around 60-80%
[18:30:19 CET] <alex88> this is the arecord command https://gist.github.com/alex88/5de01b31388b047ef94d437cf6ae4847
[18:30:56 CET] <alex88> debianuser: audio is shifted by less than a second, but it doesn't skip, it doesn't delay anywhere, it's just an initial delay due the arecord-ffmpeg different starting times
[18:31:23 CET] <debianuser> Can you also copy full output of my command running for a few seconds to some pastebin?
[18:31:43 CET] <alex88> sure
[18:35:19 CET] <alex88> debianuser: I've included also arecord output https://gist.github.com/alex88/c7399122fd1c2ab50a18bddfbe742c1c
[18:44:27 CET] <alex88> debianuser: any idea?
[18:45:49 CET] <debianuser> alex88: Hm... Let's mix those two: `avconv -f video4linux2 -input_format mjpeg -video_size 800x600 -framerate 30 -i /dev/video0 -f alsa -channels 1 -sample_rate 48000 -i hw:CinemaTM,0 -vcodec copy  -acodec libvorbis  somefile.mkv` You can also try actual ffmpeg in case there's any difference. Either install/build one yourself or try static arm builds from https://www.johnvansickle.com/ffmpeg/
[18:47:19 CET] <alex88> well, at first, no alsa buffer xrun issues, but more continuous (instead of being outputted in groups) "Non-monotonous DTS in output stream" errors
[18:48:04 CET] <alex88> anyway, I can hear some audio at the end of the stream (10 seconds recording) and nothing else
[18:48:48 CET] <debianuser> Try listening to the actual somefile.mkv recorded - does it sound expected?
[18:49:02 CET] <alex88> I said that after listening that file
[18:49:11 CET] <debianuser> Ah
[18:49:12 CET] <alex88> audio starts like half a second before the end
[18:50:05 CET] <debianuser> What if you record just the audio? No video at all. Try: `avconv -f alsa -channels 1 -sample_rate 48000 -i hw:CinemaTM,0  -acodec libvorbis  somefile.ogg` Does that sound fine?
[18:51:32 CET] <alex88> yes perfecty
[18:53:02 CET] <alex88> anyway, static ffmpeg build says alsa is not a known format
[18:55:42 CET] <debianuser> No "Non-monotonous DTS" warnings when recording just audio? And the sound starts instantly, not just 10 seconds in the end?
[18:55:48 CET] <alex88> yes
[18:55:50 CET] <alex88> sorry
[18:56:03 CET] <alex88> yes, there are warning all the time, but audio starts instantly and doesn't skip
[18:56:16 CET] <shincodex> happen to know anything about opencv
[18:56:21 CET] <shincodex> there all dead over there at the moment
[18:56:31 CET] <shincodex> and they use libavxxx in there silly vid wrapper
[18:57:03 CET] <alex88> debianuser: I don't want to waste your time anymore, also office is closing here
[18:57:07 CET] <alex88> thank you anyway for your help
[19:48:36 CET] <hurricanehrndz> Hi, has anyone gotten ffmpeg compiled with mmal
[21:52:47 CET] <sdvfwer> hello, I'm having an strange behavior when using ffplay on linux: I have a program that output a live mpegts stream to fifo (a file created by mkfifo). I'm trying to use ffplay to watch to this stream, in this way: Command line for player: "ffplay -probesize 100k -analyzeduration 100k - < fifo_file.ts". First I start this player command, then in another console I start the program that outputs the stream to the fifo file. With this setup, I can't get the
[21:52:47 CET] <sdvfwer>  audio/video to play, but when I CTRL+C the program that write the live stream to the fifo, the entire (since startup) video start playing, something like a buffer problem...
[21:53:37 CET] <sdvfwer> Someone can help me on this please?
[21:56:08 CET] <sdvfwer> (when I use the command "hexdump < fifo_file.ts" instead of ffplay,  I got the usual uninterrupted hex stream flow on console, then I think that the program that feed the fifo file is doing his job properly)
[22:00:27 CET] <durandal_1707> sdvfwer: why do big probesize and analyzeduration?
[22:00:57 CET] <sdvfwer> I also tryed to mess with these values, and nothing...
[22:06:03 CET] <sdvfwer> Another info: When I use the ffplay option "-v debug", I got several messages like this "[mpegts @ 0x7f4fbc000920] probing stream 2 pp:2499"
[22:06:36 CET] <sdvfwer> the last number (2499) decreases after about a second...
[22:07:47 CET] <sdvfwer> and I cannot get the video... But when I interrupt the source side of fifo, It appears that ffplay "wakes", and show the video immediately
[22:07:51 CET] <durandal_1707> wait for it to decrease to 0?
[22:10:48 CET] <sdvfwer> I still not wait for it reach zero
[22:11:54 CET] <durandal_1707> what is in 2 stream?
[22:14:27 CET] <sdvfwer> Now I waited for a few seconds and the video started playing!!!!
[22:14:37 CET] <sdvfwer> here are the console output in this case:
[22:15:37 CET] <DHE> sounds like it was buffering... but that's a lot
[22:15:57 CET] <sdvfwer> http://pastebin.com/fZDWNqF5
[22:19:21 CET] <sdvfwer> DHE: how can I reduce the ffplay buffering?
[22:23:12 CET] <sdvfwer> durandal_1707: please see the above pastebin. It appears that the stream 2 have nothing. How can I tell ffplay to skip this stream ?
[22:39:38 CET] <sdvfwer> I think that this is the main problem: ffplay try to probe the stream 2 for a long time, before giving up
[22:40:09 CET] <sdvfwer> how can I tell ffplay to ignore the 2nd stream, or to give up early ?
[23:24:40 CET] <sdvfwer> Okay, I just posted my questions to ffmpeg-user mailing list
[23:24:51 CET] <sdvfwer> [ http://ffmpeg.org/pipermail/ffmpeg-user/2016-December/034639.html ]
[23:26:10 CET] <sdvfwer> thanks folks
[00:00:00 CET] --- Tue Dec 13 2016


More information about the Ffmpeg-devel-irc mailing list