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

burek burek021 at gmail.com
Wed Aug 30 03:05:01 EEST 2017


[01:05:18 CEST] <guides> I got a question regarding ffmpeg and streaming to youtube, currently i'm able to stream a .png and a .mp3 file, but after the .mp3 file is done playing it's done streaming (obviously). Is there a parameter i'm missing to get it to loop forever? i janked together this combination of parameters to get this working, but having trouble finding a way to contiously loop the song without it stopping the stream. command/console output - https:
[03:23:21 CEST] <nicolas17> I want to stabilize and denoise a video
[03:23:26 CEST] <nicolas17> should I first denoise and then stabilize?
[03:23:55 CEST] <nicolas17> and if so, should I use the denoise filter during both vidstabdetect and vidstabtransform steps?
[03:29:46 CEST] <Cracki_> yes, first denoise
[03:29:56 CEST] <Cracki_> noise is relative to the chip, not the video
[03:30:45 CEST] <Cracki_> not sure how ffmpeg's vidstab works... it might be robust to noise
[03:35:17 CEST] <stimple> oh ty, didn't know we had stabilization
[03:35:59 CEST] <nicolas17> I have a script using MLT's videostab2
[03:36:11 CEST] <nicolas17> I'm glad to see ffmpeg supports videostab now
[03:44:34 CEST] <nicolas17> I'm running my old script with melt now
[03:44:40 CEST] <nicolas17> videostab is slow as hell on 1080p
[03:53:42 CEST] <Cracki_> adobe premiere's stabilization isn't terribly fast either
[03:54:16 CEST] <nicolas17> oh I know, this is *inherently* slow
[03:54:24 CEST] <Cracki_> there are papers for decent algorithms that can run quite fast
[03:54:46 CEST] <Cracki_> some are smarter about crunching numbers.
[03:54:51 CEST] <Cracki_> some use the GPU
[03:55:37 CEST] <Cracki_> I've seen realtime digital deshaking in handheld video cameras 20 years ago
[03:56:01 CEST] <Cracki_> i.e. it deshook what it saw, even if the cam was stationary
[03:56:07 CEST] <atomnuker> vf_deshake can use opencl
[03:56:35 CEST] <nicolas17> I have integrated intel GPU on a laptop, I don't think OpenCL will make miracles
[03:58:16 CEST] <Cracki_> don't discount it
[03:58:32 CEST] <Cracki_> especially integrated GPUs have the advantage of direct access to main memory
[03:59:14 CEST] <Cracki_> and compared to the CPU part, they easily have 10x the crunch for single precision
[03:59:41 CEST] <nicolas17> model name      : Intel(R) Core(TM) i5-3317U CPU @ 1.70GHz
[03:59:43 CEST] <nicolas17> OpenGL renderer string: Mesa DRI Intel(R) Ivybridge Mobile
[04:00:45 CEST] <Cracki_> wikipedia says 332.8 gflops for the intel hd 4000
[04:01:19 CEST] <Cracki_> anyway, depending on algorithm, deshaking could be quite fast.
[04:01:56 CEST] <Cracki_> I'd always go with pyramid schemes and optical flow-like computation
[04:02:27 CEST] <wutsnek> hey peeps i have a question
[04:02:46 CEST] <Cracki_> snek wut :P
[04:03:10 CEST] <wutsnek> im using ffmpeg with an audio stream but ends up crashing after 20~ seconds
[04:03:15 CEST] <wutsnek> [tls @ 0x242f9c0] Error in the pull function. [matroska,webm @ 0x242d340] Read error
[04:03:20 CEST] <wutsnek> with this error
[04:04:28 CEST] <Cracki_> update ffmpeg?
[04:06:03 CEST] <nicolas17> oh, while I wasn't looking MLT finished running the videostab analysis
[04:06:24 CEST] <nicolas17> 7642 1080p frames
[04:21:09 CEST] <Cracki_> watching a tea pot boil
[04:29:34 CEST] <wutsnek> it should be the latest versionhm why is the latest version hosted by ubuntu 2.8.11
[04:29:50 CEST] <nicolas17> what version of ubuntu?
[04:29:50 CEST] <wutsnek> oops ignore the first part
[04:30:19 CEST] <wutsnek> 16.03
[04:30:22 CEST] <wutsnek> 4
[04:30:22 CEST] <wutsnek> *
[04:31:05 CEST] <nicolas17> then you're going to get a version that was somewhat latest back in April 2016
[04:32:05 CEST] <nicolas17> Cracki_:
[04:32:08 CEST] <nicolas17> oops
[04:32:14 CEST] <nicolas17> so what denoiser do you recommend?
[04:32:37 CEST] <Cracki_> whatever looks good :P
[04:32:49 CEST] <Cracki_> depends on the kind of "noise"
[04:33:06 CEST] <furq> try them all out on some samples i guess
[04:33:12 CEST] <nicolas17> iPhone camera on somewhat low light; I don't mind waiting for processing, since I'm going to spend so much CPU time on videostab anyway
[04:33:15 CEST] <furq> hqdn3d is a good general-purpose one which is quite fast
[04:33:17 CEST] <Cracki_> if the video is compressed to smudge, nothing can fix that
[04:33:20 CEST] <furq> nlmeans is also good but slow
[04:33:27 CEST] <furq> unless you use the opencl one in vapoursynth
[04:33:58 CEST] <furq> but yeah ffmpeg has tons of them to test out
[04:33:59 CEST] <Cracki_> be aware that the heavier the denoise, the more likely it is that the video is warped by the denoising
[04:34:40 CEST] <furq> yeah you can sharpen it afterwards but obviously that's fraught with danger
[04:35:00 CEST] <nicolas17> furq: apparently I need unsharp after videostab anyway
[04:37:55 CEST] <furq> it's still generally better to denoise as little as you can
[04:41:10 CEST] <nicolas17> furq: http://nicolas17.s3.amazonaws.com/noise-crop-640x480.mp4
[04:41:28 CEST] <nicolas17> I guess some "light" denoising will be enough
[04:42:12 CEST] <furq> yeah that's not that bad
[04:42:30 CEST] <furq> hqdn3d should do a perfectly good job with that
[04:57:23 CEST] <Cracki> that calls for a temporal denoise
[04:57:44 CEST] <Cracki> not high-frequency enough for spatial denoise to make sense
[05:03:30 CEST] <furq> right
[05:10:13 CEST] <Cracki> never worked with hqdn3d, sounds like the right tool though :P
[05:11:58 CEST] <nicolas17> [AVFilterGraph @ 0x557d8d435460] No such filter: 'vidstabdetect'
[05:12:00 CEST] Action: nicolas17 cries
[05:12:57 CEST] <Cracki> now you'll learn how the sausage is made
[05:13:34 CEST] <nicolas17> Cracki: I wrote my own transcoder with libavcodec/libavformat APIs, I already know too much about the sausage
[05:13:40 CEST] <Cracki> :D
[05:16:44 CEST] <nicolas17> the problem is vidstab is not packaged in debian
[05:16:48 CEST] <nicolas17> where do I get that?
[05:16:59 CEST] <nicolas17> https://github.com/georgmartius/vid.stab is it this one?
[05:18:36 CEST] <furq> nicolas17: https://www.johnvansickle.com/ffmpeg/
[05:18:40 CEST] <furq> there are static builds with vidstab there
[05:41:57 CEST] <nicolas17> built vidstab, now building ffmpeg
[05:46:25 CEST] <mozzarella> guys help
[05:47:22 CEST] <mozzarella> I've got a gigantic (file size) video that is just the raw stream from my cctv camera, how do I shrink it down without losing quality
[05:49:01 CEST] <stimple> you don't
[05:49:20 CEST] <stimple> well you can use huffyuv
[05:50:12 CEST] <c3r1c3-Win> mozzarella: You could try x264 using CRF instead of bitrate as the compressor's main metric.
[05:50:26 CEST] <nicolas17> stimple: even that will technically lose quality if the source is RGB :P
[05:50:42 CEST] <stimple> ok yes
[05:50:58 CEST] <furq> huffyuv does rgg
[05:51:00 CEST] <furq> rgb
[05:51:04 CEST] <c3r1c3-Win> But any form of anything approaching lossless will take up a ton of space, so if you scrafice just a touch of quality you can get the files to much smaller.
[05:51:21 CEST] <c3r1c3-Win> *to a MUCH smaller size.
[05:51:28 CEST] <redrabbit> i beleive he is not looking for lossless
[05:51:30 CEST] <furq> if it's a raw stream from cctv then it's probably already mjpeg or h264 or something
[05:51:47 CEST] <furq> i doubt a cctv camera is putting out raw yuv
[05:51:50 CEST] <redrabbit> he wants little perceived quality difference
[05:51:59 CEST] <mozzarella> Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuvj420p(pc, bt709), 1280x720 [SAR 1:1 DAR 16:9], 2046 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 60 tbc (default)
[05:52:05 CEST] <furq> right
[05:52:10 CEST] <Cracki> 20 Mbit/s?
[05:52:11 CEST] <furq> also that's not particularly big
[05:52:12 CEST] <Cracki> that's not bad
[05:52:16 CEST] <furq> that's 2mbps
[05:52:17 CEST] <Cracki> 2.0*
[05:52:26 CEST] <Cracki> how "big" is that anyway
[05:52:37 CEST] <nicolas17> 2mbps, I don't think you can go much lower than that without noticeably losing quality... unless there's very very little movement ^^
[05:52:39 CEST] <Cracki> you could drop framerate, set higher keyframe intervals, ...
[05:52:40 CEST] <redrabbit> its going to be hard to compress further without botching it
[05:52:50 CEST] <furq> there will probably be very little movement and it's just a garbage hardware encoder
[05:52:56 CEST] <furq> but there's also a good chance it's noisy as well
[05:52:58 CEST] <mozzarella> 9.7 GB for a 10.5 hours video
[05:52:58 CEST] <furq> hell
[05:53:03 CEST] <Cracki> if it's a security camera pointed at a motionless scene, you can compress it some more
[05:53:08 CEST] <furq> yeah that's not gigantic at all
[05:53:35 CEST] <Cracki> so thats 8 TB/year
[05:53:48 CEST] <Cracki> if you mean to retend that long
[05:53:52 CEST] <nicolas17> I ran my old videostab script and it gave me 1GB for 4 minutes
[05:54:01 CEST] <nicolas17> turns out it was doing huffyuv, I forgot about that :P
[05:54:03 CEST] <mozzarella> I've get videos that are similar in length and they are ~1.5 GB, not sure how I did it
[05:54:16 CEST] <mozzarella> got*
[05:54:21 CEST] <Cracki> play with keyframe interval
[05:54:27 CEST] <nicolas17> [00:50] <c3r1c3-Win> mozzarella: You could try x264 using CRF instead of bitrate as the compressor's main metric.
[05:54:30 CEST] <nicolas17> that's the best place to start
[05:54:32 CEST] <furq> yes, that
[05:54:36 CEST] <Cracki> if nothing moves (see denoising), compression can work on the real content
[05:54:40 CEST] <furq> just encode with x264 defaults and see what happens
[05:54:50 CEST] <furq> -i in.mp4 out.mp4
[05:54:50 CEST] <Cracki> yeah crf, i second that
[05:55:00 CEST] <mozzarella> furq: that would work?
[05:55:03 CEST] <furq> shrug
[05:55:05 CEST] <furq> it depends on the source
[05:55:05 CEST] <Cracki> defaults are pointless. default bitrate is 200 kbit/s
[05:55:08 CEST] <furq> no it isn't
[05:55:14 CEST] <furq> the x264 default is -crf 23
[05:55:14 CEST] <Cracki> oh right, x264 not ffmpeg
[05:55:18 CEST] <furq> with ffmpeg
[05:55:38 CEST] <furq> the global default is 200kbps but codecs can override that individually
[05:55:49 CEST] <furq> the x264 defaults are pretty sensible
[05:55:58 CEST] <furq> preset medium, crf 23
[05:59:43 CEST] <mozzarella> how long is it going to take?
[06:00:57 CEST] <mozzarella> why do I keep getting "Past duration 0.something too large"
[06:02:01 CEST] <nicolas17> the status bar should show 'fps'
[06:02:08 CEST] <nicolas17> that's how many frames it's encoding per second
[06:02:17 CEST] <mozzarella> there's no status bar
[06:02:33 CEST] <nicolas17> I get a line like "frame=  300 fps= 56 q=-0.0 Lsize=   84886kB time=00:00:10.01 bitrate=69462.4kbits/s speed=1.88x" that updates every second
[06:02:52 CEST] <dystopia_> yeah thats in the command window
[06:03:03 CEST] <dystopia_> it would be nice if it was in the status bar though
[06:03:55 CEST] <mozzarella> there's no ETA
[06:03:59 CEST] <mozzarella> or %
[06:04:09 CEST] <nicolas17> you can calculate it from "speed"
[06:04:17 CEST] <dystopia_> you can do the eta maths yourself
[06:04:19 CEST] <dystopia_> yeah
[06:04:21 CEST] <nicolas17> if it says 1x it means a 10-hour video will take 10 hours to encode
[06:04:29 CEST] <mozzarella> oh jesus
[06:04:31 CEST] <Cracki> ?
[06:04:34 CEST] <nicolas17> so what does it say?
[06:04:36 CEST] <Cracki> 1x means 1x speed
[06:04:41 CEST] <mozzarella> 3.11x
[06:04:42 CEST] <Cracki> post the line?
[06:04:52 CEST] <dystopia_> then devide duration by 3.1x
[06:04:57 CEST] <Cracki> so 3 hours
[06:05:06 CEST] <nicolas17> you should encode like
[06:05:06 CEST] <mozzarella> still seems excessive to me
[06:05:07 CEST] <Cracki> 3x isn't so bad. what resolution?
[06:05:08 CEST] <nicolas17> a few minutes of video
[06:05:13 CEST] <nicolas17> to see what the quality is like
[06:05:14 CEST] <furq> lol 69mbps
[06:05:23 CEST] <furq> is the source noisy or blocky by any chance
[06:05:27 CEST] <Cracki> if medium is too slow for you, go try fast/faster/veryfast
[06:05:36 CEST] <nicolas17> furq: my 69mbps is huffyuv :P
[06:05:42 CEST] <furq> oh right
[06:05:42 CEST] <Cracki> you can go higher with the crf too, but check the results
[06:05:43 CEST] <furq> duh
[06:05:48 CEST] <furq> well yeah
[06:05:54 CEST] <furq> mozzarella: make sure it's actually coming in lower than 2mbit
[06:05:56 CEST] <dystopia_> 3.1x is fast heh
[06:05:57 CEST] <furq> otherwise you're wasting your time
[06:05:58 CEST] <Cracki> ah, 69 Mbit/s would have been 4k footage :P
[06:06:08 CEST] <Cracki> (for typical 264 bitrates)
[06:06:13 CEST] <nicolas17> what am I supposed to see with vidstabdetect=show=1?
[06:06:22 CEST] <furq> nah you'll get that with something like noisesrc
[06:06:23 CEST] <mozzarella> frame=21167 fps= 93 q=-1.0 Lsize=   20443kB time=00:11:46.38 bitrate= 237.1kbits/s dup=10 drop=7 speed=3.11x
[06:06:25 CEST] <mozzarella> video:17648kB audio:2411kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 1.913213%
[06:06:30 CEST] <Cracki> much better
[06:06:31 CEST] <furq> yeah there you go
[06:06:44 CEST] <furq> check it actually still looks good obv
[06:07:01 CEST] <furq> i wouldn't use any preset above faster if you actually want it to compress well
[06:07:12 CEST] <Cracki> ^
[06:07:21 CEST] <mozzarella> I didn't change a thing, that's the output I got initially
[06:07:39 CEST] <furq> right, that's -preset medium
[06:07:44 CEST] <furq> (the default)
[06:07:49 CEST] <Cracki> yes initially it spends bits on a keyframe, and maybe the video moves a bit still.
[06:08:06 CEST] <nicolas17> ohhhh
[06:08:07 CEST] <Cracki> as soon as the video quiets down, bitrate goes down too.
[06:08:14 CEST] <nicolas17> I have to produce a video file with vidstabdetect
[06:08:17 CEST] <Cracki> it'll spend bits on keyframes regularly, I hope
[06:08:18 CEST] <nicolas17> that's where the debugging info is
[06:08:18 CEST] <furq> fwiw if it's a security camera you can try messing with mpdecimate
[06:08:27 CEST] <furq> that'll drop sequential identical frames
[06:08:30 CEST] <furq> !filter mpdecimate
[06:08:30 CEST] <nfobot> furq: http://ffmpeg.org/ffmpeg-filters.html#mpdecimate
[06:08:35 CEST] <Cracki> nice
[06:08:51 CEST] <furq> not sure if the detection is slower than encoding those frames
[06:08:56 CEST] <furq> but it'll definitely make the video smaller
[06:09:22 CEST] <Cracki> mpdecimate drops the whole frame. h264 would compress the differences only in any case.
[06:09:42 CEST] <furq> right, but you'll get fewer IDR frames
[06:09:51 CEST] <Cracki> true
[06:09:57 CEST] <furq> possibly much fewer
[06:10:19 CEST] <Cracki> idr = intra/key?
[06:10:26 CEST] <furq> intra decoder refresh
[06:10:28 CEST] <furq> (yes)
[06:10:29 CEST] <Cracki> ic
[06:10:46 CEST] <furq> or instant decoder refresh, rather
[06:10:58 CEST] <Cracki> subtle differences in meaning, perhaps
[06:11:11 CEST] <furq> that's what you'd think of as a keyframe
[06:11:13 CEST] <Cracki> "An IDR frame is a special kind of I frame used in MPEG-4 AVC encoding. Frames following an IDR frame may not refer back to frames preceding the IDR frame. IDR frames can be used to create AVC streams which are more easily edited "
[06:11:25 CEST] <mozzarella> you guys make me realize I know close to nothing about video encoding
[06:11:41 CEST] <Cracki> I can just google quicker than the average bear
[06:11:48 CEST] <Cracki> s/google/duckduckgo/
[06:12:25 CEST] <Cracki> btw, alternative video platforms: vimeo (traditional), bitchute and dtube.video (p2p tech)
[06:12:25 CEST] <furq> idle in here for long enough and you too will be able to convincingly hold a conversation about video
[06:12:45 CEST] <Cracki> if you zig, you gotta zag too
[06:12:57 CEST] <dystopia_> lol
[06:13:06 CEST] <Cracki> I hear the BBQ transform is the new hype
[06:13:08 CEST] <dystopia_> i love this channel :O
[06:13:34 CEST] <Cracki> the successor to yolo, yolo2, is even better for object recognition
[06:13:58 CEST] <Cracki> ^ not joking
[06:14:16 CEST] <mozzarella> for some reason -preset faster is even slower than medium
[06:14:19 CEST] <nicolas17> what's that anime-oriented scaler?
[06:14:42 CEST] <nicolas17> I don't remember the name
[06:14:51 CEST] <dystopia_> there is -tune animation
[06:14:55 CEST] <dystopia_> do you mean scaler?
[06:15:01 CEST] <nicolas17> ah waifu2x
[06:15:08 CEST] <nicolas17> dystopia_: while we're talking of silly names
[06:16:13 CEST] <stimple> waifu2x is fast enough to do video?
[06:17:12 CEST] <nicolas17> stimple: sure it can do video, not sure at what fps (or spf) :D
[06:18:26 CEST] <stimple> these neural net scalers are pretty awesome
[06:18:33 CEST] <Cracki> waifu2x is sensitive to noise...
[06:18:57 CEST] <Cracki> be aware that neural net scalers introduce hallucinations depending on what they're trained on
[06:19:03 CEST] <stimple> yes
[06:19:15 CEST] <Cracki> the added information is not in the picture, but in the preconceptions it was trained on
[06:19:17 CEST] Action: nicolas17 plays with vidstab parameters
[06:19:24 CEST] <dystopia_> i thought rule 101 of video encoding was never upscale :O
[06:19:40 CEST] <furq> nnedi is pretty good
[06:19:45 CEST] <furq> mostly for deinterlacing though
[06:19:57 CEST] <Cracki> rule 34
[06:20:05 CEST] <furq> obviously it is good at deinterlacing by being good at 2x upscaling, but why would you ever do the latter
[06:20:16 CEST] <furq> unless you're making 4k blurays ofc
[06:20:17 CEST] <Cracki> upscaling old shitty footage
[06:20:46 CEST] <Cracki> anime are "easy" to upscale because lots of uniform-colored polygons
[06:20:52 CEST] <Cracki> *areas
[06:21:06 CEST] <Cracki> it only has to preserve edges well, not so much texture
[06:21:39 CEST] <Cracki> https://raw.githubusercontent.com/nagadomi/waifu2x/master/images/slide.png
[06:22:06 CEST] <dystopia_> :O
[06:22:10 CEST] <Cracki> ya
[06:22:11 CEST] <dystopia_> miku is my waifu
[06:22:15 CEST] <dystopia_> you can't have her!
[06:22:36 CEST] <Cracki> don't wanna. it's not a boy
[06:22:40 CEST] <dystopia_> the scaling looks good though
[06:22:42 CEST] <dystopia_> hehe
[06:22:48 CEST] <Cracki> it does indeed.
[06:23:07 CEST] <Cracki> and I'm sure it works fine for several iterations
[06:30:30 CEST] <stimple> neural nets aren't going to get us -- yet
[06:38:08 CEST] <c3r1c3-Win> Luka > all.
[06:48:48 CEST] <dystopia_> luka luka nightfever
[06:50:02 CEST] <c3r1c3-Win> So if Miku catches LukuLuka Nightfever, what does it turn into?
[06:50:11 CEST] <c3r1c3-Win> MikuMiku Head cold.
[06:55:11 CEST] <dystopia_> i think we might be weebs c3r1c3-Win
[06:55:21 CEST] <c3r1c3-Win> LOL
[06:55:45 CEST] <sgo11> hi, mp4 file will pick a frame from the file as the preview image (thumbnail). What is the logic? How can I let it to pick the frame that I want? thanks a lot.
[06:55:56 CEST] <furq> that depends on your file manager
[06:56:52 CEST] <sgo11> furq, I tried four different file managers and apps in two platforms (linux and android). All pick the same image. that is weird. I want to change that image. Is that possible? thanks.
[06:56:57 CEST] <mozzarella> alright guys
[06:57:08 CEST] <c3r1c3-Win> Correct me if I'm wrong, but I do seem to remember that your can set a thumbnail for MP4 files... but even if you can, it does depend on your file manager.
[06:57:17 CEST] <mozzarella> how can I put a limit of 25% CPU usage, when encoding
[06:57:21 CEST] <nicolas17> ugh
[06:57:33 CEST] <mozzarella> I just don't want my fan to spin like crazy, I don't care how long it takes
[06:57:46 CEST] <nicolas17> mozzarella: do you have multiple cores?
[06:57:47 CEST] <c3r1c3-Win> I'm not saying FFMPEG supports (or doesn't support) such, but I remember reading in the file spec something to that effect.
[06:57:52 CEST] <mozzarella> nicolas17: I do
[06:58:03 CEST] <nicolas17> maybe ffmpeg is automatically using multiple threads to speed things up
[06:58:08 CEST] <mozzarella> it is
[06:58:13 CEST] <mozzarella> it's using my 4 cores
[06:58:18 CEST] <dystopia_> you could slow it down with -re possibly
[06:58:20 CEST] <mozzarella> so almost 400%
[06:58:26 CEST] <dystopia_> if it's encoding faster than realtime as it is
[06:58:35 CEST] <c3r1c3-Win> You should be able to tell ffmpeg to use fewer threads/cores.
[06:58:37 CEST] <mozzarella> what's -re?
[06:58:40 CEST] <nicolas17> so "-threads 1" will limit it
[06:58:47 CEST] <dystopia_> encodes out put at input framerate
[06:59:09 CEST] <dystopia_> so if a 25fps video was encoidng at 100fps or 4x, it would be limited to 25%
[06:59:16 CEST] <nicolas17> urgh, vidstab's tripod mode was giving me great results
[06:59:23 CEST] <nicolas17> but it gets very confused when brightness changes
[06:59:24 CEST] <sgo11> For example, my pcmanfm-qt file manager in linux and ES File Manager App in android both are using the same thumbnail. I am satisfied if I can change the thumbnail of these two file managers. any suggestions? thanks.
[06:59:25 CEST] <dystopia_> but if your encoding slower than output framerate, nothing will happen
[06:59:34 CEST] <nicolas17> camera automatically changed the exposure when the projector turned on
[06:59:49 CEST] <nicolas17> sgo11: aren't they using the first frame?
[07:00:05 CEST] <sgo11> nicolas17, :) they are not. if they do, I will not ask here.
[07:00:29 CEST] <mozzarella> still using 4 threads, lol
[07:00:37 CEST] <mozzarella> wth
[07:00:42 CEST] <nicolas17> mozzarella: with -threads 1?
[07:00:57 CEST] <mozzarella> nicolas17: yeah
[07:01:09 CEST] <mozzarella> do I need to put it in front of the file name or what?
[07:01:19 CEST] <c3r1c3-Win> sgo11: https://superuser.com/questions/597945/set-mp4-thumbnail
[07:01:53 CEST] <nicolas17> mozzarella: -filter_threads 1?
[07:02:30 CEST] <mozzarella> still not working
[07:02:39 CEST] <sgo11> c3r1c3-Win, I tried that. That won't work because the file managers I tried are not reading the cover tag. They pick a frame image.
[07:03:01 CEST] <dystopia_> try the -re flag mozzarella it might help
[07:03:15 CEST] <c3r1c3-Win> sgo11: If that's the case you really have no control over it.
[07:03:27 CEST] <dystopia_> ffmpeg -re -i whatever....
[07:03:33 CEST] <nicolas17> maybe they are hardcoded to take the nth frame
[07:03:45 CEST] <sgo11> c3r1c3-Win, All the apps I tried in android are not reading the cover tag. And All the apps are using the same frame image. that's why I want to know the logic and what the frame is.
[07:04:14 CEST] <dystopia_> it's probably 1st i frame
[07:04:40 CEST] <sgo11> nicolas17, if they are hardcoded, I am wondering what the logic is. Because all apps are using the same frame image as thumbnail. There must be a logic.
[07:04:49 CEST] <mozzarella> alright, still using 150% CPU, though&
[07:05:01 CEST] <c3r1c3-Win> Most of the time I see it's the 4-second frame (or 3rd i-frame) that's selected... or something like that.
[07:05:11 CEST] <dystopia_> i wish my cpu could use 150%
[07:05:18 CEST] <dystopia_> i would have 6hz
[07:05:21 CEST] <c3r1c3-Win> sgo11: Best thing is to look at the source code. ;-)
[07:05:23 CEST] <dystopia_> 6ghz
[07:05:32 CEST] <nicolas17> dystopia_: multicore :P
[07:05:38 CEST] <dystopia_> hehe
[07:05:51 CEST] <sgo11> ok... let me see.
[07:16:40 CEST] <mozzarella> guys
[07:16:54 CEST] <mozzarella> can I pause/stop it and resume it in a few hours?
[07:19:43 CEST] <nicolas17> on Linux, Ctrl-Z :P
[07:19:49 CEST] <nicolas17> and the 'fg' command to resume
[07:20:03 CEST] <mozzarella> other than that
[07:20:48 CEST] <dystopia_> on windows use the pause key on the keyboard
[07:20:58 CEST] <dystopia_> and return key to resume
[07:21:57 CEST] <nicolas17> there is a *lot* of intermediate state in memory and there is no way to dump it to disk
[07:26:41 CEST] <nicolas17> is vidstabtransform's interpolation parameter for pixel interpolation or camera path interpolation?
[07:28:15 CEST] <Cracki> on windows, just select in the terminal. it'll fill up the output buffer and block the process.
[07:40:32 CEST] <nicolas17> is there any filter to compensate brightness changes across time?
[07:49:42 CEST] <Cracki> something that does auto gain/brightness/exposure? mebbeh... should be likely to exist
[07:50:22 CEST] <Cracki> eq filter, says ddg
[07:50:27 CEST] <nicolas17> I filmed a presentation, at one point I made the camera focus and adjust brightness for the projector image, which darkened the whole image
[07:50:53 CEST] <nicolas17> when the image gets darkened a bit like that, vidstab gets absolutely confused and starts shaking the image around
[07:51:23 CEST] <nicolas17> Cracki: eq seems to be to adjust the brightness by <expression>
[07:51:29 CEST] <Cracki> ya, my mistake
[07:51:46 CEST] <Cracki> if nothing else works, drop into python. pyav is getting soem development efforts
[07:52:51 CEST] <Cracki> this maybe? https://video.stackexchange.com/questions/14603/what-is-the-ffmpeg-filter-equivalent-of-automatic-levels-for-colors
[07:53:24 CEST] <Cracki> so pp=al
[07:53:35 CEST] <Cracki> but that might need some thresholds
[07:53:54 CEST] <Cracki> looks like it works on max/min only, not on some average brightness and range
[07:54:29 CEST] <Cracki> what you'd need is an expression containing average brightness
[07:54:53 CEST] <furq> !filter histeq
[07:54:53 CEST] <nfobot> furq: http://ffmpeg.org/ffmpeg-filters.html#histeq
[07:55:55 CEST] <Cracki> be aware histogram equalization can be nonlinear
[07:59:17 CEST] <Cracki> ok I can't figure out what the hell that filter does. the colors are really weird
[07:59:43 CEST] <nicolas17> Cracki: http://nicolas17.s3.amazonaws.com/vidstab-detect.mp4
[07:59:58 CEST] <Cracki> nice viz
[08:00:21 CEST] <Cracki> if you have a video editing program, maybe look in there
[08:00:46 CEST] <Cracki> i remember adobe premiere having a shitty autoexposure filter. maybe they rewrote or replaced that with something good.
[08:01:39 CEST] <Cracki> if you can't find an autoexposure filter in ffmpeg, someone should maybe set that up as a GSoC task, or hit me up with handholding for filter programming
[08:02:25 CEST] <nicolas17> sec, I'll show you what happens when I actually try to run vidstabtransform
[08:02:28 CEST] <Cracki> the math is trivial to formulate for opencl, and the only issue would be working in a linear color space
[08:02:55 CEST] <nicolas17> Cracki: http://nicolas17.s3.amazonaws.com/vidstab.mp4
[08:02:56 CEST] <Cracki> haha the vidstab gets confused by brightness changes, that's bad
[08:03:10 CEST] <Cracki> that is bad
[08:03:21 CEST] <Cracki> ok for the vidstabdetect, add a laplacian or sobel
[08:03:34 CEST] <Cracki> this will remove absolute brightness and only give it edges/texture to work on
[08:04:28 CEST] <Cracki> guys throw money at me, I'm good with computer vision, all that shit is easy to have, I just don't have any experience writing ffmpeg filters
[08:07:33 CEST] <Cracki> right now I don't have the urge, but I was considering parallelizing the qtrle encoder too
[08:12:57 CEST] <nicolas17> Cracki: I think pp=al is busted by the ceiling lights
[08:13:05 CEST] <nicolas17> which stay at max brightness even as the whole image gets darker
[08:13:09 CEST] <Cracki> yep, max/min, what I thought
[08:13:39 CEST] <Cracki> if you anticipate more video work, see about doing it through a python step
[08:14:37 CEST] <nicolas17> I'll try histeq
[08:14:53 CEST] <Cracki> some step to get linear f32 or u16 from ffmpeg into python, then do stuff on that, then send it back. pyav uses the libraries directly, doesn't mess around with subprocesses like other wrappers
[08:15:33 CEST] <nicolas17> I think that almost worked :O
[08:15:42 CEST] <nicolas17> it looks ugly
[08:15:49 CEST] <nicolas17> but it doesn't matter since it's only used for vidstabdetect
[08:16:01 CEST] <nicolas17> now let's see the stabilized image
[08:17:04 CEST] <nicolas17> there's some small high-frequency shaking hm
[08:21:28 CEST] <Cracki> add smoothing
[08:21:33 CEST] <Cracki> to the vidstab tracking
[08:21:38 CEST] <Cracki> it should have options for that
[08:22:09 CEST] <nicolas17> I'm using tripod mode, it's mutually exclusive with smoothing
[08:22:11 CEST] <Cracki> ideally it should do subpixel-precise tracking (possible due to patch matching, not point matching), but no idea if it does
[08:22:15 CEST] <Cracki> hm
[09:01:28 CEST] <tadau> hi, i had an early dropout and can't play the resulting mp4 - any advice?
[09:02:28 CEST] <tadau> err msg was sth like 'conversion failed'?
[09:16:24 CEST] <Cracki> tadau, if that mp4 has no moov atom (process crashed), it can be hard/impossible to recover
[09:16:50 CEST] <Cracki> what exactly do you mean
[09:32:08 CEST] <tadau> Cracki: i encoded sth by: 'ffmpeg -i IN -c:v libx264 OUT.mp4' but unfortunately it stoped before time. When I try to play that OUT.mp4 I see an endless list of 'seek failed' errors.
[09:32:39 CEST] <tadau> and before you ask - IN was a stream, so no chance to re-run that line
[09:33:42 CEST] <tadau> what is this moov atom anyway - and why is it only calculated / made up in the end?
[09:35:02 CEST] <Cracki> media containers contain tree structure
[09:35:15 CEST] <Cracki> actual audio/video bitstreams, metadata, jump tables to keyframes, ...
[09:35:38 CEST] <Cracki> the moov atom contains information about the streams, their codecs, durations, width height sample rate etc
[09:36:01 CEST] <Cracki> for mp4s, the moov atom is usually written at the end, because you don't really know how large it'll be at the beginning
[09:36:03 CEST] <tadau> but would'nt it be safer to keep these tables in small chunks all over the file?
[09:36:09 CEST] <Cracki> if you do this a lot, look into segmented/fragmented mp4
[09:36:18 CEST] <Cracki> that does exactly this
[09:36:41 CEST] <tadau> segmented/fragmented as an option to libx264?
[09:36:42 CEST] <Cracki> other formats seem to be smarter about this. try this with mkv maybe
[09:36:46 CEST] <Cracki> as an option to ffmpeg
[09:36:53 CEST] <Cracki> it's a container option, not a codec option
[09:37:01 CEST] <tadau> ok, will see the manual for that, tx
[09:37:39 CEST] <tadau> and now for my broken file - what can be done, what could i try to recover or restore?
[09:37:48 CEST] <Cracki> uh, what codecs were used?
[09:38:29 CEST] <tadau> libx264 and libmp4lame
[09:38:33 CEST] <tadau> libx264 and libmp3lame
[09:38:41 CEST] <Cracki> you can try recreating the circumstances of the recording, and mess around with the moov atom, transplant it. it won't be perfect, but it *might*, if the bitstreams are interleaved exactly the same, give you access
[09:38:57 CEST] <Cracki> possibly the bitstream packets/frames are contiguous in the mdat atom
[09:39:07 CEST] <Cracki> if so, you could identify them, their length, and extract
[09:39:16 CEST] <Cracki> this is the forensics approach
[09:39:38 CEST] <tadau> wut? create a new file with the same length and cut of the end to paste it to the broken one??
[09:40:00 CEST] <Cracki> I've never had to do this for a multistream file, only for qtrle without audio (then the mdat contains the single qtrle video stream)
[09:40:05 CEST] <Cracki> not quite
[09:40:31 CEST] <Cracki> you'll have to maintain the proper tree structure, but maybe copying the moov atom contents is good enough
[09:40:34 CEST] <Cracki> no guarantees though
[09:40:47 CEST] <Cracki> especially for variable bitrate codecs, this is likely to fail
[09:41:04 CEST] <Cracki> data is interleaved in the mdat atom. the interleaving is recorded outside, in the moov atom
[09:41:34 CEST] <Cracki> some bitstream "frame" formats are unframed, so you can't reliably detect where they start and end
[09:41:46 CEST] <Cracki> with knowledge of the codecs, you can eyeball it
[09:42:06 CEST] <Cracki> the best assumption is that your file is junk
[09:42:14 CEST] <tadau> so mp4 is keeping track of all those stuff in memory only? and only writes it down at the end? is that what you're telling me?
[09:42:22 CEST] <Cracki> as long as it's still writing, yes
[09:42:39 CEST] <tadau> wow - that *§$%§*"*
[09:42:40 CEST] <Cracki> and it's not mp4, it's the application that does the muxing
[09:42:44 CEST] <tadau> :(
[09:42:54 CEST] <Cracki> that's why fragmented mp4 muxing option
[09:43:07 CEST] <Cracki> fragmented/segmented, can't remember the term
[09:43:14 CEST] <tadau> so you mean i would face the same probs with any other codec?
[09:43:22 CEST] <Cracki> yes
[09:43:25 CEST] <Cracki> the codecs are not at fault
[09:43:43 CEST] <Cracki> it's a problem all container formats face.
[09:43:56 CEST] <Cracki> some muxers periodically update a header...
[09:44:05 CEST] <Cracki> even avi and mkv files can break.
[09:44:16 CEST] <Cracki> the question is how recently did they write enough metadata
[09:44:45 CEST] <tadau> Basic stream segmenter <- that one?
[09:44:54 CEST] <Cracki> avi files are so old, most of the metadata is fixed length and iirc the interleaving is selfdelimited or something
[09:44:58 CEST] <Cracki> no idea
[09:45:13 CEST] <Cracki> lemme search
[09:45:34 CEST] <Cracki> -movflags
[09:45:37 CEST] <Cracki> that's the basic entry
[09:45:42 CEST] <Cracki> https://ffmpeg.org/ffmpeg-formats.html#Options-8
[09:45:47 CEST] <Cracki> frag_keyframe perhaps
[09:45:48 CEST] <tadau> The segmenter muxer outputs streams to a number of separate files of nearly       fixed duration. Output filename pattern can be set in a fashion similar to       image2.
[09:45:57 CEST] <tadau> oh, tx
[09:46:08 CEST] <Cracki> no need for separate files
[09:46:25 CEST] <Cracki> -frag_duration maybe
[09:46:29 CEST] <Cracki> depends on what you want
[09:46:44 CEST] <tadau> yeah, didn't get it - thought it might create only virtual files inside a container
[09:46:54 CEST] <Cracki> this will create one mp4/mov but it contains fragments (with moov atoms) at fixed intervals
[09:47:02 CEST] <Cracki> it does.
[09:47:10 CEST] <tadau> that sounds about right :)
[09:47:31 CEST] <Cracki> ts are mpeg transport streams, they are a different beast
[09:48:23 CEST] <Cracki> I'm not even sure if transport streams even contains an index. they don't interleave at all because the basic packet size is so small that it doesn't make sense
[09:48:32 CEST] <Cracki> (meaning: a transport stream will never break)
[09:48:49 CEST] <Cracki> so if you want to record, record to a transport stream or to a fragmented mov/mp4
[09:49:36 CEST] <tadau> but just out of curiousity and for any lazy folks that might be following us ;-) - could i've just said 'OUT.mkv' instead of 'OUT.mp4' and ffmpeg would have automagically saved me from this calamity?
[09:51:05 CEST] <Cracki> not sure
[09:52:06 CEST] <Cracki> mov and mkv are program formats. they're not meant to be faulttolerant.
[09:52:34 CEST] <Cracki> "program"/"transport" is an MPEG-world distinction
[09:53:02 CEST] <Cracki> program is the content and the content only. transport contains program + metadata for fault tolerance and other stuff, but doesn't contain "conveniences" such as seek tables.
[09:53:28 CEST] <Cracki> "program" is logically what's presented to the viewer, i.e. all streams, their meanings, ...
[09:54:14 CEST] <Cracki> HAH! just tried with frag_duration. it works as expected.
[09:54:23 CEST] <Cracki> recorded ~14 secs at 5s intervals, playback shows me 10 secs
[09:54:35 CEST] <Cracki> (because I killed the process. proper termination gives 14 secs)
[09:54:39 CEST] <tadau> Cracki: ty very much :-)
[11:23:30 CEST] <Plop2> hi all
[11:24:15 CEST] <Plop2> is someone has a pointer to a documentation or even an exmaple to explin how to encode H264 stream form a series of images and send it through a network stream ?
[11:24:45 CEST] <Plop2> All that i've tried does not work for now...
[14:04:51 CEST] <dragmore88> hi! anyone know how i can extract audio channel 1 and 2  (FL, FR) from a prores stream and output it as a stereo track through amerge ? Cant seem to get the syntax to work..
[14:16:07 CEST] <vlt> dragmore88: What have you tried so far?
[14:38:11 CEST] <dragmore88> vlt: -vn -filter_complex "[0:7][0:8]amerge=inputs=2[aout]" -map "[aout]" -c:a pcm_s24le
[14:39:08 CEST] <dragmore88> vlt: not happy with the quality, should prolly use the 6 first tracks, and make a downmix of those
[14:44:54 CEST] <dragmore88> Another question from me; can ffmpeg onthe fly igmp join a 7 SPTS multicast group and repackage it as mp4 and HTTP it out ?
[14:46:03 CEST] <dragmore88> ismv
[14:46:58 CEST] <BtbN> "http it out"?
[14:47:06 CEST] <BtbN> mp4 is not streamable
[14:47:23 CEST] <BtbN> and running an http server to serve stuff is up to you
[14:47:39 CEST] <bencoh> ismv is a bit better though
[14:49:34 CEST] <dragmore88> the target is for Unified Streaming platform
[14:50:12 CEST] <dragmore88> we have harmonic electra transcoders today, but they can only output mulitple profiles via multicast.. unified streaming expects ismv mp4 as input
[14:50:30 CEST] <dragmore88> unified streaming would be the origin server
[14:51:14 CEST] <dragmore88> so if i could use ffmpeg inbetween and take it from multicast SPTS to unicast ismv
[14:52:25 CEST] <Nacht> We're getting ISMV streams from Electra Harmonics on our Unified. So it should be possible ?
[14:52:27 CEST] <DHE> ffmpeg can join multicast. not sure about ismv output specifically. isn't that microsoft smoothstreaming?
[14:52:38 CEST] <Nacht> Afaik the people who send it aren't using FFMPEG in between
[15:03:42 CEST] <dragmore88> Nacht, what exact product are u using and version ? (that can produce ISMV compliant streams over http ?
[15:05:10 CEST] <dragmore88> http://docs.unified-streaming.com/documentation/package/content_description.html
[15:06:54 CEST] <dragmore88> http://docs.unified-streaming.com/faqs/factsheet.html#supported-ingest
[15:07:28 CEST] <dragmore88> it only says fragmented MP4
[15:07:36 CEST] <dragmore88> as inout
[15:07:38 CEST] <dragmore88> input*
[15:08:01 CEST] <dragmore88> haha.. ffmpeg is mentioned in the supported encoders ;)
[15:08:04 CEST] <Nacht> Let's see, they are/were using Electra VS with Firmware 05.00.01, we're running 1.7.19 of Unified Origin
[15:08:29 CEST] <Nacht> Yeah Unified even has a Live Encoder sample on their support pages using FFMPEG
[15:08:36 CEST] <dragmore88> url ?
[15:08:54 CEST] <Nacht> http://docs.unified-streaming.com/installation/evaluation.html#live-demo
[15:28:09 CEST] <dragmore88> nacht, thx
[15:49:27 CEST] <nicolas17> tadau: btw, if ffmpeg crashes or similar, you get your problem of an unusable .mp4, but if you abort it properly (pressing q or Ctrl-C) it will write the moov atom
[16:27:49 CEST] <pavel> Hello! When i try to use h264_vaapi encoder with quality > 2, I see error: "Failed to end picture encode issue: 18 (invalid parameter).". What I doing wrong?
[16:28:43 CEST] <pavel> Documentation says that quality may be in range 0..8
[16:33:35 CEST] <jkqxz> Documentation says that quality may be in some driver-determined range.  Probably your driver only supported 0-2.
[16:35:02 CEST] <pavel> Hmm, thanks
[16:35:45 CEST] <jkqxz> (If you use a more recent version it checks the range and will give you a better error message.)
[16:53:33 CEST] <mcJack> Hi, I try to create a multichannel ogg file from 28 wav files. It worked in several instances, but the same command triggers an assert in some cases, here is the paste: https://pastebin.com/cvz6TWk0
[16:53:59 CEST] <mcJack> This is the assert: Assertion outlink->channel_layout == out_layout || !outlink->channel_layout failed at libavfilter/af_aresample.c:174
[16:54:14 CEST] <mcJack> Has anybody an idea, how that can be resolved?
[16:57:11 CEST] <Nacht> mcJack: What do you use that needs to have 28 different channels ? Just curious
[16:57:48 CEST] <mcJack> it's a dynamic music library, the stereo stems are mixed on the fly
[16:58:38 CEST] <mcJack> before whe had the stems stored individually, but having one multi channel file saves a lot of CPU on the client's side
[16:59:49 CEST] <Nacht> I see. Thanks for shedding some light on that :)
[17:00:02 CEST] <mcJack> my pleasure :-)
[17:01:01 CEST] <c_14> mcJack: try updating your ffmpeg
[17:01:04 CEST] <c_14> the one you have is pretty old
[17:01:10 CEST] <c_14> http://johnvansickle.com/ffmpeg/
[17:01:21 CEST] <c_14> try a static build
[17:02:40 CEST] <mcJack> I see, it's the one Ubuntu-16.04 selects& I'll build it manually and see, if that helps& thanks so far
[17:10:34 CEST] <mcJack> c_14: I tried the static builds, 3.3, unfortunately the error stays the same: https://pastebin.com/5mxmPUBn
[17:10:58 CEST] <mcJack> trying nightly build next
[17:13:08 CEST] <mcJack> and again, just the linenumber changes, that shows me at least I am not running the same thing each time ;-)
[17:16:03 CEST] <c_14> hmm
[17:16:05 CEST] <c_14> worth a shot
[17:16:17 CEST] <mcJack> sure, thanks :-)
[17:21:34 CEST] <mcJack> Here an example when it works: https://pastebin.com/MKW6cg8W
[17:26:27 CEST] <c_14> Does vorbis have a maximum number of channels?
[17:27:17 CEST] <c_14> hmm, up to 255
[17:32:27 CEST] <c_14> You can try setting -och 56 -osr 48k ?
[17:32:44 CEST] <c_14> Because the assertion is something with aresample
[17:33:42 CEST] <c_14> (so I'm just trying to override some of the things it would otherwise autodetect)
[17:33:53 CEST] <c_14> You can check in ffmpeg-resampler(1)
[17:34:47 CEST] <mcJack> cheers, I'll try that& had experimented with ac, but that didn't do anything
[17:36:23 CEST] <c_14> maybe also set -ocl 56c
[17:36:40 CEST] <c_14> possibly with a capital C instead of the lowercase one
[17:36:51 CEST] <c_14> (describen in ffmpeg-utils(1) in the Channel Layout section)
[17:44:16 CEST] <mcJack> didn't change anything. -ocl doesn't get through the parser, I might use it wrong
[17:45:40 CEST] <mcJack> ah, sorry, 56c is "Error setting option ocl", but 56C renders: [SWR @ 0x4cbc520] Unable to parse option value "56C" as channel layout
[17:51:26 CEST] <c_14> *sigh*
[17:51:30 CEST] <c_14> that's a bug
[17:51:33 CEST] <c_14> I might fix it
[17:51:50 CEST] <c_14> But it won't help you immediately
[17:52:11 CEST] <c_14> try just -ocl 56
[17:52:19 CEST] <c_14> If I read the code correctly, that should work
[17:53:15 CEST] <mcJack> jepp, that parses correectly, but it still asserts :-/
[17:53:40 CEST] <mcJack> do you have an idea, what the root cause could be?
[17:54:27 CEST] <c_14> I'm just grasping at straws
[17:55:03 CEST] <mcJack> I see& if you have an idea, I am happy to test anything you throw at me ;-)
[18:03:35 CEST] <krvl> Hi all
[18:06:24 CEST] <krvl> I have a problem with mpeg-dash streaming: the player stuck when it reaches the last fragment (I'm testing atm with dash.js library). Do I need to reload the manifest?
[18:13:31 CEST] <azarus> Does anyone know how to enable x11grab on gentoo?
[18:14:59 CEST] <kepstin> azarus: you'll need the xcb option enabled to get xcbgrab
[18:15:11 CEST] <kepstin> (which is probably what you're looking for)
[18:15:46 CEST] <azarus> kepstin: Yup, found it. x11grab seems deprecated.
[18:16:22 CEST] <azarus> Thanks!
[18:37:35 CEST] <azarus> What are some fast-to-encode video codecs?
[18:38:03 CEST] <durandal_1707> utvideo and others
[18:41:58 CEST] <mcJack> c_14: I can pass the assert, if I could set the output layout to 0? is that possible? And could that help me?
[18:45:24 CEST] <c_14> you can try
[18:45:56 CEST] <mcJack> how can I set that from the command line? ocl 0 doesn't work
[18:50:38 CEST] <c_14> 0c maybe?
[18:51:10 CEST] <c_14> ah, nvmd
[18:51:16 CEST] <c_14> If it gets 0 it throws an error
[18:51:53 CEST] <mcJack> Too bad& I was just wondering, why it is excluded from that assert& but probably because it was checked before...
[18:55:22 CEST] <mcJack> Ok, I'll be back tomorrow& thanks so far!
[18:58:11 CEST] <kbaegis> *sigh* Anyone know why aac (native) to aac (native) transcoding would fail from mkv -> mp4?
[18:58:22 CEST] <kbaegis> works with the -an arg
[18:59:17 CEST] <BtbN> can't just codec copy?
[19:00:45 CEST] <kbaegis> https://pastebin.com/5FviNifW
[19:01:20 CEST] <c_14> add -c copy
[19:01:44 CEST] <c_14> I don't see why you'd need to reencode that
[19:01:51 CEST] <kbaegis> Ahh, gotcha.
[19:02:04 CEST] <kbaegis> Well, probably because I didn't know ffmpeg didn't handle that for me :)
[19:06:56 CEST] <kbaegis> Umm
[19:07:01 CEST] <kbaegis> What's the underlying issue though?
[19:07:13 CEST] <kbaegis> What if I did want to xcode?
[19:07:54 CEST] <kbaegis> Still seeing Too many packets buffered for output stream 0:1.
[19:08:00 CEST] <kbaegis> (which is the audio)
[19:09:48 CEST] <kbaegis> c_14? anyone?
[19:10:20 CEST] <c_14> I have no clue
[19:10:40 CEST] <c_14> ffmpeg usually also outputs a more helpful error
[19:10:42 CEST] <c_14> but there is none
[19:10:43 CEST] <kbaegis> How do I run a -vvv or debug in ffmpeg?
[19:10:48 CEST] <c_14> -loglevel debug
[19:10:54 CEST] <kbaegis> Awesome, ty
[19:11:12 CEST] <kbaegis> Yeah, I can't make an avi with it (not that I'd want to), but I can strip the audio channel out into a separate mp3
[19:11:14 CEST] <kbaegis> Weird
[19:17:13 CEST] <blaenk> is there a way to mix/combine two audio tracks in an mp4 into a single one?
[19:33:56 CEST] <blaenk> got it, using amerge
[19:34:22 CEST] <kepstin> hmm, depends what you're trying to do, you might want amix instead
[19:34:49 CEST] <kepstin> if you have two stereo tracks, and you want them mixed together into a single stereo track, use amix.
[19:35:37 CEST] <blaenk> why?
[19:36:22 CEST] <c_14> amerge with 2 stereo files will give you one 4.0 file
[19:36:29 CEST] <c_14> amix with 2 stereo files will give you one stereo file
[19:36:59 CEST] <c_14> (by mixing the left channel from one file with the left from the other file and the rights etc)
[19:38:03 CEST] <blaenk> trying to make sense of that. the two audio tracks are indeed stereo, and the result of using amerge seems to show a single stereo track
[19:38:53 CEST] <blaenk> here's the mediainfo of the amerge result https://gist.github.com/anonymous/6c86c60231c37f4a6994ba4a135b76bf
[19:39:28 CEST] <c_14> what was the command you used to create the file?
[19:39:42 CEST] <blaenk> I'm also using -filter_complex, maybe that's doing it
[19:40:08 CEST] <blaenk> sec
[19:40:12 CEST] <blaenk> ffmpeg -i in.mp4 -filter_complex "[0:a]amerge=inputs=2[a]" -map 0:v -map "[a]" -c:v copy -c:a libmp3lame -ac 2 out.mp4
[19:40:35 CEST] <c_14> >-ac 2
[19:40:41 CEST] <c_14> you're downmixing the result
[19:40:44 CEST] <blaenk> ah of course
[19:40:57 CEST] <blaenk> so it's creating the 4.0 like you said, then downmixing
[19:41:06 CEST] <blaenk> different from using amix to create a 2.0 to begin with?
[19:41:28 CEST] <c_14> In this case probably not
[19:41:31 CEST] <c_14> In a more complex case maybe
[19:41:45 CEST] <blaenk> I'll try to form the equivalent amix command
[19:44:49 CEST] <igracia> hey! posted a question in the forum here http://ffmpeg.gusari.org/viewtopic.php?f=11&t=3434&p=11061#p11061
[19:45:20 CEST] <igracia> it's related to offsetting videos in a mosaic built with hstack and vstack
[19:46:21 CEST] <igracia> is there a way to make hstack show a black frame for the duration of the time specified in PTS-STARTPTS+{offset}?
[19:46:35 CEST] <igracia> or this can only be achieved via overlay?
[19:47:14 CEST] <c_14> just concat the inputs you want to delay with a color=black,trim=d=<duration>
[19:48:19 CEST] <blaenk> ffmpeg -i input.mp4 -filter_complex "[0:a]amix=inputs=2[a]" -map 0:v -map "[a]" -c:v copy -c:a libmp3lame -ac 2 "mixed.mp4"
[19:48:23 CEST] <blaenk> that look ok?
[19:48:35 CEST] <igracia> hum, is that faster than using overlay? if I have 16 videos (4x4 matrix) I will need 15 concats
[19:48:36 CEST] <blaenk> is it ok to leave the -ac 2 in there or is it having an unintended effect
[19:49:48 CEST] <kbaegis> Here's an updated paste with the loglevel turned up: https://pastebin.com/8m0SxZrJ
[19:50:54 CEST] <c_14> blaenk: you can leave it, but you don't need it
[19:51:26 CEST] <blaenk> sweet. thanks c_14
[19:51:39 CEST] <kbaegis> Seeing a lot of "cur_dts is invalid"
[19:52:22 CEST] <c_14> there's probably something funky with the input stream that the encoder dislikes
[19:53:44 CEST] <kbaegis> c_14: Since I can split audio away from the file successfully as well as video, is there a way to remerge the two streams?
[19:54:53 CEST] <c_14> yeah
[19:54:59 CEST] <c_14> just list them individually as inputs
[19:57:38 CEST] <kbaegis> I'll have to see if I have syncing issues, but maybe that will be the way to go
[20:28:38 CEST] <dorvan> hi all
[20:29:25 CEST] <durandal_170> hi
[20:32:36 CEST] <dorvan> on a net camera: stream 2560x1440, 30fps, 8192k, high, as encoding parameters, create an mp4 with a 1mbyte/s (8mbit/s) so 60mbyte/minute video, parameters are not correlated in the netcam interface, how i can find the lossless settings reducing bitrate?
[20:33:08 CEST] <nicolas17> dorvan: *lossless* settings will make the file larger than that
[20:34:12 CEST] <dorvan> nicolasl7 those are the losslessy settings... i have to compress... and reduce the bandwidth.
[20:35:43 CEST] <nicolas17> then you'll lose quality
[20:35:44 CEST] <nicolas17> you can probably tweak it so the quality loss is not noticeable, but you'll lose quality :P
[20:35:51 CEST] <nicolas17> just nitpicking on "lossless" terminology
[20:37:21 CEST] <dunpeal> Hi. I have an MP4 ("m4b") file, with chapter marks. Is there a straightforward way to cut 5 minutes off the beginning of this file, while preserving the correct chapter indices?
[20:40:57 CEST] <dorvan> nicolas17: obviously, looking to selectable params what i have prefer to change to reduce as possible, without a visible significant lossy?
[20:42:33 CEST] <klaxa> if you can pass crf values, increase it so far you still "like" it
[20:42:45 CEST] <klaxa> higher crf -> more quality loss, less bitrate
[20:47:47 CEST] <nicolas17> dorvan: "lossless" has a specific meaning in video encoding, meaning literally lossless, same pixels in and out, that means very very high bitrate
[20:49:03 CEST] <dorvan> nicolas17: i know..  i've explained what i want to say in the latest phrase. are you locked on "lossless" term?
[20:49:54 CEST] <nicolas17> what klaxa said, use crf :)
[20:57:07 CEST] <dorvan> it's a ffmpeg instance inside a network camera, i can set ONLY that settings...
[21:00:00 CEST] <dorvan> so... restart :-D on a net camera ( <--- net cam! ):  i have a stream of 2560x1440, 30fps, 8192k, high, as encoding parameters ( i can play with bitrate and profile firstly) this settings creates an mp4 with a 1mbyte/s (8mbit/s) so 60mbyte/minute video, parameters are not correlated in the netcam interface, how i can find the lossless as possible settings reducing bitrate?
[21:01:55 CEST] <klaxa> repeating it doesn't make it any less wrong?
[21:02:31 CEST] <klaxa> what is the setting you can influence exactly?
[21:03:23 CEST] <nicolas17> reduce bitrate
[21:03:40 CEST] <dorvan> maintaining quality as possible,
[21:04:02 CEST] <dorvan> obviously all solutions are lossy
[21:04:04 CEST] <nicolas17> if it starts looking bad, you may get improvements by changing the preset to a slower one, but it seems like you can't change preset and probably the camera doesn't have the CPU for it anyway
[21:04:44 CEST] <klaxa> well just decrease the bitrate then? constant bitrate encoding is pretty bad though
[21:04:52 CEST] <klaxa> it's not something where you can throw math at it
[21:04:55 CEST] <klaxa> quality is subjective
[21:05:59 CEST] <dorvan> seem looking to cam gui and manuale, setting are not directly correlated, and this it's not really possible...
[21:08:02 CEST] <dorvan> klaxa: yes quality it's subjective but loking to the stream output you have to see the "same" so i refer to not visible differencies about quality
[21:08:10 CEST] <dorvan> looking*
[21:08:37 CEST] <nicolas17> if all you can tweak is the bitrate, there isn't much you can do
[21:08:58 CEST] <nicolas17> obviously you could use lower resolution (width x height) or lower framerate :P
[21:09:16 CEST] <klaxa> what do you want us to tell you here? "use magical parameter --pixie-dust and all your problems will be resolved"?
[21:09:26 CEST] <nicolas17> what file size are you expecting to get?
[21:10:00 CEST] <klaxa> for quality comparison you encode multiple samples and compare them by eye
[21:10:27 CEST] <nicolas17> klaxa: oh but the camera settings don't have a way to set --pixie-dust! ;)
[21:10:31 CEST] <klaxa> if you want to compare pixel by pixel, do that, but with lossy encoding there will always be differences in every frame if you change the bitrate
[21:10:57 CEST] <dorvan> klaxa: opposite... playing with usable settings to get the best as possible with less delay and smallest file without downscaling or reduce framerate.
[21:11:23 CEST] <nicolas17> dorvan: but the only settings you can change are image size, framerate, bitrate, and profile?
[21:11:39 CEST] <dorvan> klaxa: ok with nude eyes you compare 4MP image with other?
[21:11:52 CEST] <klaxa> with what else
[21:11:53 CEST] <dorvan> at 30fps? .....
[21:12:04 CEST] <klaxa> do you have other visual organs? i don't :P
[21:12:38 CEST] <klaxa> if you really want to you can compare them with ssim and/or psnr
[21:12:58 CEST] <nicolas17> why get more quality if you won't *see* the difference?
[21:13:15 CEST] <dorvan> oh fuck*** probably you check video sources at fps read the bytes directly and comparing they... :-)
[21:13:21 CEST] <nicolas17> is it in case some day you need to zoom in on the video to see a detail? in that case, do the comparison zoomed in now
[21:14:28 CEST] <dorvan> nicolas17: i have to reduce delay mantaining a 4MP image at 30fps and video smooth, i have only those parameters to play with...
[21:15:35 CEST] <nicolas17> if I understood correctly, the only settings you can change are image size, framerate, bitrate, and profile
[21:15:47 CEST] <dorvan> firstly changeable params -> bitrate, and profile
[21:16:01 CEST] <dorvan> then...  image size, framerate,
[21:16:08 CEST] <dorvan> as last option
[21:16:24 CEST] <nicolas17> you don't want to change image size (downscale) or frame rate, profile is already "high", so all you have left is reducing the bitrate
[21:16:56 CEST] <klaxa> in fact, bitrate is the only factor affecting filesize
[21:17:31 CEST] <nicolas17> klaxa: if he had access to 'preset' he could make it slower while reducing bitrate, to *maybe* keep the same quality
[21:17:50 CEST] <klaxa> bitrate would still be the only factor affecting filesize
[21:17:54 CEST] <nicolas17> yep
[21:18:06 CEST] <nicolas17> dorvan: what file size are you expecting to get?
[21:18:48 CEST] <dorvan> nicolas17: i think 20%  less then now
[21:19:22 CEST] <nicolas17> so 48MB/s?
[21:19:23 CEST] <nicolas17> er
[21:19:29 CEST] <nicolas17> so 48MB/hour?
[21:19:30 CEST] <dorvan> profile can help me to reduce delay plus with bitrate reduction?
[21:19:34 CEST] <nicolas17> I keep mixing things up
[21:19:35 CEST] <nicolas17> /minute!
[21:19:48 CEST] <dorvan> i hope more... it's for minute...
[21:20:08 CEST] <dorvan> because seems too large for the quality acquired by cam sensor...
[21:20:13 CEST] <nicolas17> you're getting 60MB/minute now, 20% less is 48MB/minute
[21:20:33 CEST] <dorvan> i yes, something like this i hope...
[21:20:57 CEST] <dorvan> i have 1mbit/s steps in the selector..
[21:21:12 CEST] <nicolas17> 48MB/minute is about 6711k bitrate
[21:22:12 CEST] <dorvan> i have 6mbit/s so 46mbyte/m
[21:22:19 CEST] <dorvan> or less...
[21:35:07 CEST] <dorvan> nicolas17: I'm trying with baseline profile and 6mbit/s bandwidth
[21:44:11 CEST] <acos> Good afternoon
[21:45:51 CEST] <acos> I am having some issues with trying to merge videos.  But before that how can I fix dts errors and choppy playback?
[21:59:54 CEST] <durandal_170> acos: what container?
[22:00:34 CEST] <acos> Avi h264
[22:01:08 CEST] <acos> It says dts non contiguous.
[22:01:36 CEST] <acos> And keeps spamming the console.  The file sticks on playback during some parts.
[22:03:44 CEST] <acos> durandal_170: it also converted the file to 1920x1088 :(
[22:04:52 CEST] <durandal_170> avi is crap
[22:05:23 CEST] <acos> And frame rate is 28.662420
[22:05:43 CEST] <acos> The video editor I am using is limited. Wasn't sure what format to export too
[22:27:34 CEST] <durandal_170> acos: what else it can export?
[22:28:10 CEST] <acos> Wmv..... some you have to pay for to unlock in the software.
[22:28:24 CEST] <acos> I Wil have more info tonight busy now
[22:29:27 CEST] <durandal_170> wmv is asf and it may be better but dunno what it supporrts
[22:30:09 CEST] <JEEB> in theory you can stick almost whatever you want into ASF, but officially it's just WMV and WMA derivatives
[22:30:59 CEST] <klaxa> in theory, it seems, people hack just about everything into avi too :P
[22:33:31 CEST] <thebombzen> RIFF stuffs
[23:52:13 CEST] <DHE> acos: officially AVI does not support bframes. when transcoding set that to 0
[23:55:29 CEST] <acos> Hmmmm. Not sure.  What format should I even be using ?
[00:00:00 CEST] --- Wed Aug 30 2017


More information about the Ffmpeg-devel-irc mailing list