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

burek burek021 at gmail.com
Sun Jul 14 02:05:01 CEST 2013


[00:20] <Wulf> Hi
[00:21] <Wulf> first time trying to use ffmpeg. I want to convert a part of a video to h.264, but not with high quality. I tried "-q:v 31" and "-q:v 1" and the resulting file size is the same.
[00:21] <Wulf> What am I doing wrong?
[00:21] <sacarasc> Try -crf
[00:22] <sacarasc> And don't specify a bitrate.
[00:23] <Wulf> sacarasc: I can't find "-crf" in the manual, and it doesn't work. "Trailing options were found on the commandline"
[00:24] <sacarasc> -crf is x264's quality control thing. Goes from 0 (lossless) to 51 (worst quality).
[00:26] <Wulf> sacarasc: okay, got it working. 51 looks really bad.
[00:27] <Wulf> 35 looks fine
[00:28] <Mavrik> that's probably why 23 or so is the default :P
[01:32] <roboman2444> so... opencl support...
[01:36] <llogan> used by deshake and unsharp filters. im not sure what else does
[01:38] <llogan> "highgod" would know more, but he's not here.
[02:44] <roboman2444> llogan, so no opencl for any encoding?
[02:44] <roboman2444> i would DEFINATELY love to encode 1080p video at like 200fps
[04:59] <uersbob> hi. im writing a simple screen capture program. i'm using the following line in ffmpeg ' -f image2pipe   -i pipe:.bmp  -c:v libx264  -y  "output.mp4"   'this works well, but the output video plays at 25fps (or whatever i set it to).  Is there a way to have the output play at the same speed as the capture speed?  the frame  rate changes constantly during each image save
[07:48] <blehtm> I'm trying to slice up a 60 second flac file into 15 second segments.  To get the first segment I use the following command: "ffmpeg -i infile.flac -acodec copy -t 15 -ss 15 outfile.flac".  But I'm having a problem.  When I load outfile.flac into VLC, the track slider still thinks it is 60 seconds long.  Any idea what gives?
[07:48] <blehtm> By the way once it reaches 15 seconds playback does stop as intended.
[07:49] <blehtm> (also, the command I showed would give the second segment, not the first, sorry)
[07:51] <roboman2444> uersbob, this is what i use... ffmpeg -threads 0 -i hw:0,0 -f x11grab -framerate 30 -s 1366x768 -r 30 -i :0.0+0,0 -vcodec libx264 -crf 16 output.mp4
[07:52] <mark4o> blehtm: what version?
[07:52] <roboman2444> -framerate 30 and -r might be the answer
[07:54] <blehtm> mark4o: "ffmpeg version N-54643-g15cee5e" on Windows 8, build from http://ffmpeg.zeranoe.com/builds/ 64-bit Shared version
[08:13] <mark4o> blehtm: I see the same issue
[08:15] <blehtm> interesting
[08:15] <mark4o> blehtm: re-encoding works, and is of course lossless
[08:15] <mark4o> looks like an issue/limitation with flac & -acodec copy
[08:16] <mark4o> may want to file a ticket; not sure if it is a known limitation
[12:08] <MojoRisin> hello there people
[12:08] <MojoRisin> Its been years since I've come in here :)
[12:09] <MojoRisin> I need some help with ffpeg streamng multicast... Been developing a small server for a lot of things, one of them being multicast streaming. I thought I could use vlc for it but the command line interface lacks information and i just simply cant do it
[12:10] <MojoRisin> so, i've turned to ffmpeg. I thought of a simple shell script to launch 2 streams over multicast. What is your recommendation for this? Should I use flv format and libx264 vcodec and mp3 as audio?
[12:11] <MojoRisin> i dont need quality - just need to make it work for a prototype
[12:34] <MojoRisin> nevermind, vlc appears to be  working
[12:34] <MojoRisin> ffmpeg and ffserver wold be better, but i need this to work asap
[12:34] <MojoRisin> cheers!
[12:47] <Russel-Athletic> hiho, i am trying to convert a vob file to mkv with this snd pass cmd: ffmpeg -i out.vob -c:v libx264 -preset slow -b:v 900k -pass 2 -c:a:1 libvorbis -qscale:a 6 output.mkv
[12:47] <Russel-Athletic> but somehow i get audio out of sync in the mkv
[12:47] <Russel-Athletic> in the vob everything is fine
[18:13] <EugenA> ffmpeg -threads 4 -i 00003.MTS -b:v 900k -vcodec mpeg2video -sameq -s 720x576 00003.mpg
[18:13] <EugenA> 1) why the bitrate is still about 7000 kbits/s ?
[18:13] <EugenA> 2) running only on 1 core, why?
[18:14] <sacarasc> You put the threads part in the decoding section, and you used -sameq.
[18:14] <klaxa> you are using -sameq, this is a) probably not what you think, b) discouraged c) messes with your quality settings
[18:15] <JEEB> 1) you set two differing rate control modes (bit rate and sameq which copies over quantizers from the origin [AKA not "same quality" if you thought it was that])
[18:15] <JEEB> 2) you most probably will need to try setting threads on the encoding side (after -i)
[18:15] <JEEB> if you want to set a bit rate, you set a bit rate. If you want to set a quality level, you set a quantizer or with libx264 a crf value.
[18:17] <EugenA> thank you, understood
[18:20] <EugenA> cpu is still not completly loaded: ffmpeg -i 00003.MTS -threads 4 -b:v 6000k -vcodec mpeg2video -s 720x576 00003.mpg
[18:21] <JEEB> then the encoder just isn't that well threaded or whatever :D
[18:21] <JEEB> what else can I say, really
[18:21] <EugenA> ok :-)
[22:03] <miguel_> Im trying to record my screen with ffmpeg, but the audio gets delayed
[22:03] <miguel_> is there an option I can set to change the delay?
[22:04] <miguel_> or to make sure the screen and audio recording start simultaneously?
[22:22] <MrE> Can ffmpeg overlay text based dvb subs on a live feed, its a live feed so I cant convert its subs to srt or ass first to use with the subtitles or ass filter, it has to be a oneliner :)
[22:23] <MrE> And why does copying the dvbsub track or encoding it as dvdsub result in a target stream/file that no player will open ? Is the dvbsub muxer just totaly broken ?
[22:24] <Mavrik> no to the first point
[22:24] <Mavrik> and yes to the second ;)
[22:26] <MrE> Haha ok fair enough :D
[22:31] <MrE> Mavrik Do you know about the status of overlaying picture based dvb subs then, seems to work with filter complex blah blah, but I just cant get those damn subs to be in the right place using anything larger than a sd source and sd target, on hd i end up with this :
[22:31] <MrE> http://10only.explode.dk/screenshot003.png
[22:32] <Mavrik> is that VLC?
[22:33] <MrE> The player is xbmc, its for a rather complex iptv system, but for that picture ffmpeg is the encoder using the overlay filter, but the sub location is quite odd
[22:33] <MrE> It gets worse when using a 1080i source
[22:33] <MrE> http://10only.explode.dk/screenshot004.png
[22:34] <Mavrik> yep
[22:34] <Mavrik> that's because you have picture subtitles
[22:34] <Mavrik> and those are always rendered at SD resolution
[22:34] <MrE> Aha so atm no way to fix that ? :)
[22:34] <Mavrik> and the DVB standard demands that TVs render them at 720x576 and then upscale
[22:34] <Mavrik> MrE, fix the filter ;)
[22:34] <Mavrik> send a patch.
[22:34] <Mavrik> :P
[22:35] <Mavrik> I wrote my own burn-in subtitle renderer for those cases so I have no idea what the state of current ffmpeg implementation is
[22:36] <MrE> VLC really got this working, just add soverlay to the transcode line, and --sub-language=dan
[22:37] <Mavrik> VLC has a failing subtitle renderer which doesn't upscale subtitles
[22:37] <Mavrik> at least it had in 2.0
[22:37] <MrE> But their encoder have all kinds of other bugs that makes it crap to use in my situation, we build it arround ffmpeg so it really only works good with that
[22:38] <Mavrik> MrE, what's your command line_
[22:38] <MrE> might have to find a solution to using vlc as the decoder and overlay, and then somehow pipe it as yuv to ffmpeg, with audio!!! thats the hard part hoho :)
[22:39] <MrE> for ffmpeg subtitle overlay with picture based subs ?
[22:40] <MrE> Pretty default the usual vcodec libx264 and all its setting and shit, and then this part for burning the subs
[22:40] <MrE> -filter_complex "[0:v][0:s]overlay[v]" -map [v] -map 0:a
[22:41] <Mavrik> MrE, well, did you try scaling the subtitle input before overlaying it?
[22:41] <MrE> No cant find any documentation on it
[22:42] <Mavrik> on what?
[22:42] <MrE> scaling subs
[22:42] <Mavrik> um
[22:42] <Mavrik> it's just a stream
[22:42] <Mavrik> apply scale filter to size of video
[22:43] <Mavrik> check the filter_complex syntax, it's not that hard
[22:43] <Mavrik> would be probably something like
[22:43] <Mavrik> [0:s]scale=1920:1080[scaled_subs],[0:v][scaled_subs]overlay[v]
[22:50] <MrE> Hmm that did something but not what was intended
[22:52] <Mavrik> well I did write it out of my head
[22:52] <Mavrik> :P
[22:53] <MrE> True but it should work, its still in the middle of the screen
[22:54] <MrE> This is my complete command
[22:54] <MrE> ./ffmpeg -re -threads 4 -analyzeduration $analyzeduration -y -i "$link" \
[22:54] <MrE> -vcodec libx264 -preset $x264preset -vb $x264vb -minrate $x264minrate -maxrate $x264maxrate -bufsize $x264bufsize -r 25 -g 25 -acodec copy -vf yadif=0,scale=$res1:$res2 -f mpegts \
[22:54] <MrE> -filter_complex "[0:s]scale=1920:1080[scaled_subs],[0:v][scaled_subs]overlay[v]" -map [v] -map 0:a \
[22:54] <MrE> "udp://$2:5501?ttl=1&pkt_size=1316&buffer=262140" &
[22:54] <MrE> $res1 is = 1280 $res2 is = 720
[22:56] <MrE> Heh my vf line is not evalutated with filter complex on also, gotta put that shit inhere also
[22:58] <Mavrik> doh
[22:58] <Mavrik> :)
[23:00] <MrE> [dvbsub @ 0x2979480] Invalid object location! 78-720 38-38 11
[23:05] <vhann> Hi, is there a way to normalize audio in a .avi,.mp4,etc. file so the max volume is 0 dB with ffmpeg? The manpage and Google don't seem to help me here
[23:06] <Mavrik> vhann, ffmpeg processes files sequentally so normalization really can't be done easly
[23:06] <Mavrik> (since ffmpeg doesn't know what max volume is)
[23:06] <MrE> Looks like they are located just where you would expect on a 720x576 resolution now but the size of the subs got better, how do i force the location to the bottom ?
[23:07] <Mavrik> MrE, overlay filter almost certanly has positioning parameters.
[23:07] <vhann> Mavrik: Oh ok. Thanks
[23:07] <Mavrik> vhann, if it helps, there is a volume audio filter (http://www.ffmpeg.org/ffmpeg-filters.html#volume) which allows you to change volume
[23:08] <MrE> Yeah but the man page its quite cryptic about em, oh well maybe i can find an example somewhere with google :p
[23:08] <Mavrik> vhann, there is also "volumedetect" filter which outputs volume stats
[23:09] <Mavrik> so using a script you can run ffmpeg first with volumedetect and use that output with "volume" filter to normalize it
[23:09] <Mavrik> MrE, don't read the man page
[23:09] <vhann> Mavrik: Yes, I'll experiment with this. If I'm lucky and it works, I might be able to run volumedetect, then calculate the needed amplification and rerun ffmpeg
[23:09] <Mavrik> MrE, read documentation pages I'm linking -_-
[23:10] <MrE> ye that was also what i ment
[23:10] <MrE> this page
[23:10] <MrE> http://ffmpeg.org/ffmpeg-all.html#overlay-1
[23:11] <Mavrik> yep
[23:11] <MrE> But already the first example
[23:11] <MrE> overlay=main_w-overlay_w-10:main_h-overlay_h-10
[23:11] <Mavrik> yes?
[23:11] <MrE> Does absolutely nothing to my subs, should locate then in the bottom right corner
[23:11] <MrE> them*
[23:12] <Mavrik> why are you just blindly typing random stuff from the internet without reading what it does? :P
[23:12] <MrE> Ehh
[23:12] <MrE> Draw the overlay at 10 pixels from the bottom right corner of the main video:
[23:13] <MrE> That shoud count for all overlays also subs ?
[23:13] <Mavrik> remember
[23:14] <Mavrik> you're incoming frames are 1920x1080 because you're scaling them beforehand
[23:19] <MrE> Hmm yeah a 1920x1080 image can only be overlayed at one fixed pos over another 1920x1080 image, so why do the subs end up in the middle of the screen :D
[23:19] <Mavrik> well
[23:19] <Mavrik> from which size are the subs resized from?
[23:22] <MrE> Hm no idea, my guess would be 720x576
[00:00] --- Sun Jul 14 2013


More information about the Ffmpeg-devel-irc mailing list