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

burek burek021 at gmail.com
Sat Mar 17 03:05:01 EET 2018


[00:05:32 CET] <PPrX> Howdy - I'm encoding WebM + VP8 in "real time" over a websocket, source of frame data is from a processing pipeline which will split out frames at some unknown rate (generally around 80 fps, but could be anywhere from 1 - 1000 (!) fps). I'm wondering how I should calculate the frame PTS based off wall clock time, and what I should set the timebase to?
[00:06:59 CET] <DHE> whatever you want. timebase of 1/1000 means that pts is basically "timestamp in milliseconds"
[00:08:18 CET] <PPrX> DHE: that makes sense, then I can just figure out the delta time between write requests then increment the pts. How should I think about framerate on the codec context - or is that independent the encoder will just use whatever data it deems best?
[00:09:40 CET] <DHE> I think you can pass the same timestamps through...
[00:10:25 CET] <PPrX> Woudn't the first PTS be massively offset, or wouldnt that matter?
[00:10:51 CET] <DHE> ?
[00:12:12 CET] <PPrX> When you say pass the same timestamps through; you mean pMyIncomingFrame->ptr = time_now_in_millseconds() ?
[00:13:01 CET] <DHE> well, normalized to time_now_in_milliseconds() - time_at_start_of_encoding;
[00:13:27 CET] <DHE> if there's audio this makes things better
[00:15:59 CET] <PPrX> cool
[00:17:33 CET] <PPrX> no audio in this pipeline, just video
[00:20:29 CET] <JeremyK> I have ubuntu 16.0.4.4 with an i5 and and RX480 GPU. I have been playing around with ffmpeg for a few years. I am now trying to use hwaccel with the GPU. I have installed the newest amdgpu-pro drivers 17.50. and clinfo show that opencl is working. ffmpeg -hwaccel opencl -i file...... seems to work. but there is no speed increase. what should I look for?
[00:21:31 CET] <DHE> opencl only affects a few filters right now. x264 has opencl offload but it's situational for whether it's worth the effort of moving frames in/out of the GPU
[00:21:58 CET] <DHE> even so it's partial offload only. I've seen +20 to -20% performance changes
[00:43:19 CET] <kevinnn> JEEB: I managed to export about 50 frames to a file from x265 if that makes the debugging process any easier
[00:43:34 CET] <kevinnn> Do you think you could take a look if I uploaded it?
[00:44:14 CET] <kepstin> JeremyK: the rx480 does have a hardware video encoder, but the quality of the radeon hardware encoders is kinda meh. Only really worth using if for some reason you can't use the cpu encoder.
[00:51:27 CET] <Jodon> I am doing almost the same thing as PPrX (very similar).  Same issue I believe:  I have a variable frame rate source, sending over RTP (using rtp_mpegts) and in my case consuming with VLC.  I've seen error logs in ffmpeg when you have non-monotonous PTS (i.e. setting to millisecond rather than 1,2,3,4).  Is setting the PTS in such a manner really safe to do?
[01:12:43 CET] <kepstin> Jodon: it's only a problem if you might have multiple frames get the same timestamp
[01:13:28 CET] <kepstin> non-monotonous pts means that either you have multiple frames with the same pts, or your pts went backwards (e.g. you didn't re-order them properly)
[01:15:06 CET] <kepstin> note that a lot of ffmpeg stuff internally uses 'AV_TIME_BASE', which is microseconds. Use that if you're worried about getting multiple frames in the same millisecond.
[01:17:14 CET] <Jodon> Hmm, sounds good.  How does that work with players like VLC where it wants to buffer a certain amount of ms?  Or should I just try this all out and see if it works?
[02:08:51 CET] <kevinnn> Does anyone know why x265_encoder_encode might be taking 120+ms every time I call it?
[02:09:13 CET] <kevinnn> I think it has to do with the way I tuned x265 but I am not sure
[02:13:06 CET] <kepstin> kevinnn: err, that's not an ffmpeg function?
[02:13:45 CET] <kevinnn> kepstin: ya I know, but I figured maybe someone who know what it was might know here
[02:14:44 CET] <kepstin> well, all I can really tell you about the matter is that if you want video encoded quickly, you probably shouldn't be using hevc :/
[02:15:05 CET] <kevinnn> why is that!
[02:15:10 CET] <kevinnn> kepstin
[02:15:24 CET] <kevinnn> Don't a lot of people use hevc to live stream?
[02:15:43 CET] <kepstin> because compared to, say, x264, all the hevc encoders I've seen are much slower to achieve similar levels of quality
[02:15:50 CET] <kepstin> nah, almost everyone uses h264
[02:16:39 CET] <kevinnn> really...
[02:16:52 CET] <kevinnn> well looks like I've wasted my time
[02:16:59 CET] <kepstin> doesn't help that the patent licensing for hevc is a mess, h264 is a lot easier to deal with there.
[02:36:47 CET] <furq> does anyone use hevc for streaming
[02:37:30 CET] <klaxa> i would be surprised if not, but it's probably not many
[03:25:54 CET] <thebombzen> when trying to compile git master of ffmpeg, all of a sudden I'm getting this: ERROR: cuda requested, but not all dependencies are satisfied: ffnvcodec
[03:26:51 CET] <thebombzen> the issue is that it can't find #include <ffnvcodec/nvEncodeAPI.h>
[03:33:05 CET] <thebombzen> what changed that suddently ffmpeg can't find its own nvidia headers?
[06:31:21 CET] <saltlake> Anyone?
[06:31:38 CET] <saltlake> Which format to convert to upload the .wav file in youtube?
[07:17:07 CET] <xxzz> mp3?
[07:17:18 CET] <xxzz> ogg
[08:40:10 CET] <zamba> i have a problem grabbing from old video cassettes.. i'm trying to use s-video, but only getting a black and white image
[14:05:37 CET] <hellyeah> hey there
[14:06:09 CET] <hellyeah> i am just getting rtsp stream and publish on the web do you tthink this command is good enough or can be developoed?
[14:06:37 CET] <hellyeah> ffmpeg -v verbose -i rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mov myTestCam.m3u8
[19:37:38 CET] <clovisw> I'm new on transcoding, and wish to know your experience on transcoding, is FFmpeg fine and usefull than commercial tools or have something that we cant do with FFmpeg that commercial tools do?
[19:40:01 CET] <durandal_1707> clovisw: just use commerical tools
[19:50:07 CET] <clovisw> ffmpeg isnt good for transcoding then?
[19:51:12 CET] <durandal_1707> clovisw: it is very good for transcoding
[19:55:24 CET] <clovisw> ok, then why just use commercial tools is your answer as my intent is to have some glue based on your experiences, or you is the one that sell commercial tools ^^
[19:55:43 CET] <JEEB> clovisw: durandal is just being durandal
[19:56:44 CET] <clovisw> uh I see, the one that dont like to spread the word and kick dummies fast ;)
[19:59:29 CET] <clovisw> then except durandal opinion, anyone have experiences, note I know all the words of why matters you have support and such things, but take for example Linux, we have a free O.S. that do better than the paid and closed sources.
[20:00:35 CET] <durandal_1707> commercial tools have support channel, free tools like FFmpeg have consulting
[20:00:43 CET] <clovisw> the intent as we dont have a chance to compare ffmpeg tools with commercial ones, is to know if anyone is free to share their experiences
[20:01:50 CET] <durandal_1707> commercial ones usually have nice GUI and other nice shiny features
[20:02:42 CET] <clovisw> that dont matters, but for example, ffmpeg can transcoding fast than the XYZ commercial tools? or all today commercial tools embed ffmpeg inside?
[20:04:20 CET] <kepstin> clovisw: depends on the specific format? For many modern codecs (h264, vp9, etc.) ffmpeg uses the same encoder libraries as pretty much everyone else.
[20:05:01 CET] <durandal_1707> dunno, you need to be more specific, there are many commercial tools, and if you are interested only in transcoding - thats very limited view
[20:05:06 CET] <kepstin> (well, in the case of x264, it's probably better than many of the proprietary encoders)
[20:05:50 CET] <clovisw> its for VOD then codecs must work on mobile phones, but for now my focus is on transcoding part only.
[20:06:11 CET] <clovisw> durandal, the transcoding for example, AWS charge per minutes. and do only this, transcoding.
[20:06:40 CET] <kepstin> aws is probably just using ffmpeg, really.
[20:06:52 CET] <clovisw> in a project you can spent 200K in transcoding based on minutes charge for AWS.
[20:07:11 CET] <clovisw> but if you install your EC2 with ffmpeg inside you got very less price than that.
[20:07:28 CET] <kepstin> yeah, but then you have to build your own queue system and manage it
[20:07:43 CET] <kepstin> (that's what I do, because I do a lot of custom stuff)
[20:08:23 CET] <clovisw> me too, queue system, kubernetes, containers, and all such things to avoid cloud lockin
[20:10:10 CET] <clovisw> then as I have too low time for this research I like to gatter the info from community of ffmpeg
[20:10:48 CET] <clovisw> for example, any problem or codec that ffmpeg cant deal like the ones used in iPhone?
[20:10:49 CET] <kepstin> well, the answer is, do you want to pay some devs to build a system with ffmpeg, or pay some other company so their devs build a system (which'll probably use ffmpeg anyways)?
[20:11:33 CET] <clovisw> I want to learn ffmpeg to avoid to learn a commercial tool and discover that they embed ffmpeg inside.
[20:11:46 CET] <clovisw> I'm a developer too
[20:11:56 CET] <kepstin> clovisw: ffmpeg supports as input more formats and codecs than any other video tool on the planet.
[20:12:19 CET] <clovisw> just want to avoid follow a commercial path and discover that ffmpeg solve all things on transcoding.
[20:12:21 CET] <kepstin> (of course, a lot of them are really strange or obsucre)
[20:15:13 CET] <kepstin> well, just make sure you don't underestimate the ongoing maintenance effort of building a system in-house when deciding.
[20:15:38 CET] <kepstin> it may or may not make sense for you, but nobody here can really say anything about that...
[20:15:57 CET] <kepstin> but if you're gonna build a transcoder tool, ffmpeg is probably the place to start for it.
[20:16:58 CET] <clovisw> yes, I have the know to make that custom use of ffmpeg fine, but just try to avoid going to this path and discover that in this area we have some patent tech that for VOD is the only way to follow and must use a commercial tool.
[20:17:54 CET] <kepstin> we can't answer that without knowing specifics of your use case?
[20:19:24 CET] <clovisw> I must create a VOD system, that will be consumed by end users on mobile devices (Android or iOS)
[20:20:14 CET] <clovisw> the transcode is to create files for many resolutions and bitrates
[20:20:32 CET] <clovisw> from a 4K source file
[20:21:51 CET] <kepstin> shouldn't have any issue doing that with ffmpeg, just need to enumerate the devices you want to support and decide on which codecs/profiles and containers to use.
[20:24:23 CET] <kepstin> honestly, just h264 high profile and aac-lc in HLS will probably get you almost every device from the past 3-4 years at least.
[20:25:21 CET] <clovisw> very nice then, ffmpeg will be my new perk  from now
[20:28:26 CET] <clovisw> thanks for all information.
[20:30:01 CET] <clovisw> and sorry to botter you durandal_1707 I promise to stay quiet from now, and help others when finish to learn ffmpeg ;)
[20:31:06 CET] <furq> don't forget level 4.1
[20:31:15 CET] <kepstin> just don't forget to contribute back to ffmpeg if you end up having to change something ;)
[20:31:28 CET] <durandal_1707> clovisw: where is your donations?
[20:31:53 CET] Action: kepstin rewrote the fps filter because he was seeing oom errors on his transcoder boxes when they were being fed particularly nasty webcam streams.
[20:32:11 CET] <clovisw> yes, I will do
[20:32:47 CET] <durandal_1707> kepstin: yes!, great contribution
[20:35:14 CET] <clovisw> durandal take easy, if I can use ffmpeg on this project, I can promise good donations in near time, this year, as I can tell CEO that we dont need to pay for minutes of transcoding and I wish to revert this to opensource projects
[20:35:54 CET] <clovisw> Im just poor developer too, and like to spreed the word of open source power
[20:36:27 CET] <clovisw> here is an example, in what commercial tool, we can have 435 people in a room sharing knowledge?
[20:36:46 CET] <kepstin> well, you still gotta pay for minutes of transcoding, but hopefully you can give jeff bezos a smaller cut ;)
[20:36:52 CET] <clovisw> maybe some bots LOL
[20:37:23 CET] <clovisw> Bezos now is focused to pass Elon Musk in Mars road
[23:32:23 CET] <philipp64> I'm familiar with avio_alloc_context() and the read_packet parameter... which aspirates data as it needs it.  is there a way to push data as it becomes available into AVIO instead? i.e. instead of looping, be event-driven?
[23:43:49 CET] <hackeron> Hi there, I'm looking at https://trac.ffmpeg.org/wiki/Encode/AAC but I'm struggling to make sense of it - if I want to have variable bitrate encoding, that's close to CD quality - will something like -c:a libfdk_aac -profile:a aac_he_v2 -q:a 2 a good choice?
[23:54:29 CET] <furq> hackeron: fdk uses -vbr, not -q
[23:54:39 CET] <furq> you probably want -vbr 5
[23:55:19 CET] <BtbN> aac_he is for ultra low bitrate stuff
[23:55:20 CET] <furq> you also definitely don't want he-aac at bitrates above 128k
[23:55:31 CET] <furq> or above 96k really
[23:59:20 CET] <hackeron> ah, ok, so maybe -c:a libfdk_aac -vbr 4 then? (5 seems a bit overkill from what I can tell?)
[00:00:00 CET] --- Sat Mar 17 2018


More information about the Ffmpeg-devel-irc mailing list