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

burek burek at teamnet.rs
Thu Oct 17 03:05:02 EEST 2019


[00:26:28 CEST] <ChrisJW> BtbN, you are correct I'm using nvdec. Thanks for the help. I'll try to create the context myself in this way
[00:58:54 CEST] <ChrisJW> Thanks BtbN, I am making some progress
[01:09:41 CEST] <furq> does the input bit depth make any difference to the aac encoder
[01:10:07 CEST] <furq> i.e. do i need to bother converting to 16-bit before encoding
[01:18:02 CEST] <cehoyos> The native aac encoder only accepts floats, so converting to "16-bit" will not help...
[01:18:38 CEST] <cehoyos> (libfdk requires converting to 16-bit)
[01:21:28 CEST] <furq> i know they both work
[01:21:41 CEST] <furq> they give different outputs so presumably one is better
[01:31:24 CEST] <cehoyos> Not sure I understand: libfdk is known as being the superior aac encoder (although not gpl-compatible) but this is not related to a 16-bit conversion...
[01:33:40 CEST] <furq> i meant the builtin aac encoder gives different output with 24-bit and 16-bit input
[01:34:59 CEST] <furq> specifically the qavg it prints when it's done is like 25% different
[01:35:07 CEST] <furq> unfortunately i don't know what that actually means
[01:35:07 CEST] <cehoyos> The builtin aac encoder does not work for 24-bit and does not work for 16-bit input
[01:35:24 CEST] <furq> yeah i'm sure it's being converted to fltp beforehand
[01:35:40 CEST] <cehoyos> But not by the aac encoder (and not by libavcodec)
[01:36:27 CEST] <cehoyos> If you first convert your 24-bit input to 16-bit before it gets converted to floats, I would assume that this hurts quality
[01:36:41 CEST] <cehoyos> (If it does not, I suspect this would indicate an encoder bug)
[01:38:04 CEST] <furq> they sound identical which is no surprise because the source files also sound identical to me
[01:38:23 CEST] <furq> i assume qavg is some kind of complexity metric, in which case i assume lower is better with constrained bitrate
[01:38:30 CEST] <furq> but it's not documented anywhere
[01:40:12 CEST] <furq> i know conventional wisdom with lame is to convert to 16-bit first, but i also know how much digital av conventional wisdom is "PhAZeR_666 posted it on doom9 in 2005"
[01:40:13 CEST] <cehoyos> You should not do more conversion steps than necessary and you should not throw away information before converting to float.
[01:41:05 CEST] <cehoyos> lame accepts floats, int16 and int32, I don't remember which of those will be converted internally by lame
[10:09:21 CEST] <amosbird> Hello, why do I get this error [mjpeg @ 0x561d9c2a2900] unable to decode APP fields: Invalid data found when processing input
[10:09:29 CEST] <amosbird> when doing /usr/bin/ffmpeg -f v4l2 -input_format mjpeg -i /dev/video0 -c:v copy -f rtsp -muxdelay 0.1 rtsp://localhost:5545/cam
[10:09:53 CEST] <amosbird> the webcam output like this https://la.wentropy.com/CpKd.png
[14:26:43 CEST] <match_it> hi everybody. I'm playng with ffmpeg and nginx. I'm producing an .avi file with a streaming hls source overlapping the video with a logo.png image. I'm trying to do the same with -f flv rtmp: output but the result is a completely BLACK VIDEO. Any idea ?
[14:28:22 CEST] <match_it> practically "seems" that -filter_complex option works fine just if the destination is a file on a disk and not an HLS output
[14:51:39 CEST] <th3_v0ice> I have two files. One is TS file recorded from antenna, the other is MP4 converted to TS. When I encode them using the API, in case of antenna TS audio encoder is reseting the timestamps, in case of MP4 -> TS, its not touching the timestamps. What is happening here?
[15:05:09 CEST] <OnkelTem> Hi all. I'm trying to convert an mp3 into m3u8 list with 10 seconds segment, but VLC doesn't play anything and prints error:  adaptive demux error: Failed to create demuxer (nil) Unknown
[15:05:13 CEST] <OnkelTem> The command I used was:
[15:05:49 CEST] <OnkelTem> ffmpeg -i music_29.mp3 -vn -c:a mp3 -hls_time 10 -hls_segment_type fmp4 -hls_flags append_list -f hls playlist/mp3mp4/list.m3u8
[15:06:22 CEST] <OnkelTem> it created 5 files in the target dir: init.mp4, list.m3u8, list[0-2].m4s
[15:08:52 CEST] <OnkelTem> What do I wrong?
[16:18:21 CEST] <th3_v0ice> Is there a way for aac encoder to preserve the timestamps?
[16:32:31 CEST] <BtbN> Encoders are not overly concerned with timestamps, and merely pass them through most of the time
[16:38:39 CEST] <DHE> especially for audio codecs which don't tend to reorder to even buffer much and require fixed input frame sizes
[16:52:11 CEST] <th3_v0ice> Error was in my code. Thanks for this info. I was resetting it to 0.
[18:10:35 CEST] <lyncher> hi. is it possible to use ffmpeg to add ID3 metadata to a MPEG-TS file?
[18:11:35 CEST] <lyncher> when using -metadata with a mp4 file, the metadata is added
[21:53:47 CEST] <ironm> Hello. Is it possible using ffmpeg to combine four FullHD/50fps mp4 video clips into one 4K/50fp mp4 output mp4 file? (just showing in four windows the FullHD clips in parallel)
[21:54:33 CEST] <JEEB> yes. there's a video filter or filters for that. (since I remember there being one for vertical and another for horizontal
[21:56:10 CEST] <durandal_1707> see stack filters
[21:56:30 CEST] <JEEB> right, those were the ones
[21:56:30 CEST] <ironm> Hello JEEB, thank you for the hint. I will have to check the filter functionality. I have tried some utilities like obs-studio, mplaye/mencoder etc
[21:56:40 CEST] <JEEB> I didn't remember the word used :)
[21:56:46 CEST] <JEEB> so hstack/vstack I think?
[21:56:50 CEST] <JEEB> horizontal|vertical
[21:56:52 CEST] <ironm> thank you durandal_1707
[21:57:00 CEST] <JEEB> oh there's even https://www.ffmpeg.org/ffmpeg-all.html#xstack
[21:57:01 CEST] <JEEB> now
[21:57:07 CEST] <JEEB> see the examples, I guess?
[21:57:22 CEST] <ironm> JEEB, thanks a lot, I will check the syntax
[21:57:45 CEST] <ironm> JEEB, great, I will check them asap
[21:59:13 CEST] <durandal_1707> see wiki about xstack
[21:59:22 CEST] <ironm> JEEB, another function I look for is to put two FullDH clips on different layers and to show them at once
[21:59:36 CEST] <ironm> great, thanks a lot durandal_1707
[22:00:19 CEST] <durandal_1707> http://trac.ffmpeg.org/wiki/Create%20a%20mosaic%20out%20of%20several%20input%20videos%20using%20xstack
[22:00:29 CEST] <ironm> ffmpeg is quite comfortable to split long clip in parts
[22:00:52 CEST] <ironm> durandal_1707, tnx :-)
[22:02:12 CEST] <ironm> exactly like that: "Display 4 inputs into 2x2 grid."
[22:22:01 CEST] <ironm> one question more: I need an mp4 output and the codec does not need to change.I am bit curios about: "c:v libx264 -t '50' -f matroska output_col_2x2.mp4"
[22:22:23 CEST] <ironm> what are other options than "matroska" ?
[22:22:52 CEST] <durandal_1707> that can be freely changed to anything you want
[22:25:46 CEST] <JEEB> wat
[22:25:56 CEST] <JEEB> forcing format to matroska and using the .mp4 extension?
[22:26:52 CEST] <ironm> JEEB, I don't want to force format matroska
[22:27:26 CEST] <ironm> I will remove the "-f matroska" option
[22:28:15 CEST] <ironm> the format should be the same as the format of inpunt files (mp4 from GoPro7)
[22:28:29 CEST] <ironm> !paste
[22:34:07 CEST] <ironm> It looks like I miss something: http://paste.debian.net/1107515/
[22:34:48 CEST] <ironm> xstack.sh: 2: xstack.sh: -filter_complex: not found
[22:39:13 CEST] <durandal_1707> ironm: missing \
[22:39:38 CEST] <durandal_1707> on first line
[22:43:17 CEST] <ironm> durandal_1707, right, thank you very much :-)
[22:43:27 CEST] <ironm> I try now with:   -map "[out]" -c:v copy -c:a copy output_col_2x2.mp4
[22:44:02 CEST] <ironm> ;-( ... Streamcopy requested for output stream 0:0, which is fed from a complex filtergraph. Filtering and streamcopy cannot be used together.
[22:46:09 CEST] <durandal_1707> ironm: you can not stream copy and have mosaic files
[22:48:32 CEST] <ironm> durandal_1707, I wanted to take over the original format of all mp4 inputs  (all of them have the same one)
[22:49:13 CEST] <durandal_1707> ironm: original format is already mp4
[22:55:24 CEST] <ironm> durandal_1707, yes, thank you. The output mp4 file (expected 360MBytes) has only 3.8MBytes - http://paste.debian.net/1107521/
[22:55:46 CEST] <ironm> It looks like I have to define 4K output
[22:56:28 CEST] <durandal_1707> ironm: i do not help with basic ffmpeg issues
[22:56:49 CEST] <ironm> durandal_1707, anyway, thank you very much
[22:57:26 CEST] <ironm> I have expected a default size ( 4 x FullDH = 4K )
[22:57:46 CEST] <ironm> because of for FullHD inputs
[22:57:50 CEST] <ironm> four
[22:58:11 CEST] <furq> then don't scale the inputs to qvga
[22:58:40 CEST] <ironm> a good hint! .. thank you
[23:00:05 CEST] <ironm> well, the syntax is new for me (xstack call)
[23:03:38 CEST] <durandal_1707> have you ever worked with ffmpeg?
[23:04:19 CEST] <ironm> durandal_1707, yes, I have splited long mp4 files unsing ffmpeg
[23:04:49 CEST] <ironm> normaly I use mplayer to display mp4 files
[23:05:14 CEST] <durandal_1707> mplayer is dead. do not use mplayer.
[23:05:16 CEST] <ironm> cool tool (ffmpeg)
[23:05:51 CEST] <ironm> durandal_1707, I can use another tool (if there are debian packages for it)
[23:06:41 CEST] <durandal_1707> debian packages are ultra old
[23:06:44 CEST] <pink_mist> durandal_1707: what do you mean "dead"? version 1.4 was released just a few months ago
[23:06:49 CEST] <durandal_1707> use mpv player
[23:06:55 CEST] <durandal_1707> mplayer is dead.
[23:07:01 CEST] <ironm> durandal_1707, thank you
[23:07:02 CEST] <pink_mist> latest version of mpv was released more than a year ago
[23:07:21 CEST] <durandal_1707> mpv have nightly versions
[23:07:21 CEST] <ironm> apt-get install mpv
[23:07:38 CEST] <durandal_1707> that will install pra historic version, avoid at all cost
[23:07:49 CEST] <ironm> mpv 0.29.1 Copyright © 2000-2018 mpv/MPlayer/mplayer2 projects
[23:07:57 CEST] <durandal_1707> yes, very old
[23:07:59 CEST] <pink_mist> yeah, that's the latest version of mpv
[23:08:06 CEST] <ironm> just debian
[23:08:25 CEST] <durandal_1707> no, latest version is : [cplayer] mpv 0.29.0-842-gf0f1387145 Copyright © 2000-2019 mpv/MPlayer/mplayer2 projects
[23:08:28 CEST] <durandal_1707> [cplayer]  built on Tue Oct 15 18:51:18 CEST 2019
[23:08:53 CEST] <pink_mist> no, that's a nightly, not a released version
[23:09:04 CEST] <durandal_1707> use nightly all the time
[23:09:39 CEST] <durandal_1707> real users compile own software
[23:10:48 CEST] <durandal_1707> ironm: with mpv you can use all ffmpeg filters, with mplayer you can not.
[23:11:42 CEST] <ironm> durandal_1707, I will check mpv in detail.
[23:12:16 CEST] <ironm> at the moment I am guessing for possible values of the scale option
[23:12:33 CEST] <ironm>       [0:v] setpts=PTS-STARTPTS, scale=1 [a0]; \
[23:12:52 CEST] <ironm> [AVFilterGraph @ 0x5568542d1ac0] Error initializing filter 'scale' with args '1'
[23:12:56 CEST] <durandal_1707> you do not need scale
[23:13:32 CEST] <durandal_1707> and setpts only if you need all timestamps to start from 0 when mosaicing video
[23:14:38 CEST] <ironm> durandal_1707,  I try to follow what you say. What would be the correct syntax of the line? .. "      [0:v] setpts=PTS-STARTPTS, scale=false [a0]; \"
[23:14:55 CEST] <durandal_1707> just remove scale  REMOVE SCALE
[23:15:12 CEST] <durandal_1707> and , with it
[23:15:21 CEST] <ironm> durandal_1707,  I did it before, but then I have got another error message
[23:15:46 CEST] <durandal_1707> this is all basic ffmpeg usages issues, that complete ffmpeg novice get
[23:16:28 CEST] <durandal_1707> just:    [0:v] setpts=PTS-STARTPTS[a0];
[23:16:38 CEST] <ironm> durandal_1707, that is a question of the syntax consistency
[23:16:51 CEST] <durandal_1707> huh?
[23:17:01 CEST] <ironm> exactly, I did it just and it is ongoing now
[23:17:38 CEST] <ironm> durandal_1707,  with the consistency I mean scale=1 (otr scale=false etc.)
[23:17:50 CEST] <durandal_1707> no, that is nonsense
[23:18:12 CEST] <durandal_1707> ffmpeg -h filter=scale
[23:18:14 CEST] <ironm> durandal_1707, now it looks fine:     Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuvj420p(pc), 3840x2160 [SAR 1:1 DAR 16:9], q=-1--1, 50 fps, 12800 tbn, 50 tbc (default)
[23:18:19 CEST] <durandal_1707> see its options
[23:18:49 CEST] <ironm> durandal_1707, thanks a lot for all hints hints
[23:21:27 CEST] <ironm> durandal_1707, somehow the mp4 output is two times smaller all four mp4 input files
[23:22:31 CEST] <durandal_1707>  ironm: use higher bitrate, again ffmpeg basic
[23:22:43 CEST] <durandal_1707> read some ffmpeg book first
[23:23:32 CEST] <ironm> durandal_1707, yes, I will do. Thanks a lot
[23:23:50 CEST] <durandal_1707> or use relatively small scale factor
[23:24:00 CEST] <ironm> I will check different options and play with them a bit
[23:24:33 CEST] <ironm> well, I don't need to scale ( 4 x FullHD = 1 x 4K )
[23:24:44 CEST] <ironm> it is fine for me
[23:25:55 CEST] <ironm> I am only a bit curious about the smaller size, as I did not expect any compression (only 1 to 1 copyof all inputs)
[23:26:05 CEST] <durandal_1707> ironm: QUALITY scale, not video scale
[23:26:18 CEST] <ironm> OMM
[23:26:44 CEST] <ironm> I need to read more about ffmpeg
[23:27:12 CEST] <kepstin> ironm: output bitrate has nothing to do with input bitrate. you have to pick the output quality or bitrate setting, if you don't specify then it uses some arbitrary defaults
[23:29:06 CEST] <ironm> kepstin, thank you. I thought the 50fps from all FullHD inputs will end in 50fps in the output file
[23:29:19 CEST] <ironm> the 4K output file
[23:29:22 CEST] <kepstin> it should unless you have timestamp sync issues
[23:29:35 CEST] <ironm> kepstin, a good question
[23:29:35 CEST] <kepstin> that's *another* thing different from bitrate
[23:29:59 CEST] <kepstin> framerate, resolution, and final output size are all controlled separately
[23:31:16 CEST] <durandal_1707> ironm: make sure your videos are constant frame rate and not variable frame rate
[23:31:43 CEST] <ironm> kepstin, my current xstack.sh (ffmpeg) - http://paste.debian.net/1107527/
[23:32:13 CEST] <kepstin> if the inputs are not consistent and you want the output to be, then the easiest fix is to run an fps filter separately on each input before stacking them
[23:32:15 CEST] <ironm> probably I don't need to set: "setpts=PTS-STARTPTS"
[23:32:41 CEST] <ironm> kepstin, alle inputs are from GoPro 7 hero balck
[23:32:45 CEST] <ironm> black
[23:33:00 CEST] <ironm> and all are set to FullHD 50fps
[23:33:08 CEST] <ironm> linear mode
[23:34:11 CEST] <ironm> 4K 60fps offers only the wide mode. The internal CPU of GoPro7 is not fast enough for 4K)
[23:34:25 CEST] <durandal_1707> you could run: ffmpeg -i one_of_input_videos -vf vfrdet -f null -
[23:34:38 CEST] <durandal_1707> it will report how clean are timestamps
[23:35:05 CEST] <ironm> durandal_1707, thanks a lot, I will check it
[23:35:54 CEST] <ironm> [Parsed_vfrdet_0 @ 0x55bdf4b57a00] VFR:0.000000 (0/849)
[23:36:30 CEST] <durandal_1707> perfect
[23:37:02 CEST] <ironm> durandal_1707, I will check it for all input files
[23:39:59 CEST] <ironm> all of input files have like: VFR:0.000000 (0/749)
[23:40:23 CEST] <durandal_1707> huh, they should have same duration, number of frames?
[23:41:01 CEST] <ironm> durandal_1707, well, there are two pairs ... 15 and 17 seconds long
[23:41:13 CEST] <ironm> that is ok
[23:41:58 CEST] <durandal_1707> so why you think output is not 50fps ?
[23:43:30 CEST] <ironm> durandal_1707, because the size of the output file is two time smaller than the sum of all mp4 inputs
[23:43:42 CEST] <ironm> but the output has 50fps
[23:43:45 CEST] <ironm> VIDEO:  [H264]  3840x2160  24bpp  50.000 fps  92163.6 kbps (11250.4 kbyte/s)
[23:45:12 CEST] <durandal_1707> ironm: please study: http://trac.ffmpeg.org/wiki/Encode/H.264
[23:45:15 CEST] <kepstin> video resolution (picture size), framerate, and bitrate (output file size) are all *completely unrelated*
[23:45:41 CEST] <ironm> strange, I see 50fps in the mplayer output, but it is going on like slow motion
[23:45:44 CEST] <kepstin> well, aside from that it's hard to tell x264 to make a really big video if the picture size and framerate are small
[23:46:40 CEST] <durandal_1707> ironm: make sure your machine can actually play 4k 50fps in real time
[23:46:56 CEST] <ironm> kepstin, thanks a lot. I am quite new to the usage of ffmpeg to prepare 4K mp4 files (using FullHD mp4 inputs)
[23:47:13 CEST] <kepstin> yeah, that's most likely the problem. Note that if you use mpv rather than mplayer, it supports using hardware decoders (if you have one, and it can do 4k...)
[23:47:50 CEST] <ironm> durandal_1707, exactly. It is a xeon cpu with 32GBytes of DDR3 (rather slow compare to DDR4)
[23:48:17 CEST] <ironm> kepstin, I will try mpv now
[23:49:10 CEST] <kepstin> "xeon cpu" means nothing, and ram is not usually the limiting factor in video encoding or decoding speed.
[23:49:17 CEST] <ironm> kepstin, YES, mpv is running with normal speed
[23:49:50 CEST] <ironm> Well, it is GT1050 passive graphic card
[23:50:10 CEST] <kepstin> alright, so *that* makes a difference.
[23:50:23 CEST] <ironm> kepstin,  a BIG difference
[23:50:28 CEST] <kepstin> 1050 has a reasonably competent hw encoder and decoder
[23:50:54 CEST] <kepstin> (although i don't think mpv will use it by default, your improvement's most likely just due to bug fixes and a more efficient video out)
[23:50:56 CEST] <BtbN> Isn't the encoder disabled on the GTs?
[23:51:02 CEST] <ironm> mplayer seems not to support them (looks like)
[23:51:04 CEST] <BtbN> Never checked on the latest ones
[23:51:06 CEST] <kepstin> 1050 is only a GTX card
[23:51:11 CEST] <kepstin> GT 1030 has not hw encoder
[23:51:17 CEST] <kepstin> has no*
[23:51:24 CEST] <BtbN> oh, yeah. Was about to say, GT1050 sounds strange
[23:51:40 CEST] <kepstin> gt 1030 still has the hw decoder tho, that works fine
[23:54:21 CEST] <ironm> kepstin, sorry, it is: Palit GeForce GTX 1050 Ti KalmX (4GB, Midrange)
[23:54:38 CEST] <ironm> BtbN, Hi, ^^^^
[23:57:49 CEST] <ironm> kepstin, mpv seems to be the better option than mplayer
[00:00:00 CEST] --- Thu Oct 17 2019


More information about the Ffmpeg-devel-irc mailing list