Re: [FFmpeg-user] ffmpeg wav lossless to youtube mov?
Zathras: It appears your assumption (6) that the files are "exactly the same" because the spectrograms are the same is not correct. I downloaded https://www2.cs.uic.edu/~i101/SoundFiles/BabyElephantWalk60.wav as a test file and converted it with the freeoconvert.com online converter, and ffprobe reports the following: % ffprobe BabyElephantWalk60.mov ... Stream #0:1[0x2]: Audio: aac (LC) (mp4a / 0x6134706D), 22050 Hz, mono, fltp, 72 kb/s (default) Metadata: handler_name: SoundHandler vendor_id : [0][0][0][0] That is, the online converter you specify has converted the audio to AAC. That is, you should be able to use simply ffmpeg -i picture.jpg -i music.wav upload.mov and accept the results. Alternatively, discussion in this thread suggests you can use the FLAC encoding, which is lossless. I agree that the responses you received to your inquiry were rude and unprofessional and have no place on this mailing list and I am sorry you had to deal with them, and I do not understand who administers this list or how to resolve those issues. -- jh...@alum.mit.edu John Hawkinson On Thu, May 23, 2024 at 7:12 PM Zathras Yes wrote: > Hi, > > as i have mentioned to Mr. Reindl, the online-converter > https://www.freeconvert.com/wav-to-mov does the trick. > > ffmpeg should be able to do the same, I suppose. > May be, I am in error, may be not... > > 1. make a wav-files (16 Bit, 44.1 kHz) "sound.wav" > 2. use the mentioned online converter from "sound.wav" to "upload.mov" > 3. Upload this "upload.mov" to youtube. > 4. Go to the youtube-link and download the file "download.mov" > 5. extract the sound file out of "download.mov" --> "extracted.wav" > 6. Compare the original file "sound.wav" with "extracted.wav" with its > spectrogramms. (Audacity or Spectral Layers for instance) > --> et voila the files are exactly the same! > > So, it does work somehow. > For this, I do not understand the length of the discussion (especially with > Mr. Reindl), that it does not work, because it is not supposed to work? > But it does - so I wonder why it is such a big deal here. > ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Slow seeking for GB-scale MOVs?
Any thoughts on this issue, or how best to narrow or debug it? (Platform is MacOS if that's helpful, but I could do so from Linux is that's easier.) Thank you! -- jh...@alum.mit.edu John Hawkinson John Hawkinson wrote on Sun, 7 Jun 2020 at 19:26:26 EDT in <20200607232626.ga74...@alum.mit.edu>: > Date: Sun, 7 Jun 2020 19:26:26 -0400 > From: John Hawkinson > To: ffmpeg-user@ffmpeg.org > Subject: Slow seeking for GB-scale MOVs? > Message-ID: <20200607232626.ga74...@alum.mit.edu> > > When I try to seek within a 5 GB MOV file (24 hours 12 minutes of video; > someone screwed up) over http, it seems that ffmpeg downloads a lot more data > than is necessary, and so is fairly slow to start (delay of minutes on a > medium-speed network connection), seemingly unnecessarily so. In particular, > it seems that in the search for the moov atom, it may end up downloading the > final 69 MB of the file, and that takes quite a while. > > (I'm not quite sure of this -- the http traces from libavformat appear to > indicate the start of HTTP byte-range queries, but don't indicate the end of > such a transfer. For instance, iniially there is a GET for "Range: bytes=0-" > and shortly thereafter there is a GET for "Range: bytes=605088-" and it's > clear that the first could not have downloaded the entire 5 GB file before > turning to the second. So maybe I am missing when http transfer stops and > maybe that matters here.) > > I spent a while staring at libavformat/mov.c and I wasn't able to discern > exactly how/when it decides to do this seeking, although empirically it would > appear that the offset it begins to retrieve is a function of the 'sz' > reported in the 'mdat' trace line, and it finds the 'moov' atom quite > quickly. Yet there is long delay (again, a minute-ish, depending on > connection speed) before any playback starts. There are a few stages along > the way, with a lot of AvIndex output about halfway before playback begins, > but that don't seem correlated with http GETs. > > My example is trying to seek 30 minutes into > http://mediadownload.iqm2.com/CambridgeMA/2288.mpeg4 , the 5 GB video. > So, for instance: > > bash$ ffplay -ss 30:00 -loglevel trace > http://mediadownload.iqm2.com/CambridgeMA/2288.mpeg4 ... > > The complete uncut output at the defaul loglevel is uninteresting. > The above is excerpted from loglevel trace, which gives nearly 1 GB of output > and is probably not helpful here in the entirety. > > A lightly edited version and prematurely truncated version of the trace > output follows, with prefixed timestamps (via tai64n/tai64nlocal). > > > Anyhow, is there a way to reduce how much ffmpeg downloads when it goes for > the moov atom, and am I correct in thinking that that is the issue here? > > Thanks. > > > p.s.: I'm not 100% sure this HTTP resource cited above will persist. It's > possible someone may decide to correct the errantly recorded 24+ hours of > video (it should have been only 9) and so the problem may go away or shift. > > -- > jh...@alum.mit.edu > John Hawkinson ... ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Slow seeking for GB-scale MOVs?
uch ffmpeg downloads when it goes for the moov atom, and am I correct in thinking that that is the issue here? Thanks. p.s.: I'm not 100% sure this HTTP resource cited above will persist. It's possible someone may decide to correct the errantly recorded 24+ hours of video (it should have been only 9) and so the problem may go away or shift. -- jh...@alum.mit.edu John Hawkinson 2020-06-07 18:56:29.836799500 ffplay version 4.2.2 Copyright (c) 2003-2019 the FFmpeg developers 2020-06-07 18:56:29.836800500 built with Apple LLVM version 9.0.0 (clang-900.0.39.2) 2020-06-07 18:56:29.836801500 configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags='-I/Library/Java/JavaVirtualMachines/jdk1.8.0_74.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/jdk1.8.0_74.jdk/Contents/Home/include/darwin' --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack --enable-libzvbi 2020-06-07 18:56:29.836855500 libavutil 56. 31.100 / 56. 31.100 2020-06-07 18:56:29.836855500 libavcodec 58. 54.100 / 58. 54.100 2020-06-07 18:56:29.836856500 libavformat58. 29.100 / 58. 29.100 2020-06-07 18:56:29.836856500 libavdevice58. 8.100 / 58. 8.100 2020-06-07 18:56:29.836856500 libavfilter 7. 57.100 / 7. 57.100 2020-06-07 18:56:29.836863500 libavresample 4. 0. 0 / 4. 0. 0 2020-06-07 18:56:29.836864500 libswscale 5. 5.100 / 5. 5.100 2020-06-07 18:56:29.836869500 libswresample 3. 5.100 / 3. 5.100 2020-06-07 18:56:29.836874500 libpostproc55. 5.100 / 55. 5.100 2020-06-07 18:56:29.987504500 Initialized metal renderer. 2020-06-07 18:56:29.996615500 [NULL @ 0x7f9253000600] Opening 'http://mediadownload.iqm2.com/CambridgeMA/2288.mpeg4' for reading 2020-06-07 18:56:29.996616500 [http @ 0x7f9252c2e700] Setting default whitelist 'http,https,tls,rtp,tcp,udp,crypto,httpproxy' 2020-06-07 18:56:30.057426500 [tcp @ 0x7f9252f34d40] Original list of addresses: 2020-06-07 18:56:30.057448500 [tcp @ 0x7f9252f34d40] Address 69.164.46.0 port 80 2020-06-07 18:56:30.057457500 [tcp @ 0x7f9252f34d40] Address 69.164.46.128 port 80 2020-06-07 18:56:30.057462500 [tcp @ 0x7f9252f34d40] Interleaved list of addresses: 2020-06-07 18:56:30.057472500 [tcp @ 0x7f9252f34d40] Address 69.164.46.0 port 80 2020-06-07 18:56:30.057476500 [tcp @ 0x7f9252f34d40] Address 69.164.46.128 port 80 2020-06-07 18:56:30.057485500 [tcp @ 0x7f9252f34d40] Starting connection attempt to 69.164.46.0 port 80 2020-06-07 18:56:30.082411500 [tcp @ 0x7f9252f34d40] Successfully connected to 69.164.46.0 port 80 2020-06-07 18:56:30.082499500 [http @ 0x7f9252c2e700] request: GET /CambridgeMA/2288.mpeg4 HTTP/1.1 2020-06-07 18:56:30.082499500 User-Agent: Lavf/58.29.100 2020-06-07 18:56:30.082500500 Accept: */* 2020-06-07 18:56:30.082500500 Range: bytes=0- 2020-06-07 18:56:30.082500500 Connection: close 2020-06-07 18:56:30.082501500 Host: mediadownload.iqm2.com 2020-06-07 18:56:30.082501500 Icy-MetaData: 1 2020-06-07 18:56:30.082501500 2020-06-07 18:56:30.082501500 2020-06-07 18:56:30.108572500 [http @ 0x7f9252c2e700] header='HTTP/1.1 206 Partial Content' 2020-06-07 18:56:30.108587500 [http @ 0x7f9252c2e700] http_code=206 2020-06-07 18:56:30.108591500 [http @ 0x7f9252c2e700] header='Server: Apache' 2020-06-07 18:56:30.108594500 [http @ 0x7f9252c2e700] header='Accept-Ranges: bytes' 2020-06-07 18:56:30.108598500 [http @ 0x7f9252c2e700] header='Content-Disposition: attachment' 2020-06-07 18:56:30.108601500 [http @ 0x7f9252c2e700] header='Content-Type: application/octet-stream' 2020-06-07 18:56:30.108605500 [http @ 0x7f9252c2e700] header='Age: 35458' 2020-06-07 18:56:30.108608500 [http @ 0x7f9252c2e700] header='Date: Sun, 07 Jun 2020 22:56:30 GMT' 2020-06-07 18:56:30.108612500 [http @ 0x7f9252c2e700] header='Last-Modified: Wed, 03 Jun 2020 15:15:47 GMT' 2020-06-07 18:56:30.108615500 [http @ 0x7f9252c2e700] header='Content-Range: bytes 0-6124146040/6124146041' 2020-06-07 18:56:30.108624500 [http @ 0x7f9252c2e700] header='X-LLID: fe2d4871173adb88805ac55d4a741bb8' 2020-06-07 18:56:30.108624500 [http @ 0x7f9252c2e700] header='Content-Length: 6124146041' 2020-06-07 18:56:30.108643500 [http @ 0x7f9252c2e700] header='Connection: close' 2020-06-07 18:56:30.108644500 [http @ 0x7f9252c2e700] header='' 2020-06-07 18:56:30.112945500 nan: 0.000 fd= 0 aq=0KB vq=
Re: [FFmpeg-user] Changing the crop filter's output width over time?
Gyan Doshi wrote on Sun, 26 Apr 2020 at 02:03:23 EDT in <76dff16c-331a-534c-fe28-558dae8a8...@gyani.pro>: > The temporal parameters t, n and pos are only applicable for x and y > expressions. At present, the only way to vary w and h over time is by > sending commands with varying constants for w/h. Not very convenient, I > know. Open a ticket if you want an enhancement for the crop filter. Thanks, that's clear enough. It would appear that there is both a documentation bug (the crop filter's doc says "The out_w, out_h, x, y parameters are expressions containing the following constants" and includes a list with n, pos, and t), and also either bugs or odd limitations in the error reporting. These errors don't seem to make sense: Undefined constant or missing '(' in 'T' Error when evaluating the expression '1146+T' Unknown function in 'T*(1920-1146)' Error when evaluating the expression '1146+T*(1920-1146)' Error when evaluating the expression '1146+t' Upon further review, I wonder if the parser is trying to parse T as the 10^9 SI prefix, although that doesn't quite explain it. And there's not even a detailed error message for the '1146+t' form. As for code enhancements, it seems to me that it would be more valuable to focus on the zoompan filter? For instance, I would like to: * give it a duration for the entire zoom effect (in frames or seconds, just like fade and oher filters * specify a starting and ending zoom factor, rather than the current zoom factor and calculate an expression to parameterize steps, which needs clip() or max() and other awkward functions * Not force me hard-code the fps. Since fps isn't available in the expression parser, there seesm no way to make zoompan operate properly on video input without a preprocessing step to check the fps of the input video. * Similarly, a way to not hard-code the resolution, although I assume s=(iw)x(ih) might work, although maybe the parser wouldn't be happy? It also seems the filter could use a clearer definition than "Apply Zoom & Pan effect." Philosophically, I kind of wonder why "crop", "scale", and "zoompan" are 3 separate filters. It would seem that "zoompan" could do the same work as a chain of crop and scale, so I have to imagine one method is more efficeint than the other, but the arbitrary differences in parameters and evaluable expressions just feel odd. Maybe I'm missing something. Thanks. -- jh...@alum.mit.edu John Hawkinson +1 617 797 0250 ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Changing the crop filter's output width over time?
I wanted to execute zoom-and-pan out over a few seconds by parametrizing the width and height of the crop filter via sendcmd (the result of which would then be handed to a scale filter), and when I try to do this, I get errors that I don't understand. When I use: sendcmd=c='0-1 crop w 1146+t*(1920-1146), crop h 1080' I get: Error when evaluating the expression '1146+t*(1920-1146)' When I use sendcmd=c='0-1 crop w 1146+T*(1920-1146), crop h 1080' I get: Unknown function in 'T*(1920-1146)' Error when evaluating the expression '1146+T*(1920-1146)' Neither of these seem to make sense to me. The crop filter docs indicate it takes the parameter 't', and the general eval api docs refer to 'T'. I'm not sure which (or both?) applies, but both fail in odd ways. Same problem with a simpler exmpression like '1146+T'. What am I doing wrong? Console output below. I ultimately managed to get the zoompad filter to work for me, but it doesn't really seem designed to work well with video (rather than a still). I ended up using zoompan=z=if(eq(pzoom\,1)\,1.8\,max(pzoom-0.0025\,1.01)):x='iw/2-(iw/zoom/2)+60':y='ih/2-(ih/zoom/2)-120':d=1:fps=30, where if I didn't specify the fps rate, it desynced my audio and video, and the expression necessary to make it work, depending on pzoom, and specifying the zoom steps...just felt fragile. (On the other hand, presumably it's more performant than a crop filter followed by a scale filer). Thanks you. -- jh...@alum.mit.edu John Hawkinson $ sh -x diag.sh + ffplay -i v -vf ' sendcmd=c='\''0-1 crop w 1146+T, crop h 1080'\'', crop= 1146:644: 456-clip(t\,0\,1)*456: 73-clip(t\,0\,1)*73' ffplay version 4.2.2 Copyright (c) 2003-2019 the FFmpeg developers built with Apple LLVM version 9.0.0 (clang-900.0.39.2) configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags='-I/Library/Java/JavaVirtualMachines/jdk1.8.0_74.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/jdk1.8.0_74.jdk/Contents/Home/include/darwin' --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack --enable-libzvbi libavutil 56. 31.100 / 56. 31.100 libavcodec 58. 54.100 / 58. 54.100 libavformat58. 29.100 / 58. 29.100 libavdevice58. 8.100 / 58. 8.100 libavfilter 7. 57.100 / 7. 57.100 libavresample 4. 0. 0 / 4. 0. 0 libswscale 5. 5.100 / 5. 5.100 libswresample 3. 5.100 / 3. 5.100 libpostproc55. 5.100 / 55. 5.100 Input #0, matroska,webm, from 'v': Metadata: COMPATIBLE_BRANDS: iso6avc1mp41 MAJOR_BRAND : dash MINOR_VERSION : 0 ENCODER : Lavf58.29.100 Duration: 00:04:30.30, start: -0.007000, bitrate: 2977 kb/s Stream #0:0: Video: h264 (High), yuv420p(tv, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 29.97 fps, 29.97 tbr, 1k tbn, 59.94 tbc (default) Metadata: HANDLER_NAME: ISO Media file produced by Google Inc. DURATION: 00:04:30.27000 Stream #0:1(eng): Audio: opus, 48000 Hz, stereo, fltp (default) Metadata: DURATION: 00:04:30.30100 [Parsed_crop_1 @ 0x7f7f8d7955c0] [Eval @ 0x772cedb0] Undefined constant or missing '(' in 'T' Error when evaluating the expression '1146+T' [Parsed_crop_1 @ 0x7f7f8d7955c0] [Eval @ 0x772cedb0] Undefined constant or missing '(' in 'T' Error when evaluating the expression '1146+T' Switch subtitle stream from #-1 to #-1 vq= 162KB sq=0B f=0/0 2.09 A-V: -0.030 fd= 5 aq= 20KB vq= 143KB sq=0B f=0/0 ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Efficiently doing thousands of edits?
Michael Shaffer wrote on Wed, 10 Apr 2019 at 19:40:36 -0400 in : > I'm pretty sure you could use Python and OpenCV to create a solution.. "Just because you can, doesn't mean you should." My original post explained how to determine where the runs of black are, using ffmpeg (libavfilter)'s "blackdetect." The only piece left is applying the edits in a practical fashion. Rolling your own with opencv would be a whole lot more work. I'm not entirely sure that I agree with Carl Eugen that ffmpeg isn't a video editing tool, but if it's not, Python certainly isn't. Yes, you can make it work. But you're going to spend a lot more time doing it than if higher level tools were used. The goal here is for higher-level tools, not lower-level ones. Or I might just end up using ffmpeg to split it into 7,000 files and then concatenating them. That's hardly the worst thing in the world. -- jh...@alum.mit.edu John Hawkinson ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Efficiently doing thousands of edits?
Carl Eugen Hoyos wrote on Wed, 10 Apr 2019 at 01:13:17 +0200 in : > ffmpeg, the command line application, is not a video editor. FFmpeg, > the project, provides libraries that can be used by video editor software. Thanks, Carl Eugen. What would you recommend for video editing tools that use ffmpeg's libraries? I admit most of my experience with video editing software has been with commercial GUI projects that are not great for tasks like this. I guess I could use the blackdetect filter to produce an EDL and run that through a commerical GUI video editor, but...well, what woudl you recomend for using ffmpeg's libraries? That's not something I'm very familiar with. Thanks. -- jh...@alum.mit.edu John Hawkinson ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
[FFmpeg-user] Efficiently doing thousands of edits?
w cluster due to timestampte= 903.0kbits/s speed=0.0662x Last message repeated 2 times [matroska @ 0x7fb7bc742a00] Starting new cluster due to timestampte= 449.9kbits/s speed=0.132x [matroska @ 0x7fb7bc742a00] Starting new cluster due to timestampte= 450.2kbits/s speed=0.132x frame=13337 fps=1.1 q=29.0 size= 50354kB time=00:14:47.32 bitrate= 464.9kbits/s speed=0.0758x (Yes, the complete uncut console output is missing. 3000 duplicate stream mapping lines isn't appropriate for the mailing list.) That's after running for a few hours, it the speed is 0.0758x. And nowhere into finishing the 2.5 hour video. In comparison, running on the 10 second test with 4 trims, it was: frame= 150 fps= 62 q=-1.0 Lsize= 498kB time=00:00:10.37 bitrate= 392.7kbits/s speed= 4.3x QUESTION: What's the right way to do this efficiently? Presumably there's a point where the concat filter is more efficient than the concat muxer, but presumably much much lower than 3,000 entries. Presumably the right answer involves writing off segments to files? It also occurred to me that there are snazzier ways to fix this than just frame-holding the last frame. Maybe split out the two video streams and let one continue unchanged while the other is fixed. Perhaps recompose them in a better way. Perhaps do some kind of blend or transition across the glitch rather than a frame hold. But I figured I'd worry about those after I got the baseline fix working. Thanks. And thanks for any suggestions how to do this better. -- jh...@alum.mit.edu John Hawkinson ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Converting .trm files ("ForTheRecord") -- force AAC decoding?
> Please provide a sample input file if possible. http://mit.edu/jhawk/tmp/t1.trm Thanks! --jh...@mit.edu John Hawkinson ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] mp4 concatenation (muxer) problems -- invalid output?
I want to be clear -- I only gave my goal (stitching multiple videos together) so you'd have context. I'm not asking for help with the overall task, merely with the concatation problem. I don't mean to sound ungreatful, and Erik, I've tried to answer all your questions, even though they seem to be taking me further away from the original problem, not closer to a solution. My question specifically is why (1) extracting a still; (2) frame-holding it with "-loop 1 -i f1.png -t 3.933 -pix_fmt yuv420p -r 29.97"; and (3) attempting to concatenate it with the original mp4 with "-f concat -i concat7 -c copy" ===> results in an invalid mp4. Far too long as reported by the ffmpeg concat process; far too long as reported by ffprobe; does not play properly in VLC. My assumption is something is wrong at step (2), but I don't know that to be the case. Erik Dobberkau <erik.dobber...@gmail.com> wrote on Mon, 20 Feb 2017 at 07:56:41 +0100 in <CAOz0ov+aubY+k=bZm1PE1vn1fjTpF7p0wrm5B-2=yuglysb...@mail.gmail.com>: > Obviously you're trying to concat recordings from a DSLR. > -> Why are there gaps in between? They shouldn't be there, if the camera is > continuously on record. This isn't really relevant to ffmpeg, and it's a constraint I have to live with. But the answer is the camera in question (not a DSLR) is limited to 30-minute recording chunks, because of MPEG patent licensing restrictions in the firmware. > When done with the video, you want to replace the audio (of the lng > video file) with a continuous mp3 audio track that is in sync all of the > time? Again, not relevant to ffmpeg, but yes. Possibly adjustment of the audio timebase may be required in some cases for optimal sync, but my experience has been that it's not necessary in my application. > You can only concat files with matching parameters (and different moov > atoms if they're not raw files, like transport streams) if you want to get > a decent result, Right, understood. The question is why the frame-held still does not appear to be compatible with the original mp4. (Although as an aside, the ffmpeg documentation throws around the phrase "raw" a fair bit, and it's not really clear as a reader what exactly it means. Which formats constitute "raw" and in what contexts? How are you supposed to know or figure it out? It would be great if ffprobe could report it definitively.) > which means you have to do the following: > - Get the exact timecode difference between each of the adjacent files ( -> > exiftool is your friend, use ffprobe and exiftool in a nice script to do > the math... ) Again, not relevant to the problem. As noted originally, I get this data via another mechanism (PrPro -> EDL export). > - Based on that difference, create matching splice files from the first > frame of the "next" clip for each gap with matching video Yes, here's what I am asking about, because, again, the "splice files" I create do not seem to work properly with the concat mixer. > and audio parameters to the source clips (-> use anullsrc to add > blank audio to an image). I'm not really sure why the audio matters much, since it's getting stripped out anyhow. A MP4 with no audio is compatible with an MP4 with some aac audio, right? In any event, as I reported, having stripped the audio from the video file, I continue to have concatenation problems with two MP4s that both lack audio. > Your mileage will vary here because DSLR cameras use evil magic to > record video... I'm not quite sure what you're getting at here (also still not a DSLR). Are you suggesting the MP4 from the camera is sufficiently "damaged" because of realtime codec issues that it requires some form of transcoding to be usable in any way? That would be unfortunate, but if it's true, what's the minimal operation required? > your ffmeg cmd line will (need to) be much longer than it is now. Why? But more sigificantly, in what way? But this is again out of scope for the question, which is why concatenating a single frame-held still (your term: "splice file") with a single video file produces a broken result. > I don't think it's likely to get a single-line solution for your task. I'm not seeking one. What I am seeking is a successful way to concatenate a held still with an mp4 video that produces a valid result, with minimal transcoding. Thanks! Oh, right, you started with: > just to make sure I get this right, are you trying to build an > advanced version of Vantage Camera Ingest? Have fun then... ;-) I'm not familiar with it but I looked at the cutsheet just now. I'd say "not really" since generally my timebases aren't good enough for fully automatic syncing, and so I end up with manual adjustments to the time sync (often comparing the audio tracks between the video clips and the master audi