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

burek burek021 at gmail.com
Thu Jun 7 03:05:02 EEST 2018


[01:08:59 CEST] <shfil> hi, as far I know pcm_s16le doesn't contain info about channels layout, I know that I need set it for swr resample, should I do something more?
[01:14:52 CEST] <kepstin> shfil: what's the context? you're building an api application? Where is the audio coming from?
[01:15:45 CEST] <kepstin> there are some container formats which can hold pcm_s16le that have channel layout info available (or have standard layouts, at least)
[01:16:16 CEST] <shfil> https://github.com/rwengine/openrw/pull/420/commits/dea8f0f9c006371ec6adc1c07a9d84cd4df5d378
[01:16:24 CEST] <kepstin> if you have raw s16le stuff, I guess you'll have to say what it is yourself.
[01:17:17 CEST] <shfil> there are short wav files
[01:17:57 CEST] <shfil> it almost works well, except quiet scrapping/interferences on the radio/ticking.
[01:18:15 CEST] <shfil> sound something like that
[01:18:26 CEST] <kepstin> from wav, I *think* you should be fine if the codec parameters are being sent from the formatcontext to codeccontext properly
[01:21:06 CEST] <shfil> something like this is ok? https://github.com/rwengine/openrw/pull/420/files#diff-e9cc6b7c0e9b40ae49ea18ed92518bfcR52
[01:21:15 CEST] <kepstin> (the stuff on line 221/222 looks like a really verbose way to write a memcpy)
[01:22:18 CEST] <kepstin> shfil: yeah, looks like the codec params are being copied correctly there, at a glance.
[01:24:08 CEST] <shfil> it's weird because decoding directly works, but after resampling to stereo there are some quiet artifacts.
[01:26:57 CEST] <kepstin> shfil: are the artifacts happening on sample loops? it looks like you're not flushing the resampler at the end of the file.
[01:27:52 CEST] <kepstin> so any buffered samples from the end of the file could be missing from your result
[01:28:52 CEST] <kepstin> (call swr_convert_frame with NULL input frame when you're done to get the remaining samples)
[01:30:32 CEST] <shfil> should I add some extra loop for it?
[01:31:48 CEST] <kepstin> no, just call it once after you're done with the loop over input should be fine
[01:34:06 CEST] <shfil> you mean loop `while ((receiveFrame = avcodec_receive_frame(codecContext, frame)) == 0) {`or that copying data
[01:34:26 CEST] <kepstin> after the avcodec_receive_frame loop
[01:36:57 CEST] <kepstin> call swr_convert_frame once on each frame you get from avcodec_receive_frame, then afterwords call it once with NULL input frame
[01:38:05 CEST] <shfil> sorry for many dump question, should I increase range of resampled or use frame?
[01:38:21 CEST] <shfil> (I mean variables)
[01:39:38 CEST] <kepstin> shfil: i'm not sure what you mean? The variable 'resampled' is an AVFrame.
[01:40:42 CEST] <shfil> `resampled` is output frame for swr_convert_frame, `frame` is input frame.
[01:42:16 CEST] <kepstin> shfil: you should only call swr_convert_frame with an output frame that doesn't have any buffers (i.e. it's newly allocated, or you've "deref"ed it)
[01:43:16 CEST] Action: kepstin would advise not re-using an AVFrame you got from the decoder for that.
[01:44:38 CEST] <kepstin> (the reason is that swr_convert_frame calls av_frame_get_buffer, which is documented to leak memory if called on a frame that already has a buffer)
[01:45:44 CEST] <kepstin> oh, i'm misreading that.
[01:46:04 CEST] <kepstin> excuse my misinformation there - if the frame has an already allocated buffer, it'll just fill that
[01:46:58 CEST] <kepstin> (if called on a frame without a buffer, it allocates a new buffer guaranteed to hold all the samples it could output - if you provide a buffer, it will only output what fits, and will internally queue stuff that doesn't fit)
[01:48:15 CEST] <shfil> so do you think it's source of problem?
[01:49:18 CEST] <shfil> (if I understand)
[01:51:27 CEST] <kepstin> my suspicion is that if you have looping audio, then the missing samples (from the resampler delay) at the end of the file with your current code might cause artifacts at the loop point.
[01:52:00 CEST] <kepstin> if you have problems elsewhere, then it's a different problem :/
[02:03:37 CEST] <shfil> thanks for help, I'll take closer look at tomorrow. ;)
[03:08:40 CEST] <tom13> are there any effective super-resolution type advanced filters that can motion-interpolate / auto-tween 24,25,30 fps video to 60fps
[03:09:15 CEST] <tom13> i've been talking with people about this since um. 2003
[03:09:25 CEST] <tom13> gettin a bit old
[04:13:00 CEST] <Moocow9m_> hello, I'm trying to build ffmpeg and got an error while configuring. (Slightly striped log for 512KB limit)LOG: https://pastebin.com/HqpCH5wv
[04:13:20 CEST] <Moocow9m_> Seems to be having a hard time linking vorbis
[04:14:03 CEST] <Moocow9m_> I am able to compile older versions of ffmpeg but 4.0 and up seems to do this
[04:24:31 CEST] <tdr> on my system, vorbis provides /usr/lib32/pkgconfig/vorbis.pc /usr/lib32/pkgconfig/vorbisenc.pc /usr/lib32/pkgconfig/vorbisfile.pc /usr/lib64/pkgconfig/vorbis.pc /usr/lib64/pkgconfig/vorbisenc.pc /usr/lib64/pkgconfig/vorbisfile.pc
[04:24:45 CEST] <tdr> (built w/ 32 + 64 bit versions)
[04:25:42 CEST] <Moocow9m_> It seems to be more with ogg methods in vorbis (also I have pkg-config set to both .pc files)
[04:26:19 CEST] <Moocow9m_> I mean vorbis.pc(multiple) files and ogg.pc file
[04:26:20 CEST] <tdr> ERROR: vorbis not found using pkg-config
[04:27:42 CEST] <Moocow9m_> line 12785 checks for vorbis with no error. it starts testing with vorbis then errors
[04:44:10 CEST] <Moocow9m_> @tdr I have this variable set before ./configure: PKG_CONFIG_PATH=/d/db6/build/S/VS1564R/Release/x264/lib/pkgconfig:/d/db6/build/S/VS1564R/Release/openjpeg/lib/pkgconfig:/d/db6/build/S/VS1564R/Release/ogg/lib/pkgconfig:/d/db6/build/S/VS1564R/Release/vorbis/lib/pkgconfig:/d/db6/build/S/VS1564R/Release
[04:44:33 CEST] <Moocow9m_> It has paths to the needed .pc files
[05:54:27 CEST] <kepstin> tom13: ffmpeg has one builtin, "minterpolate". Your results may vary :/
[05:55:46 CEST] <tom13> ty kepstin
[05:56:11 CEST] <tom13> i haven't looked into the motion interpolation of modern televisions
[05:56:20 CEST] <tom13> but i think it began in early 2000s with LG
[10:02:48 CEST] <DeDaDo_> Hello every one. Good morning, good evening and good afternoon to every one located in different time zones.
[10:03:47 CEST] <DeDaDo_> I have a question regarding video rotation. I have a video which has meta data of rotation 180 degrees. As per ffmpeg , ffmpeg will autorotate video. Is this case valid for RTMP Streaming as well?
[10:14:40 CEST] <DeDaDo_> ?
[10:18:54 CEST] <tom13> i have been looking into rem ote desktop
[10:19:29 CEST] <tom13> and ffmpeg can h264 screengrab and pipe out  the pc x session or portion of screen
[10:19:40 CEST] <tom13> with a lag about 80ms
[10:20:37 CEST] <tom13> now all someone needs is make a script that sets up that on the server, and another on remote device for playback and forwarding of inputs
[10:21:22 CEST] <tom13> nomachine nx can do h264 now also, but it is overkill for some quick gaming
[10:28:08 CEST] <Mavrik> That still sounds like x2 of what Steam/GeForce Now do. Where is the lag coming from?
[10:31:15 CEST] <tom13> i do not know what they use
[10:31:59 CEST] <tom13> i think h264 needs to buffer a few frames for its encoding
[10:32:58 CEST] <tom13> and playback devices  need some too
[10:33:27 CEST] <tom13> i am curious if you know anyone who did this
[10:42:27 CEST] <DHE> x264 can be run in zerolatency mode which brings encoder latency as low as it can. framing is up to you
[11:42:10 CEST] <DeDaDo_> Any one can help in my query please?
[11:45:31 CEST] <Mavrik> DeDaDo_: hmm, I don't think ffmpeg will autorotate video by default
[11:45:37 CEST] <Mavrik> unless you're applying a filter?
[11:54:09 CEST] <DeDaDo_> Mavrik, the video has a rotation value of 180, so ffmpeg will still not auto rotate it?
[11:54:24 CEST] <Mavrik> ffmpeg won't do auto anything
[11:54:37 CEST] <Mavrik> Because it assumes you don't want things to randomly rotate
[11:54:50 CEST] <Mavrik> It'll just pass through the rotation flag (which I assume is set) if destination container supports it
[11:56:16 CEST] <DeDaDo_> ok, so its up to the destination player to read that flag and render the video
[11:56:18 CEST] <DeDaDo_> ?
[11:57:17 CEST] <Mavrik> yep
[11:57:35 CEST] <Mavrik> I'm decently sure RTMP doesn't support that flag tho
[12:00:04 CEST] <DeDaDo_> ok thanks Mavrik for all the information.
[12:29:03 CEST] <slavanap> Is there any ability with ffmpeg to detect muted audio segments in video?
[12:41:46 CEST] <BtbN> silencedetect
[14:14:16 CEST] <slavanap> BtbN, thanks! `ffmpeg -nostats -hide_banner -i 2016.05.31.mp4 -af silencedetect=n=-50dB:d=5 -vn -f null -`   works like a charm!
[14:43:02 CEST] <xmbswc> what was the --option to disable <depending on tty/console>
[14:43:56 CEST] <DHE> -nostdin ?
[14:44:50 CEST] <xmbswc> thanks, will text, is probably it
[14:46:40 CEST] <Guest671> Hi, I'm trying to build ffmpeg with --enable-libsrt, and I'm getting "ERROR: srt >= 1.2.0 not found using pkg-config"
[14:47:04 CEST] <Guest671> Does it mean ffmpeg does not support srt above 1.2.0
[14:47:37 CEST] <DHE> if you compiled it manually, you may need to set PKG_CONFIG_PATH
[14:47:45 CEST] <xmbswc> seems to do DHE thanks
[14:50:49 CEST] <Guest671> Already set it
[14:50:53 CEST] <Guest671> PKG_CONFIG_PATH=/home/hao/repo/Transcoder/Release/libsrt/lib/pkgconfig ./configure --prefix=/home/hao/repo/Transcoder/Release/ffmpeg --enable-shared --enable-demuxer=mpegts,mpegvideo,image2 --enable-muxer=mpegts --enable-protocol=file,udp,rtp --enable-filter=overlay --enable-zlib --enable-libsrt --disable-doc
[14:51:11 CEST] <Guest671> this is my build command
[15:23:29 CEST] <zh_> PKG_CONFIG_PATH=/home/hao/repo/Transcoder/Release/ffmpeg/lib/pkgconfig ./configure --prefix=/home/hao/repo/Transcoder/Release/ffmpeg --enable-shared --enable-demuxer=mpegts,mpegvideo,image2 --enable-muxer=mpegts --enable-protocol=file,udp,rtp --enable-filter=overlay --enable-zlib --enable-libsrt --disable-doc
[15:23:34 CEST] <zh_> ERROR: srt >= 1.2.0 not found using pkg-config
[15:24:43 CEST] <JEEB> less ffbuild/config.log
[15:24:47 CEST] <JEEB> see what happened
[15:43:24 CEST] <zh_> usr/bin/ld: warning: libcrypto.so.1.0.0, needed by /home/hao/repo/Transcoder/Release/ffmpeg/lib/libsrt.so, not found
[16:37:49 CEST] <mas886> Hello there, I'm getting a resolution format I don't want with the following command "ffmpeg -i - -vcodec rawvideo -pix_fmt yuv420p -threads 0 -f v4l2 /dev/video1"
[16:38:01 CEST] <mas886> Is there anything I can do to force 1080?
[16:43:20 CEST] <Mavrik> can you pastebin the output of the command_
[16:45:08 CEST] <mas886> Mavrik: https://pastebin.com/tZdt6rfJ
[16:46:10 CEST] <mas886> I use thisto capture my DSLR camera as a webcam
[16:47:59 CEST] <Mavrik> mas886: well it seems like your input from the stdin pipe is already in a crappy resolution
[16:48:04 CEST] <Mavrik> so it's not ffmpeg that can do anything abou tit
[16:50:35 CEST] <mas886> Mavrik: Hm, too bad, thanks!
[16:50:39 CEST] <furq> i'm surprised that even works
[16:50:49 CEST] <furq> i thought you always needed to explicitly set -video_size when reading rawvideo from stdin
[16:50:54 CEST] <furq> and -framerate
[16:51:21 CEST] <Mavrik> I guess it can automagick itself from JPEG headers :)
[16:51:40 CEST] <furq> oh right it's mjpeg
[16:51:57 CEST] <furq> duh
[19:29:00 CEST] <waterworks> I'm trying to build FFmpeg with nvenc support, I've installed the ffnvcodec headers and they are found in the PKG path, but I get the error message "ERROR: nvenc requested, but not all dependencies are satisfied: ffnvcodec". The config.log shows it passing the nvenc tests and then just failing at the very end with that message.
[19:43:49 CEST] <JEEB> waterworks: post config.log on pastebin/gist/0x0.st and link here?
[19:47:02 CEST] <waterworks> JEEB: https://pastebin.com/2cTxajfe
[19:50:18 CEST] <JEEB> waterworks: seems like it fails with the "Wdeclaration-after-statement" flag
[19:50:29 CEST] <JEEB> seems to be the only test trying that
[19:50:54 CEST] <JEEB> I don't think it was tested really hard with MSVC
[19:51:08 CEST] <JEEB> or not
[19:51:23 CEST] <JEEB> that's a separate feature check
[19:51:54 CEST] <waterworks> Multiple tests fail in different feature checks. It can compile fine without nvenc specified, so that means it reads the libx264 pkg correctly but not the nvenc one.
[19:52:48 CEST] <JEEB> well if you look at that nvenc test I don't think it even fails
[19:53:25 CEST] <BtbN> it looks like the ffnvcodec tests aren't even run
[19:54:06 CEST] <BtbN> Or produce no log output. ffnvcodec needs to be found by pkg-config, and the version has to end in .2
[19:54:17 CEST] <BtbN> well, at least .2
[19:54:32 CEST] <JEEB> I see no enable-nonfree there
[19:54:39 CEST] <JEEB> waterworks: are you patching that out of configure? :P
[19:54:40 CEST] <BtbN> Why would it be there?
[19:54:47 CEST] <waterworks> The nvenc test is run at 14137.
[19:54:47 CEST] <JEEB> nvidia stuff?
[19:54:53 CEST] <BtbN> is not non-free
[19:54:59 CEST] <JEEB> ok
[19:55:12 CEST] <JEEB> right because of the RE'd'ish header :P
[19:55:31 CEST] <BtbN> The header is just released by nvidia under MIT
[19:55:34 CEST] <waterworks> My ffncvodec version is 8.1.24.3
[19:55:36 CEST] <BtbN> so there is no issue in the first place
[19:56:03 CEST] <JEEB> ok
[20:17:39 CEST] <waterworks> The error doesn't make much sense.
[20:22:40 CEST] <BtbN> What does pkg-config --cflags ffnvcodec output?
[20:24:03 CEST] <BtbN> and --modversion
[20:28:14 CEST] <waterworks> $ pkg-config --cflags --modversion ffnvcodec Ignoring incompatible output option "--modversion" -IB:/msys64/home/CF/ffmpegbuild/include
[20:37:10 CEST] <waterworks> ffnvcodec version is 8.1.24.3
[20:39:41 CEST] <feliwir> Hey, i am libav to decode a bink video. The problem i am having is that av_read_frame is always crashing when i reach EOF
[20:39:54 CEST] <feliwir> I am doing this in C#, but the bindings aren't the issue
[20:40:27 CEST] <JEEB> with the API I've generally been capable of finishing up by following https://www.ffmpeg.org/doxygen/trunk/group__lavc__encdec.html
[20:40:47 CEST] <JEEB> which is the basic documentation on how to decode/encode with the push/pull API
[20:41:15 CEST] <feliwir> JEEB, i've been following this guide
[20:42:25 CEST] <feliwir> and Reading frame/demuxing: https://github.com/OpenSAGE/OpenSAGE.FFmpeg/blob/master/src/OpenSage.FFmpeg/Source.cs#L104
[20:42:50 CEST] <feliwir> Decoding: https://github.com/OpenSAGE/OpenSAGE.FFmpeg/blob/master/src/OpenSage.FFmpeg/StreamContext.cs#L64
[20:43:05 CEST] <feliwir> and i am crashing on the av_read_frame when almost all frames have been read
[20:43:44 CEST] <feliwir> C# simply tells me "Memory corruption". Not very helpful
[20:44:14 CEST] <feliwir> Is there some API misusage i am doing?
[20:45:43 CEST] <feliwir> Help would be very appreciated
[20:53:44 CEST] <feliwir> JEEB, you maybe?
[20:54:38 CEST] <JEEB> tired after work so not touching certain things right now
[21:03:57 CEST] <feliwir> Alright :) I guess C# code is one of them
[21:38:56 CEST] <diverdude> hi. i made a windows c++ program and i need to install this: https://www.microsoft.com/en-us/download/details.aspx?id=52685   before i install the program....if i dont install that it will not run. Is there any way i can bundle this in the installer?  I think its because of ffmpeg i need this
[21:39:51 CEST] <JEEB> pretty sure there's a way to bundle those with your installer, but you only get that if you use the non-static CRTs
[21:45:17 CEST] <feliwir> he, you helped him :D
[21:51:22 CEST] <JEEB> feliwir: did I have to read a line of code?
[21:55:14 CEST] <diverdude> JEEB: the non-static CRT's ? What is that? DLL files?
[21:58:06 CEST] <feliwir> JEEB, i can describe the code to you
[22:18:06 CEST] <tom13> someone make a ffmpeg remote-desktop for me
[22:18:07 CEST] <waterworks> BtbN: Think it
[22:18:27 CEST] <waterworks> 'd be worth to post tomorrow as well?
[22:19:05 CEST] <BtbN> ffmpeg master and ffnvcodec builds fine for me on msvc. Must be something with your build env.
[22:19:35 CEST] <waterworks> What could I have different?
[22:19:54 CEST] <BtbN> no idea
[22:20:11 CEST] <waterworks> Msys2 as well?
[22:25:06 CEST] <waterworks> The only thing I do is start msys from a VS2017 environment and then use CC=cl before configure.
[22:25:17 CEST] <waterworks> I hate using msys but whatever.
[22:34:49 CEST] <waterworks> BtbN: You mind sharing what you have done to your build environment since what I have is all default?
[22:35:08 CEST] <BtbN> Nothing special really
[22:35:20 CEST] <BtbN> I'm using Cygwin as base though
[22:35:37 CEST] <BtbN> But you do pass --toolchain=msvc to configure?
[22:35:59 CEST] <waterworks> Yes
[22:36:33 CEST] <waterworks> If I take that away then it cant find x264.
[22:46:30 CEST] <waterworks> Better to use cygwin or something?
[22:47:13 CEST] <BtbN> it shouldn't matter really
[22:49:11 CEST] <waterworks> ffnvcodec shows up in pkg-config --list-all so there's no chance I've set up something wrong
[22:49:39 CEST] <waterworks> And again that it obviously passes the nvenc test as shown in the config.log
[22:50:03 CEST] <BtbN> it doesn't even seem to do it, which is weird
[22:50:39 CEST] <waterworks> Is it not the one on line 14137?
[22:50:49 CEST] <BtbN> that's the code for it.
[22:51:00 CEST] <BtbN> and it's for nvenc, not ffnvcodec
[22:51:25 CEST] <waterworks> ffnvcodec is just the headers though
[22:56:35 CEST] <BtbN> That's all there is to it.
[22:57:01 CEST] <waterworks> I know
[22:58:24 CEST] <BtbN> Yeah, just confirmed it again, works fine for me and it detected with no configure commandline except toolchain=msvc
[23:00:23 CEST] <waterworks> Pretty pathetic you even need to install a separate thing to even build but whatever.
[23:07:25 CEST] <waterworks> Can't get it to work at all through msys2
[23:14:07 CEST] <wfbarksd_> is it fairly comon that the pts + duration of the last packet in a stream is less than the duration of the stream as reported on the AVStream from the demuxing context?
[23:27:07 CEST] <BtbN> the timestamp can be anything, really. It does not indicate the stream length
[23:27:25 CEST] <BtbN> they do not necesarily start at 0, or are monotonic
[23:48:38 CEST] <wfbarksd_> So i guess the only way to get the "true" duration of the stream is to seek to the last packet and check?
[23:48:45 CEST] <wfbarksd_> Btbn:
[23:49:16 CEST] <BtbN> pretty much, yeah.
[23:49:30 CEST] <BtbN> Or trust the container, if it specifies a duration
[00:00:00 CEST] --- Thu Jun  7 2018


More information about the Ffmpeg-devel-irc mailing list