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

burek burek at teamnet.rs
Sun Oct 6 03:06:08 EEST 2019


[00:02:41 CEST] <DHE> well the second transcodes. the first just copies the existing audio
[00:04:40 CEST] <snatcher> DHE: transcodes to what and why?
[00:04:56 CEST] <Diag> well arent you adding text?
[00:06:59 CEST] <DHE> traditionally transcodes to the default codec as specified by the output file format, and because that's the default and you didn't override it
[00:37:41 CEST] <furq> does chromaprint even work with -c:a copy
[00:37:49 CEST] <furq> i thought the library required pcm
[01:19:27 CEST] <snatcher> /dev/shm/FILENAME doesn't work as value for filename= of signature filter while regular path works, is it bug?
[01:19:59 CEST] <snatcher> typo, nevermind
[01:57:13 CEST] <snatcher> i give up, don't understand chromaprint muxer at all, how can i get fingerprint of audio stream from video in binary format? tried: ffmpeg -y -loglevel fatal -f mp4 -vn -i FILE -f chromaprint - | base64 -d >BIN, seems doesn't work because outputs incorrect base64, or >    Base64 compressed fingerprint (default)
[01:57:27 CEST] <snatcher> means something more than base64?
[01:59:07 CEST] <snatcher> or chromaprint muxer is broken, can anyone test it please? ffmpeg version 4.2
[02:24:08 CEST] <snatcher> segmentation fault with -f chromaprint -algorithm 2, looks deprecated/broken
[02:45:57 CEST] <taliho> snatcher: if you get a segfault you should post a ticket on ffmpeg trac
[02:48:35 CEST] <furq> you should probably report -fp_format not working as well
[02:50:14 CEST] <snatcher> furq: what about broken base64 output?
[02:50:26 CEST] <Atlenohen> Hello
[02:50:50 CEST] <Atlenohen> it is possible with FFMPEG to concat many video files but insert text between them directly with ffmpeg
[02:51:18 CEST] <Atlenohen> custom text, but filename works as I only want between each video the TITLE of the video
[02:51:47 CEST] <Atlenohen> But without having to painstakingly use a video editor to do every video title manually
[02:52:23 CEST] <taliho> snatcher: I tried ./ffmpeg -i input_file.mp4 -acodec pcm_s16be -f chromaprint out
[02:53:16 CEST] <taliho> seems to work for me, I confirm I got a segfault with -algorithm 2 option
[02:54:12 CEST] <taliho> to be clear..  the command above seems to work for me. But, I confirm got a segfault with -algorithm 2option
[02:55:26 CEST] <snatcher> taliho: does (base64 -d out >outbin) work for you?
[02:58:53 CEST] <furq> are you sure you don't want pcm_s16le
[02:59:47 CEST] <snatcher> furq: pcm_s16le doesn't make any difference while ffmpeg outputs incorrect base64
[03:00:45 CEST] <snatcher> *not base64
[03:00:59 CEST] <taliho> my machine is little endian, so yes it makes more sense
[03:01:58 CEST] <taliho> snatcher: I'm reading base64 option
[03:03:18 CEST] <snatcher> taliho: it's not option, it's shell command where out is your ffmpeg command out and outbin should be valid binary fingerprint
[03:05:25 CEST] <snatcher> also i think -acodec doesn't make any difference because i tried on flac file and same flac with some changed bytes and got the same checksum for _broken_ (not base64) output
[03:09:59 CEST] <taliho> snatcher: I would have to have a look at what is done in the code
[03:10:56 CEST] <taliho> if I pipe output to base64 -d then I get invalid input. becase input is not in base64
[03:11:32 CEST] <furq> https://github.com/ffmpeg/ffmpeg/blob/master/libavformat/chromaprint.c#L143
[03:11:38 CEST] <furq> it's just calling libchromaprint
[03:12:08 CEST] <furq> so i guess check if that works first
[03:12:19 CEST] <taliho> in ffmpeg options there is a base64 option with chromaprint, which suggests you need to set it to get a base64 output
[03:12:47 CEST] <snatcher> taliho: default one
[03:12:56 CEST] <furq> yeah that's the last argument to chromaprint_encode_fingerprint
[03:14:29 CEST] <snatcher> furq: fpcalc from libchromaprint works(?)
[03:15:25 CEST] <furq> fun
[03:15:36 CEST] <taliho> but base64 is default value
[03:15:49 CEST] <taliho> so something looks off to me
[03:16:03 CEST] <snatcher> https://github.com/acoustid/chromaprint/blob/1839652b3ff5aaf124cf20fccc8ecdfbce1f064d/src/cmd/fpcalc.cpp
[03:16:34 CEST] <furq> i wouldn't be massively surprised if ffmpeg is at fault, it looks like this file has been touched once since it was added four years ago and that was just to update the chromaprint version check
[03:17:14 CEST] <furq> but you should obviously triple check before submitting a bug report
[03:18:36 CEST] <furq> [chromaprint muxer @ 0x7fffc60deac0] Unable to parse option value "base64"
[03:18:37 CEST] <furq> nice
[03:24:00 CEST] <taliho> furq: yeah have the same issue
[03:24:16 CEST] <snatcher> what will happen with chromaprint support if no one will fix it? removal?
[03:25:45 CEST] <furq> someone will probably just fix it
[03:40:09 CEST] <snatcher> is there a way to extract all audio streams to separate files automatically?
[03:40:33 CEST] <snatcher> *from video
[05:06:07 CEST] <taliho> snatcher: furq: I've at least found the bug that doesn't allow to set fp_format options
[05:06:24 CEST] <taliho> i'll send it to the mailing list in a bit
[07:23:33 CEST] <taliho> snatcher: It's possible that the output chromaprint is in url save version where / are replaced by _
[07:23:57 CEST] <taliho> sorry *safe not save
[07:24:43 CEST] <taliho> I tried replacing _ with / in the output of ffmpeg and base64 -d seems to work
[15:40:09 CEST] <taliho> :snatcher did you see my message about chromaprint?
[16:22:14 CEST] <snatcher> taliho: still base64: invalid input
[16:23:07 CEST] <taliho> can you paste the base64 output?
[16:24:11 CEST] <snatcher> taliho: https://clbin.com/uyztO
[16:27:38 CEST] <snatcher> taliho: generated with: ffmpeg -i 1.flac -acodec pcm_s16le -f chromaprint out
[16:31:38 CEST] <taliho> I wonder if it just doesn't like the new line character at the end
[16:36:11 CEST] <snatcher> no, same result after: tr -d '\n'
[16:38:43 CEST] <snatcher> i think it's not base64 encoded fingeprint somehow, just plain one, if so don't know why ffmpeg plain fingerprint much bigger than fpcalc -plain one
[16:51:56 CEST] <taliho> snatcher: i'm quite sure it's something with new lines
[16:51:58 CEST] <taliho> try this
[16:52:47 CEST] <taliho> echo "hello" | base64 | base64 -d
[16:52:50 CEST] <taliho> this works
[16:52:55 CEST] <taliho> but
[16:54:28 CEST] <taliho> ignore my message above :)
[16:57:40 CEST] <taliho> :snatcher another option is that you could do base64 yourself
[16:57:50 CEST] <taliho> ./ffmpeg -loglevel trace -y -i input_file.mp4 -vn -acodec pcm_s16le -f chromaprint -fp_format raw - | base64
[16:59:41 CEST] <taliho> :snatcher I posted a patch for parsing raw option, because it doesn't work at the moment
[16:59:43 CEST] <taliho> http://ffmpeg.org/pipermail/ffmpeg-devel/2019-October/251029.html
[17:01:57 CEST] <taliho> :snatcher if you don't want to apply the patch, you could the same with
[17:02:33 CEST] <taliho> ffmpeg -loglevel trace -y -i input_file.mp4 -vn -acodec pcm_s16le -f chromaprint -fp_format 0 - | base64
[17:08:05 CEST] <relaxed> for tidiness you may want ... -fp_format 0 - 2>ffmpeg.log | base64
[17:24:07 CEST] <void09> how to cut at precise time without re-encoding the whole video, just the first and last frames leading to their nearest keyframe ?
[17:34:13 CEST] <taliho> :snatcher ok, the issue is that chromaprint is using "URL and filename safe version" of base64 and so it contains "underscore" and "-"
[17:34:15 CEST] <taliho> https://tools.ietf.org/html/rfc4648#section-5
[18:22:11 CEST] <Atlenohen> Hello
[18:22:27 CEST] <Atlenohen> is it possible to use ffmpeg to insert automatically some kind of text between concated videos?
[18:23:16 CEST] <Atlenohen> or if that won't be possible, what if I just insert some transitional effect or a transitional short clip between videos, if not filename title text, at least it separates them apart
[18:23:32 CEST] <Atlenohen> they're multiple videos like 30, but short, want them all in one file for convenience
[18:24:29 CEST] <tdr> couldn't you make an image/frame, turn that into a very short clip, then use the clip(s) as part of your concat process?
[18:25:18 CEST] <tdr> it would be more manual since you'd have to specify order / where to put the middle clips, but should be doable
[18:42:29 CEST] <Atlenohen> I'd like to avoid reconversion and painstakingly manually doing the titles one by one
[18:43:59 CEST] <relaxed> transcoding will be necessary unless they were encoding the same exact way
[18:44:52 CEST] <relaxed> encoded*
[18:46:23 CEST] <relaxed> as tdr said, script using the filenames to create a short video with that text to concat in between the videos
[18:48:06 CEST] <relaxed> look at the drawtext filter
[18:56:18 CEST] <Atlenohen> ah ok will take a look
[18:59:05 CEST] <relaxed> Atlenohen: remember to add a silent audio track to them in order to concat with the other videos
[19:11:56 CEST] <Atlenohen> concat unsafe filename?
[19:11:59 CEST] <Atlenohen> minus signs?
[19:14:52 CEST] <Atlenohen> looks like it's about quotes in this case
[19:18:32 CEST] <Atlenohen> looking at https://stackoverflow.com/questions/38996925/ffmpeg-concat-unsafe-file-name
[19:18:41 CEST] <Atlenohen> i have "file D:\ ...
[19:18:44 CEST] <Atlenohen> not sure
[19:18:49 CEST] <Atlenohen> not quotes
[19:26:44 CEST] <relaxed> you added -safe 0?
[20:03:39 CEST] <taliho> :snatcher you can recreate what chromaprint is doing
[20:03:51 CEST] <taliho> ffmpeg -loglevel trace -y -i input_file.mp4 -vn -acodec pcm_s16le -f chromaprint -fp_format compressed - 2>/dev/null | base64
[20:04:24 CEST] <taliho> ffmpeg -loglevel trace -y -i input_file.mp4 -vn -acodec pcm_s16le -f chromaprint -fp_format base64 - 2>/dev/null
[20:06:20 CEST] <taliho> are the same except "/" -> "underscores" and "+" -> "-"
[20:06:46 CEST] <taliho> also base64 in bash adds padding with == at the end
[20:14:42 CEST] <Atlenohen> I did try safe too yeah
[20:14:48 CEST] <Atlenohen> I'll be back later, gtg
[20:43:46 CEST] <taliho> :snatcher I also fixed a bug when writing with raw format... ffmpeg was truncating the output by 4 before
[20:43:55 CEST] <taliho> it would be great if you could try this branch:
[20:43:57 CEST] <taliho> https://github.com/talih0/FFmpeg/tree/chromaprint_branch
[20:44:20 CEST] <taliho> and I'll send the patchset this evening
[20:47:32 CEST] <snatcher> taliho: thank you! also is "-acodec pcm_s16le" necessary?
[21:12:51 CEST] <taliho>  snatcher: I don't think it's necessary. I get the same output with or without it
[22:16:01 CEST] <la_mettrie> adding the first piece of music to a video went well, but then i added another one to another time point and it started to complain "Non-monotonous DTS in output stream 0:1;" and the sound became borked.
[22:16:08 CEST] <la_mettrie> i used this command:  ffmpeg -i hk2.avi -itsoffset 00:00:12.6 -i hk-intro.raw -vcodec copy -acodec copy hk3.avi
[22:16:11 CEST] <la_mettrie> what to do?
[22:45:34 CEST] <void09> how to cut at precise time without re-encoding the whole video, just the first and last frames leading to their nearest keyframe ?
[22:46:04 CEST] <void09> is there such a function ? or do you know of a script to implement it ? encoding should be done with the same settings as the input video
[22:46:45 CEST] <DHE> that is not a built-in feature in ffmpeg. it would have to be implemented in code, and something has to be smart to read the parameters of the input video and match the encoding parameters and other things for this to be safe
[22:52:12 CEST] <void09> i tried to encode the first 8 missing frames piece with different settings than the rest of the video, and concatenate them with ffmpeg.. the result was bad, gray frame, missing frames
[00:00:00 CEST] --- Sun Oct  6 2019


More information about the Ffmpeg-devel-irc mailing list