[Ffmpeg-devel-irc] ffmpeg.log.20190224
burek
burek021 at gmail.com
Mon Feb 25 03:05:02 EET 2019
[03:35:15 CET] <mcurran> can anyone help me fix a (mp4) file i got from an embedded facebook video with wget? The moov file and streaming information isn't correct for vlc, so I need to reencode it somehow and was wondering if ffmpeg has that capability.
[03:39:37 CET] <DHE> usually: ffmpeg -i input.mp4 -c copy -movflags faststart output.mp4
[10:20:53 CET] <Paramonins> Why ffmpeg streaming speed is falling below 1x when I am broadcasting to youtube? I have posted more details about the problem here https://stackoverflow.com/questions/54850458/ffmpeg-youtube-streaming-quality-and-speed-issues please help
[14:37:46 CET] <jaggz> how do I optimize this video that's mostly a slideshow? but it was streaming so there's some wiggling from encoding.. I want to shrink it down.
[14:38:43 CET] <Hello71> perhaps mpdecimate
[14:39:22 CET] <jaggz> Hello71, hallooo
[14:39:28 CET] <Hello71> no
[14:40:02 CET] <jaggz> Hello71, can it be used with crf?
[14:40:14 CET] <Hello71> wat
[14:40:28 CET] <jaggz> or do I use -b:v ?
[14:41:20 CET] <jaggz> I'm not that familiar with this, but I believe something like -b:v sets a fixed video rate, while -crf sets a quality rate to keep (and the bitrate might vary)
[14:44:08 CET] <jaggz> You cannot combine mpdecimate and mov/mp4 output in a useful way
[14:44:08 CET] <jaggz> because our mov/mp4 muxer only supports constant frame rate, this
[14:44:08 CET] <jaggz> is a known limitation of FFmpeg.
[14:44:12 CET] <jaggz> good to know :)
[14:44:30 CET] <jaggz> https://stackoverflow.com/questions/37088517/ffmpeg-remove-sequentially-duplicate-frames/37089629
[14:51:04 CET] <jaggz> https://amiaopensource.github.io/ffmprovisr/#about
[14:51:41 CET] <jaggz> cookbook of ffmpeg commands.. I think
[17:32:26 CET] <faLUCE> hello, I'm trying to change the h264 bitrate on the fly, with libav. I found this function: static void reconfig_encoder(AVCodecContext *ctx, const AVFrame *frame), in libx264.c, but it's not in the API. Nor can I extract a X264Context fro the CodecContext, because X264Context is not in the API too. So, Is there a way to get the x264 handler so I can call the reconfig() function of the x264 API ?
[17:34:07 CET] <JEEB> what do you mean with the word libav?
[17:34:12 CET] <JEEB> if you mean libavcodec within FFmpeg
[17:34:15 CET] <JEEB> then call it lavc
[17:34:16 CET] <JEEB> please
[17:34:23 CET] <JEEB> or just avcodec
[17:34:41 CET] <faLUCE> I mean libavcodec
[17:34:50 CET] <JEEB> not because I have anything against the Libav project, because I don't - just because that project exists and named itself libav
[17:35:09 CET] <JEEB> and thus just saying "libav" is in that sentence is not clear :P
[17:35:17 CET] <JEEB> yes, ok
[17:35:34 CET] <JEEB> faLUCE: see where that static function is called
[17:35:44 CET] <faLUCE> in libx264 itself
[17:35:46 CET] <JEEB> I'm pretty darn sure it gets called during when you feed the encoder an AVFrame
[17:35:50 CET] <faLUCE> in libx264.c itself
[17:35:52 CET] <JEEB> in the lavc libx264 wrapper
[17:37:25 CET] <faLUCE> JEEB: it only called in libx264.c, not in an API function
[17:37:42 CET] <JEEB> which is called from the API
[17:37:49 CET] <JEEB> just read what I just said
[17:37:50 CET] <JEEB> please
[17:37:55 CET] <JEEB> stop annoying people by not looking
[17:43:29 CET] <faLUCE> JEEB: if you don't want to answer, nobody forces you to do that. And stop telling me what I have to do with netiquette. That said, X264Context is private too, as said before. And the only way to access a LIBX264 encoder is accessing the X264Context->enc field
[17:43:49 CET] <JEEB> jesus christ
[17:44:17 CET] <JEEB> you are complaining that you cannot access reconfig_encoder in lavc/libx264.c
[17:44:28 CET] <JEEB> yet you have not looked where it's called within that file!
[17:44:28 CET] <faLUCE> JEEB: you did not read well my msg
[17:44:43 CET] <faLUCE> "Nor can I extract a X264Context fro the CodecContext, because X264Context is not in the API too. So, Is there a way to get the x264 handler so I can call the reconfig() function of the x264 API ?"
[17:45:15 CET] <JEEB> why do you need the x264 API context to begin with? you're trying to break through the abstraction
[17:45:26 CET] <JEEB> see where reconfig_encoder is getting called?!
[17:45:46 CET] <JEEB> and if you really are that blind, it's called in "X264_frame"
[17:45:57 CET] <JEEB> which is the encode function where you push a new AVFrame into the encoder
[17:46:11 CET] <JEEB> so you don't need to break through the darn abstractions if you just want to reconfigure
[17:46:18 CET] <JEEB> unless what you need to reconfigure is not supported
[17:46:25 CET] <JEEB> which you can you know - add support for
[17:46:35 CET] <JEEB> I don't get how you can look at lavc/libx264.c and not notice this stuff
[17:47:09 CET] <JEEB> I specifically told you to look at where reconfig_encoder is used in lavc/libx264.c
[17:47:21 CET] <JEEB> and you could have gotten the feeling of "oh, so I can use it like this"
[17:47:33 CET] <faLUCE> X264_frame()
[17:47:56 CET] <faLUCE> which is linked to encode2() (??) function
[17:48:16 CET] <JEEB> see the AVCodec definition for x264 at the bottom
[17:48:22 CET] <JEEB> ff_libx264_encoder
[17:48:35 CET] <faLUCE> I saqw it
[17:48:35 CET] <JEEB> that sets encode2 to ?
[17:49:03 CET] <faLUCE> I just wrote:
[17:49:07 CET] <faLUCE> "which is linked to encode2() (??) function"
[17:49:19 CET] <JEEB> ok
[17:49:27 CET] <JEEB> this is how libavcodec works
[17:49:47 CET] <JEEB> effectively your encoding function calls when you encode stuff end up calling that function with the AVFrame etc
[17:49:58 CET] <JEEB> that's how libavcodec encoders (and decoders) work
[17:50:08 CET] <faLUCE> then the functions names ARE WRONG
[17:50:12 CET] <JEEB> why?
[17:50:43 CET] <faLUCE> because it reconfigures the frame at each encoding
[17:50:55 CET] <faLUCE> it's not "reconfigure", but "configure"
[17:51:40 CET] <JEEB> it checks various values if they have changed that a user might want to reconfigure
[17:51:44 CET] <JEEB> and if they change it reconfigures
[17:51:47 CET] <JEEB> wtf is wrong for that
[17:52:08 CET] <faLUCE> reconfigure means RECONFIGURE. not "reconfigure_if_necessary
[17:52:10 CET] <faLUCE> "
[17:52:26 CET] Action: JEEB facepalms
[17:52:44 CET] <JEEB> ok, you could make the function name even longer but I don't consider it incorrect
[17:52:49 CET] <JEEB> also at that point you're looking at the internals
[17:52:50 CET] <pink_mist> faLUCE: you're welcome to fork ffmpeg and rename the function to reconfigure_if_necessary if you want
[17:52:50 CET] <JEEB> you see the code
[17:53:11 CET] <faLUCE> I consider so. In fact I thought it was a wrap for libx264 reconfigure(). It is not.
[17:53:21 CET] <JEEB> but it is a wrapper oer it
[17:53:28 CET] <JEEB> it just checks if various values have actually changed
[17:54:06 CET] <JEEB> like, by default reconfigurations can be expensive so while you want to support them you generally want to make sure that you've actually changed something
[17:54:10 CET] <JEEB> but whatever
[17:54:31 CET] <JEEB> now you know how you can reconfigure without actually having to break down the abstractions
[17:54:33 CET] <faLUCE> JEEB: I don't want to speak about useless things. It's unclear. stop. And nobody can guess that a "reconfigure" function, without any check before its call could be called at each encoding
[17:54:48 CET] <faLUCE> please stop insisting.
[17:54:55 CET] <faLUCE> now, let's do my job
[17:55:01 CET] <JEEB> no, you do your job
[17:55:15 CET] <pink_mist> brilliant, you made him leave
[20:34:09 CET] <trysten> I don't understand the conflict. Is it really about a function name?
[21:16:11 CET] <faLUCE> trysten: it's because the encode() function always calls a reconfigure() function. Check if the reconfigure must be done is inside that function, then an user can't understand what the function does really (and there's not a ret value check, in addition)
[21:17:45 CET] <faLUCE> trysten: but JEEB is too much sure about his convinctions. I'm not interested in discussing in this useless stuff
[21:20:45 CET] <faLUCE> the x264 reconfig_encoder function is properly written, because it returns a value which tells if the operation is done
[21:20:50 CET] <faLUCE> but the ffmpeg's one is void
[21:21:47 CET] <faLUCE> but JEEB would not admit that
[21:23:58 CET] <durandal_1707> faLUCE: stop talking shit
[22:34:05 CET] <trysten> durandal_1707: seems like they're just expressing their opinion that the function is improperly named while english is not their first language
[22:34:29 CET] <trysten> Seems to be self-contradicting though, saying they don't want to talk about useless stuff then arguging about function names
[22:34:50 CET] <trysten> Sorry, shouldn't have pinged.
[22:54:43 CET] <Hello71> brilliant, you made him leave
[23:04:22 CET] <c3r1c3-Win> They'll be back.
[00:00:00 CET] --- Mon Feb 25 2019
More information about the Ffmpeg-devel-irc
mailing list