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

burek burek021 at gmail.com
Wed Jun 5 02:05:02 CEST 2013


[01:43] <dror> I am trying to convert a h264 mov to a png video. I am getting segmentation fault when calling avcodec_encode_video2() on the first rgba frame.
[01:43] <dror> Anyone up for some help? :)
[02:29] <dror> anyone?
[02:57] <dagerik> "Stream #0:0(eng): Video: mpeg4 (Simple Profile) (mp4v / 0x7634706D), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 8491 kb/s, 29.97 fps, 29.97 tbr, 2997 tbn, 2997 tbc"
[02:57] <dagerik> what does all these numbers mean?
[03:01] <sacarasc> #0 is first file. :0 is first stream within the file. 1920x1080 is the resolution. SAR is Screen (I think) aspect ratio. DAR is display aspect ratio. 8491 is the bitrate. 29.97 fps is the frame rate.
[03:01] <sacarasc> The rest I'm not sure about.
[03:17] <killown> is there a way to ffmpeg record the screen and the output got splitted when it reaches N size?
[03:18] <killown> split each N size I mean
[03:43] <killown> please help me?
[03:45] <killown> ffmpeg -f alsa -ac 2 -i pulse -f x11grab -s hd1080 -r 24 -i :0.0 -vcodec libx264 -crf 0 -preset ultrafast -an -y /videos/video.mkv -acodec pcm_s16le -threads 0 -vn  -y /videos/audio.mkv I need split the files when it reach 1GB then I will have one script checking this file to move it  for another place
[03:46] <killown> I will record it in the tmpfs
[04:34] <defaultro> hey folks, how do we specify a fade out of 45 frames if we don't know the total number of frames?
[04:46] <ulatekh> defaultro: I think that would violate causality.  You have to know the total number of frames in your video before trying to fade it out.
[04:47] <defaultro> there is no automatic way of ffmpeg finding out on the fly?
[04:47] <defaultro> it's because I am going to encode about 30 files via a for loop in unix
[04:47] <defaultro> i can write a script that captures the total frames but was hoping if there is an easier way
[04:48] <ulatekh> You can ask ffmpeg how many frames are in the file.  http://stackoverflow.com/questions/2017843/fetch-frame-count-with-ffmpeg
[04:49] <ulatekh> No, like I said, I think that violates causality. :-)
[04:51] <ulatekh> You could go through all the fun of writing some code that interfaces to ffmpeg's libraries directly, passing frames through, but keeping 45 of them in reserve, until you reach the end, at which point you start fading....but that doesn't sound easier to me :-)
[04:55] <defaultro> k
[04:55] <defaultro> i'll just grab the time and mult it with my default fps
[04:56] <ulatekh> Glad I could (sorta) help :-)
[04:56] <defaultro> actually there is a command that is better for finding the frames
[04:56] <defaultro> i think it's ffplay
[05:02] <defaultro> this is it, ffmpeg -i MVI_9508.MOV -f null /dev/null 2>&1 |grep Duration | awk '{print $2}' | cut -f 1 -d, | cut -f 3 -d:
[05:02] <defaultro> that will work for me since my recordings are just 15 seconds max
[05:02] <defaultro> thanks for the link, I got an idea :)
[05:03] <defaultro> I'll round that off then multiply it with 30 fps :) done!
[05:03] <ulatekh> Remember, it's not exactly 30 fps...it's usually a fraction that's close to 30, but not exactly.
[05:03] <ulatekh> NTSC video is actually 30000/1001 fps.
[05:04] <defaultro> 30000/1001
[05:04] <defaultro> oh, you wrote it :)
[05:04] <defaultro> yup, I'm aware. It's ok,since it's just for fading
[05:04] <ulatekh> Just being overly careful. :-)
[05:04] <defaultro> yup :D
[05:09] <defaultro> I got it. (echo "5.73" | bc -l | xargs printf "%1.0f")
[05:09] <defaultro> I'll write the script now :)
[05:11] <ulatekh> Enjoy!
[05:11] <defaultro> Done, it worked! :D
[05:11] <defaultro> DURATION=`ffmpeg -i $1 -f null /dev/null 2>&1 |grep Duration | awk '{print $2}' | cut -f 1 -d, | cut -f 3 -d:`
[05:11] <defaultro> TIME=$(echo $DURATION | bc -l | xargs printf "%1.0f")
[05:11] <defaultro> echo $TIME
[05:12] <defaultro> continuiung with the code now :D
[05:14] <ulatekh> And the heat death of the universe is delayed, just a little bit...LOL
[05:36] <defaultro> this is the code I wrote
[05:36] <defaultro> DURATION=`ffmpeg -i $1 -f null /dev/null 2>&1 |grep Duration | awk '{print $2}' | cut -f 1 -d, | cut -f 3 -d:`
[05:36] <defaultro> TIME=$(echo $DURATION | bc -l | xargs printf "%1.0f")
[05:36] <defaultro> TOTALFRAMES=$(echo "$TIME * (30000/1001)" | bc -l | xargs printf "%1.0f")
[05:36] <defaultro> TOTALFRAMES=`expr $TOTALFRAMES - 65`
[05:36] <defaultro> ffmpeg -y -i $1 -vcodec libx264 -vf "fade=in:0:45,fade=out:$TOTALFRAMES:45" -r 30000/1001 -crf 15 -preset veryslow $1.mp4
[05:37] <defaultro> I can correct TIME=..... I don'
[05:37] <defaultro> I don't need bc there
[05:37] <defaultro> oops
[10:03] <damir__> hello
[10:03] <damir__> when using ratecontrol I keep getting "failed to encode buffer" errors
[10:03] <damir__> any idea why this is happening?
[10:03] <damir__> oh the encoder is mpeg2video
[12:24] <hackeron> hey, any ideas why this video will not play on iphone/ipad? < http://itstar.co.uk/skip.mp4
[12:25] <hackeron> it was recorded with this from an ACTi IP camera: ffmpeg -i rtsp://127.0.0.1:10104/proxyStream -loglevel warning -analyzeduration 0 -map 0 -codec:v copy -codec:a libfdk_aac -flags +qscale -global_quality 1 -afterburner 1 -f segment -segment_time 60 -segment_wrap 10 -segmen    t_list_flags live -segment_list_size 10 -reset_timestamps 1 -segment_list 51acee26c5399f6029000027.csv -ar 44100 -y 51acee26c5399f6029000027_%02d.mp4
[12:25] <JEEB> [h264 @ 027ba860] number of reference frames (0+2) exceeds max (1; probably corrupt input), discarding one
[12:25] <JEEB>     Last message repeated 1 times
[12:25] <JEEB> is what I got at first at least
[12:26] <hackeron> JEEB: what is causing that? - anything wrong with my ffmpeg command?
[12:26] <JEEB> anyways, seems to be main profile, level isn't shown in ffprobe at least
[12:26] <JEEB> hackeron, well it's a problem in the H.264 stream, which you were just copying, but I don't know if it's /that/ problematic
[12:27] <JEEB> then I can see the 5fps part, but I can't tell if /that/ is the problem
[12:27] <JEEB> also the thing seems to have gone through GPAC at some point
[12:28] <hackeron> JEEB: yeh, I tried to do MP4Box -inter 500 as that seems to make videos start playing quicker
[12:42] <hackeron> JEEB: here's an original from another camera: http://itstar.co.uk/original.mp4
[12:43] <hackeron> plays fine in the browser but not from iphone/ipad - any ideas why that could be? :(
[12:43] <hackeron> that one's baseline
[13:09] <hackeron> Any ideas why this file won't play on the iphone/ipad? < http://itstar.co.uk/original.mp4 - It was recorded from an IP camera with ffmpeg -i rtsp://192.168.88.11 -analyzeduration 0 -map 0 -codec:v copy -an -flags +qscale -global_quality 1 -f segment -segment_time 60 -segment_wrap 10 -segment_list_flags live -segment_list_size 10 -reset_timestamps 1 -segment_list test.csv -ar 44100 -y test_%02d.mp4
[15:49] <raven> hi
[15:50] <raven> webcam-recording: i have this kind of error every frame http://picpaste.com/5310d6f64be425b739165477efe5b35e.png what is that and how to solve?
[16:16] <whatadewitt> hey, anyone here good with making animated gifs using ffmpeg? i have a script that i'm running that is creating them in 6 different ways to different qualities, but i'm trying to further refine my solution, does anyone have any tips?
[16:17] <whatadewitt> fwiw, my best output thus far is by creating a bunch of images, then using "convert" to stitch them together. i have -coalesce -layers OptimizeTransparency as vars on my convert
[16:18] <whatadewitt> if the original images are pngs my gif is 2.6 megs, if original images are gifs i'm 1.2 but it's a bit grainy... i'd love to keep the png quality with the gif size if possible :S
[16:35] <ubitux> whatadewitt: are you using the development version of FFmpeg?
[16:39] <raven> webcam-recording: i have this kind of error every frame http://picpaste.com/5310d6f64be425b739165477efe5b35e.png what is that and how to solve?
[16:43] <raven> ubitux, http://pastebin.com/Y3GhZ3ut
[16:43] <raven> ffmpeg version 0.8.6-6:0.8.6-1+rpi1
[16:44] <ubitux> it's missing "EXACT ffmpeg command", the output is incomplete, and you might not even be using FFmpeg
[16:44] <ubitux> and if it's FFmpeg, it's extremely old
[16:45] <raven> ffmpeg -f video4linux2 -r 25 -s 640x480 -vcodec copy -i /dev/video1 -acodec libmp3lame -ar 32000 -ac 1 -ab 64k out.avi
[16:45] <ubitux> -vcodec copy is an output option
[16:46] <ubitux> please upgrade your ffmpeg
[16:46] <ubitux> at least use ffmpeg 1.2, or better ffmpeg git
[16:46] <ubitux> also, you still didn't share the complete output
[16:47] <raven> thats the newest on raspberry
[16:47] <ubitux> https://trac.ffmpeg.org/wiki/How%20to%20compile%20FFmpeg%20for%20Raspberry%20Pi%20%28Raspbian%29
[16:47] <spaam> :S
[16:47] <ubitux> raven: then you're likely not using FFmpeg but the fork, and thus we can not support it here
[16:48] <spaam> using space in urls--
[16:48] <spaam> ubitux: you wrote that guide? :)=
[16:48] <spaam> :)
[16:48] <ubitux> no
[16:48] <ubitux> i don't have a r-pi
[16:49] <spaam> mr.bananas :D  nice name
[16:49] <raven> ubitux, not sure if you have a similar definition of the word polite...
[16:51] <ubitux> i'm just pointing out issues and ways to solve your problems
[17:43] <hackeron> Any ideas why this file won't play on the iphone/ipad? < http://itstar.co.uk/original.mp4 - It was recorded from an IP camera with ffmpeg -i rtsp://192.168.88.11 -analyzeduration 0 -map 0 -codec:v copy -an -flags +qscale -global_quality 1 -f segment -segment_time 60 -segment_wrap 10 -segment_list_flags live -segment_list_size 10 -reset_timestamps 1 -segment_list test.csv -ar 44100 -y test_%02d.mp4
[19:02] <whatadewitt> ubitux: apologies for the delay... i don't believe i am using the development version... when i run help i see ffmpeg version 1.2
[19:03] <durandal_1707> whatadewitt: use dev, latest master
[19:04] <whatadewitt> durandal_1707: will all my commands be the same? or will i have to rewrite?
[19:04] <durandal_1707> whatadewitt: what commands?
[19:05] <whatadewitt> durandal_1707: i'm just creating animated gifs... i guess im wondering what i will gain by using dev, latest master
[19:06] <raven> v4l2 broken file - i dumped webcam inputs now but cannot open it with vlc, avidemux, avconv and mplayer how to repair/transcode it?
[19:07] <durandal_1707> whatadewitt: what command you use to create andimated gifs?
[19:08] <durandal_1707> gif muxer in 1.2 create uncompressed big files
[19:08] <whatadewitt> durandal_1707: im having my best luck by running the following first: ffmpeg -ss 20 -i video.mp4 -t 5 -s 500x271 -f image2 tmp/%03d.png
[19:08] <whatadewitt> i then get the number of files created and run
[19:09] <whatadewitt> convert -delay 1x10 `seq -f tmp/%03g.png 10 3 150` -coalesce -layers OptimizeTransparency tmp/test.gif; -- where the 150 is number of images that were created
[19:09] <durandal_1707> so you don't use ffmpeg to create gif files?
[19:10] <whatadewitt> i guess no, this was giving me better quality... if i run something like
[19:10] <whatadewitt> ffmpeg -ss 20 -i video.mp4 -vf scale=500:-1,format=rgb8,format=rgb24 -t 5 -r 10 tmp2/output10.gif
[19:10] <whatadewitt> that gives me a much larger file and the quality is pretty bad
[19:10] <durandal_1707> that happens with 1.2
[19:11] <durandal_1707> anyway, you do not use ffmpeg for gif creation, so asking for help here is akward
[19:11] <whatadewitt> er, well, if i can create the gifs in better quality with a newer version of ffmpeg, then that would be a more than acceptable solution
[19:12] <durandal_1707> well certainly smaller than with 1.2
[19:12] <durandal_1707> but it still lacks high quality palette thing
[19:12] <whatadewitt> ah
[19:13] <whatadewitt> durandal_1707: the quality is currently the bigger issue for me, unfotunately :(
[20:47] <hackeron> hey, I have an rtsp stream with 2 video streams in it - how do I record the first one only?
[20:59] <relaxed> hackeron: ffmpeg -i input -map 0:v:0 -map 0:a ...
[21:17] <raven> my webcam video is mostly blue and red - what could be the right encoding?
[21:18] <llogan> raven: what are you trying to do?
[21:19] <raven> llogan, to find the right channel mapping
[21:26] <zap0> try them all
[21:30] <durandal_1707> raven: its not rgb?
[21:30] <raven> obviously not
[21:33] <bananaduckling> Hey guys, I'm trying to install ffmpeg for use in a script, but I keep getting "ERROR: libopencore_amrnb not found", does anyone know how I'd circumvent this?
[21:35] <talcat> Is there a way to create a video from every nth image in an image sequence without renaming the images?
[21:35] <llogan> bananaduckling: install libopencore_amrnb or remove --enable-libopencore-amrnb
[21:36] <llogan> *install and then compile ffmpeg
[21:37] <llogan> what is your distro?
[21:37] <bananaduckling> Using ubuntu.
[21:37] <bananaduckling> I can't find where I would download the tar for the libopencore_amrnb install anyway.
[21:37] <llogan> do you need amrnb? i think about 3 people have used it in the last year.
[21:38] <bananaduckling> Hahaha, fair enough. I'll take a look into that.
[21:38] <llogan> but, if for some reason, you do want it you can install the libopencore-amrnb-dev package
[21:38] <llogan> then compile ffmpeg as shown in https://ffmpeg.org/trac/ffmpeg/wiki/UbuntuCompilationGuide
[21:38] <bananaduckling> With apt-get install?
[21:38] <llogan> yes
[21:39] <bananaduckling> Alright! *runs compile* Fingers crossed.
[21:40] <relaxed> bananaduckling: apt-cache search libopencore; apt-cache show libopencore-amrnb0 | grep ^Home
[21:41] <Zeranoe1> Is there a list anywhere of the decoders that depend on external libraries to work? Like Theora for example
[21:41] <llogan> Zeranoe1: i usually look in configure
[21:42] <Zeranoe1> llogan: What for?
[21:43] <llogan> what external stuff is required.
[21:46] <relaxed> Zeranoe1: ls ffmpeg/libavcodec/lib*dec.c
[21:47] <relaxed> oh, that's not complete
[21:49] <relaxed>  "./configure --list-decoders | grep lib" should be
[21:50] <Zeranoe1> relaxed: Thats it, thanks a lot
[21:52] <Zeranoe1> I see a few on there that I think FFmpeg had decoder support for built in? Like vp8/vp9, or maybe openjpeg?
[21:53] <llogan> sometimes there is both a native and external decoder available for the same format
[22:02] <llogan> Zeranoe1: don't forget that some native decoders may require an external library such as PNG (zlib)
[22:24] <hackeron> relaxed: thanks :) - ended up adding live555ProxyServer which seems to set up the streams different from ffmpeg - adding /track1 or /track2 gets the first/second stream through live555ProxyServer, but not reading with ffmpeg directly, strange
[22:27] <andrew____> hi to all! i stream a list of files by restarting a ffmpeg on each file. On client drops frames, when stream restarts. how can i make continuosly stream without a restarting ffmpeg?
[22:31] <andrew____> while true; do; ffmpeg -re -i file.mp4 -c:copy -f mpegts udp://239.10.10.10:1234?pkt_size=1316; done
[23:04] <bunniefoofoo> when I compiled ffmpeg with --enable-libvo-aacenc, now the "aac" encoder is using a different sample format (float packed instead of float planar). Is libvo-aac being used even when I set the codec name to "aac" ?
[23:05] <llogan> "aac" is the name of the native aac encoder.
[23:06] <durandal_1707> bunniefoofoo: you are not using libvo-aacenc, as that one support s16 packed only
[23:07] <llogan> there are better choices than libvo_aacenc.
[23:07] <bunniefoofoo> why would the sample format change from packed to planar ?
[23:12] <bunniefoofoo> ok my bad, encoder was using S16 packet. But how did it change from float planar to S16 packet? My only guess is that "aac" passed to avcodec_find_encoder_by_name() now gives me libvo-aacenc
[23:13] <bunniefoofoo> the native encoder still shows up under ffmpeg -codecs
[23:20] <bunniefoofoo> I would use the native encoder if not for the heisenbug in there
[23:21] <durandal_1707> bunniefoofoo: native aac use float planar
[23:21] <durandal_1707> libvo one use s16
[23:22] <bunniefoofoo> right, I was mistaken earlier, that is cleared up now
[23:23] <bunniefoofoo> wierd thing is I ask for "aac" and seems to give me libvo-aacenc
[23:26] <Rajeev> Is it possible to have only single BR stream in m3u8 playlist?
[23:26] <Rajeev> in HLS
[23:27] <Rajeev> instead of multiple Bitrates i only see single BR in manifest file
[23:31] <Rajeev> does anyone saw similar behaviour?
[23:41] <bunniefoofoo> llogan, is libfdk-aac any good, the license looks LGPL-ish to me which is what I'm after
[23:46] <Rajeev> instead of multiple Bitrates i only see single BR in manifest file
[00:00] --- Wed Jun  5 2013


More information about the Ffmpeg-devel-irc mailing list