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

burek burek021 at gmail.com
Sun Jan 12 02:05:01 CET 2014


[00:10] <jnvsor> Can you give an input a name to map it with?
[00:10] <jnvsor> Or are input streams always numbered?
[00:13] <gusto> hey
[00:13] <gusto> i am having trouble wanting to extract subtitles from a file where the sub stream does not appear instantly
[00:15] <ubitux> jnvsor: you can map an input yes, but you're most likely interested in the output of the filtergraph
[00:15] <gusto> http://pastebin.com/8keh27fy here trying to do the extract
[00:16] <ubitux> your input has no subtitles
[00:16] <ubitux> and even if it had it would probably be dvd sub, which are bitmaps
[00:16] <ubitux> and you wouldn't be able to extract them with ffmpeg
[00:16] <ubitux> at best remux them into something like mkv
[00:17] <gusto> here the file again http://pastebin.com/eze3a4ZH
[00:17] <jnvsor> ubitux: No I've gotten past that. My issue now is how to map streams when I'm not sure which number of input files come before the ones I'm looking for
[00:18] <gusto> here doing remuxing into MKV http://pastebin.com/z3c090hh
[00:19] <ubitux> you probably need to use some kind of ifo index
[00:19] <ubitux> ffmpeg doesn't support that unfortunately, patch welcome
[00:19] <jnvsor> Oh dear. Well my work just got a lot more fun :P
[00:19] <ubitux> jnvsor: i don't understand at all
[00:20] <jnvsor> I'm writing a script for screencapping
[00:20] <jnvsor> It already supports multiple video streams, scaling, multiple audio streams etc
[00:21] <jnvsor> Now I'm trying to add filter_complex support for eg overlaying webcam onto video track 1
[00:21] <jnvsor> Problem is mapping the audio streams when you don't know how many video streams came before it
[00:22] <ubitux> why?
[00:23] <jnvsor> Well as it is I just have the user input the amount of video streams they have, loop over it and add `-map $i` for every stream
[00:23] <jnvsor> But if I'm mapping by name instead then I don't know when the audio streams start
[00:26] <ubitux> -map 0:v -map 0:a ?
[00:26] <jnvsor> That only maps the first stream. Ideally I'd have -map*:a
[00:27] <jnvsor> first file*
[00:27] <ubitux> maybe there is some kind of joker
[00:27] <ubitux> like -map v, or -map :v
[00:28] <gusto> ok
[00:28] <gusto> i seem to have found a way how to extract it from the original DVD
[00:28] <gusto> aaa, no
[00:29] <gusto> does not work :-(
[00:29] <gusto> w8, it works
[00:30] <gusto> http://pastebin.com/Bdw5TnuB
[00:31] <gusto> this way i should get at least the DVB SUB out in a MKV and will try to do something with it then
[00:34] <gusto> still no luck http://pastebin.com/egBHugkc
[00:37] <jnvsor> gusto: What's stopping you from just downloading fresh subs and using them?
[00:37] <gusto> i do not know
[00:38] <gusto> maybe its just curiosity if i d get it down from there
[00:38] <gusto> i ll try VLC once again, if it can put down those subs from the DVD, thats also worth a try
[00:38] <gusto> but apart from that, when it does not work, i ll stop trying
[01:53] <jnvsor> From the looks of it the copy and null filters do the same thing, but is there a performance difference between them?
[02:55] <reywood> hello, can anybody help with a subtitle question?
[02:56] <sacarasc> Only if you ask it.
[02:56] <reywood> heh
[02:56] <reywood> I have a subtitle track that should be displayed by default, like when one character in a movie speaks a different language, subtitles should always be shown for them
[02:57] <reywood> can't figure out how to specify that in the ffmpeg command
[02:57] <reywood> the command I'm currently using looks like this:
[02:57] <reywood> ffmpeg -i mymovie.mp4 -f srt -i mymovie.srt -c:v copy -c:a copy -c:s mov_text -metadata:s:s:0 language=eng mymovie-sub.mp4
[03:10] <relaxed> reywood: I'm curious why you want subs in mp4.
[03:11] <reywood> relaxed: I prefer to have it all in one file. Is there a reason not to?
[03:12] <relaxed> well, I think the matroska container would be a better choice.
[03:13] <reywood> ideally, I'd be able to play the video on an AppleTV which doesn't support mkv
[03:14] <relaxed> ugh, really?
[03:14] <reywood> if it's not possible to do what I want with mp4, that's fine, but I'd like to know
[03:14] <relaxed> let me see the console output from you command.
[03:14] <relaxed> pastebin.com
[03:17] <reywood> http://pastebin.com/s4Jxv6k2
[03:18] <reywood> if I was to use mkv, what would be the option?
[03:18] <hi117> http://j00ru.vexillium.org/?p=2211
[03:18] <hi117> keep up the good work!
[03:19] <relaxed> reywood: with matroska you could copy the srt along with the audio/video
[03:20] <relaxed> reywood: If all else fails you can hardsub them: https://trac.ffmpeg.org/wiki/How%20to%20burn%20subtitles%20into%20the%20video
[03:20] <reywood> yeah, I was hoping there was a way without hardsubbing
[03:21] <relaxed> are you sure appletv supports loading subs in mp4?
[03:21] <relaxed> you're command didn't have any errors.
[03:21] <relaxed> your*
[03:21] <reywood> relaxed: the subs are in the final mp4, they just aren't on by default, so If I play the movie, I have to manually select them
[03:22] <relaxed> hmm, maybe there's metadata to enable them by default
[03:22] <reywood> I haven't tried it on the appletv, I've played it in VLC on my comp
[03:23] <reywood> I tried setting "default=1" and "forced=1" in the metadata, no difference
[03:34] <relaxed> Maybe you can configure appletv to play subs by default. Other than that I'm out of ideas.
[03:35] <reywood> well thanks for your help anyway
[03:35] <reywood> much appreciated
[06:26] <rcombs> anyone know if libavcodec does anything special when converting an SRT stream in an RTL script to ASS?
[06:26] <rcombs> (i.e. does it reverse character order, or set the font encoding to Arabic/Hebrew as a hint for libass?)
[09:50] <Zeranoe> My input audio and video streams have a different number of frames, how could I output with the same?
[12:53] <jnvsor> If I overlay webcam into x11grab my framerate drops to ~20fps, regardless of how many threads I use. I presume something about my webcam input is bottlenecking it. Any ideas?
[14:20] <albator> hi all
[14:20] <albator> anybody has a little idea how to use named pipe to combine 2 files in one output?
[14:58] <jnvsor> You mean like an overlay?
[14:59] <jnvsor> Or are you looking for multiple tracks?
[15:59] <jnvsor> Anyone here intested in testing an FFmpeg based screen capture script? :D
[16:14] <Cigaes> Hi.
[16:49] <Bombo> i thought i understood the commandline, but now i get an error:
[16:49] <Bombo> /opt/bin/ffmpeg -i bar.mkv -c:v copy -c:a copy -c:a copy -i foo.mp4 -c:s copy -map 0:0 -map 0:1 -map 0:2 -map 1:3 baz.mkv
[16:51] <Bombo> i want to take video 0:0, audio 0:1, audio 0:2 from bar.mkv, then sub 1:3 from foo.mp4, mux it into baz.mkv (copy)
[16:51] <Bombo> error is: Unknown decoder 'copy'
[17:00] <albator> i mean like instead of having a disconnection after sending every single video to remote rtmp, using pipe to create a single input for ffmpeg
[17:01] <albator> but i don't know the proper syntax
[17:02] <jnvsor> Bombo: You have the codec parts next to the inputs so it's using them to *de*code the streams, try this:
[17:03] <jnvsor> Bombo: http://pastebin.com/RWaBhM3Q
[17:07] <Bombo> jnvsor: oh! right, thx ;)
[17:07] <Bombo> (btw no need for pastebin for just one line)
[17:15] <Bombo> hmmm is it possible to delay subs? they are like 3s late
[17:23] <Bombo> or i could just delay the rest ;)
[17:31] <jnvsor> Hmm "Data is not aligned. This can lead to a speed loss" - any way to tweak my filters to get rid of this error
[17:36] <Bombo> jnvsor: good question, i got these too
[17:38] <jnvsor> It only happens when the input is uneven width/height. I get that it should be even, that's why I scale it (To stop the encoder freaking out) but I'm wondering if there's some obscure setting that will pad the data in order to align it in some way
[17:41] <Bombo> not sure when i get it, i've just seen it often now, i do .mpg to .mp4 with scale=640:something
[17:42] <Bombo> when the height is odd it complains so i add or remove -1
[17:43] <jnvsor> Hehe, I have a trick for that: scale=w=trunc(in_w/2)*2:h=trunc(in_h/2)*2
[17:43] <jnvsor> add that after your first scale and it rounds it off for you automatically
[17:46] <Bombo> i do scale=640:in_h*out_w/sar/in_w
[17:47] <Bombo> so scale=640:in_h*out_w/sar/in_w,scale=w=trunc(in_w/2)*2:h=trunc(in_h/2)*2
[17:47] <Bombo> hmmm try it next time, thx ;)
[17:48] <Bombo> +i'll
[17:50] <jnvsor> It's designed for something like: scale=640:-1,scale=w=trunc(in_w/2)*2:h=trunc(in_h/2)*2
[18:06] <lkiesow> albator: /quit
[18:06] <albator> ?
[18:06] <lkiesow> sorry, ignore that ^^
[18:07] <albator> i better ignore yes lol
[18:16] <jnvsor> I'm trying to overlay my webcam onto an x11grab - that's all fine and dandy but my webcam's framerate is... sporadic... 30fps one second and 10fps the next. It's dragging my output framerate down even though x11grab is dropping frames to do it.
[19:07] <albator> ffmpeg -i test1.avi -i test2.avi -vcodec copy -acodec copy \
[19:07] <albator>                    -vcodec copy -acodec copy test12.avi
[19:07] <albator> is this supposed to encode test1 and test2 in a single file?
[19:07] <albator> because I am really trying with multiples input and I can't get past file1 , it doesn't do anything on following inputs
[19:25] <klaxa> albator: see: https://trac.ffmpeg.org/wiki/How%20to%20concatenate%20%28join,%20merge%29%20media%20files
[19:58] <albator> yes I saw that, it isn't working (the filelist.txt for instance)
[00:00] --- Sun Jan 12 2014


More information about the Ffmpeg-devel-irc mailing list