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

burek burek021 at gmail.com
Sat Jul 29 03:05:01 EEST 2017


[03:15:44 CEST] <Tatsh> so
[03:15:58 CEST] <Tatsh> if you have a source for h264 that has constqp, vbr, or cbr  which should you use?
[03:16:03 CEST] <Tatsh> what's best?
[03:17:05 CEST] <c_14> the one that looks best
[03:24:44 CEST] <furq> i mean probably not the cbr one but it depends what the bitrate is
[03:24:52 CEST] <furq> so basically what c_14 said
[03:25:01 CEST] <furq> he is truly wise
[04:34:38 CEST] <ElementalBlack> is there some sort of external library required for png output support?
[04:34:58 CEST] <furq> no
[04:35:38 CEST] <ElementalBlack> not sure why I'm getting "Automatic encoder selection failed for output stream #0:0. Default encoder for format image2 (codec png) is probably disabled. Please choose an encoder manually." then
[04:35:47 CEST] <ElementalBlack> is it version 3 gpl?
[04:36:09 CEST] <furq> all the internal decoders and encoders are lgpl
[04:36:18 CEST] <furq> so unless you specifically disabled it, it should be there
[04:36:57 CEST] <ElementalBlack> I'm not disabling it...
[04:37:13 CEST] <furq> pastebin the output of ffmpeg -version
[05:18:28 CEST] <kepstin> i think the png encoder requires zlib? so if you build your own ffmpeg and don't have the zlib dev stuff available, it could be missing
[05:52:48 CEST] <hanna> Is it normal that seeking on HEVC files produces a bunch of corrupt garbage (mostly grey) until I let it play for about a second?
[05:53:05 CEST] <hanna> It also seems like there's a regression, in the past, when I framestepped backwards it would always give me a correct frame again
[05:53:16 CEST] <hanna> but now I also get garbage even when framestepping backwards from a garbage frame
[05:54:00 CEST] <hanna> Actually not all HEVC files
[05:55:02 CEST] <hanna> Hmm I think it only happens for MPEGTS
[05:55:59 CEST] <hanna> Yeah works fine after transcoding to matroska
[05:56:01 CEST] <hanna> I'll just do that from now on
[05:58:20 CEST] <kepstin> what player?
[05:58:43 CEST] <kepstin> it should work on any format where recovery frames are correctly marked, and it'll usually work better in formats with seek indexes (like matroska)
[05:59:33 CEST] <hanna> kepstin: mpv
[09:16:48 CEST] <lindylex> why is this not using my font?  ffmpeg -i zoom1920.mp4 -vf "drawtext='fontfile=.\fonts\SoulMission.ttf':text=#MOTIONDESIGNSTUDIO FAILED:fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4  It defaults to [Parsed_drawtext_0 @ 0x5599f67e5140] Using "/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf"
[09:43:16 CEST] <luc4> Hello! I have a weird video file here that ffprobe reports being of size 854x480 [SAR 1280:1281 DAR 16:9]. Now I understand the resolution is 854x480, but any idea why SAR is 1280:1281? Why should someone declare the size of the frame with a size different from the resolution of the video stream?
[13:41:31 CEST] <nahsi> how do I change DAR (display aspect ratio) of a video stream in mkv container? The original dimension is 1440x1080 but aspect ratio is 16:9. Tried mkvtoolnix but it creates 'Original display aspect ratio' and when I upload video to youtube it's 16:9 not 4:3. How can I completely erase any info on aspect ratio from a container? Tried also extract just a plain avc stream and repack it - didn't work
[13:49:15 CEST] <mickie> Hi All, I can't get mpv to show subtitles ... I used ffmpeg with '-codec:s dvb_subtitle -metadata:s:s:0 language=eng' providing the video and .srt files as inputs. Am I missing some option from ffmpeg?
[13:49:55 CEST] <nahsi> >dvb_subtitle that is not correct
[13:50:02 CEST] <nahsi> use mkvmerge
[13:50:33 CEST] <mickie> I am trying to convert the stream to .rec which is a Topfield mpeg2 format.
[13:51:43 CEST] <mickie> All .rec files have the subtitles defined as a 'Subtitle: dvb_subtitle' format
[13:52:04 CEST] <mickie> I'll look into mkvmerge to see if this will do
[13:52:09 CEST] <mickie> Thanks nahsi
[13:52:15 CEST] <nahsi> No-no mkvmerge will only merge
[13:52:23 CEST] <mickie> Ah!
[13:52:29 CEST] <nahsi> You need to convert right? I'm googling right now
[13:52:47 CEST] <mickie> Yes I need to convert from srt to dvd_subtitle format
[13:53:07 CEST] <mickie> This is why I used the syntax I posted just now.
[13:54:06 CEST] <mickie> ffprobe shows the subtitle stream as it should be, similar to other .rec files, but mpv won't display it. :(
[13:54:54 CEST] <nahsi> Is you mpv is built with dvb support?
[13:55:00 CEST] <rev0n> I was wondering if any of you know how I can "repair" chunks of webm video generated by getUserMedia() with MediaStreamRecorder API. FFMPEG has problem reading the chunks, and when I tried mkvalidator (for validating webm files) I got such errors: https://pastebin.com/tiG9w3qT
[13:55:30 CEST] <mickie> Hmm ... too obvious - why didn't I check before?
[13:55:42 CEST] <mickie> Ha! No it is not built with dvd support!
[13:56:27 CEST] <mickie> However, playing .rec files with this same mpv shows their subtitles fine.  Only my converted file won't show any.
[13:58:47 CEST] <nahsi> try -c:s dvbsub ?
[13:58:48 CEST] <mickie> I'll convert the .ts file to .rec with the ProjectX java application I use for this purpose and see what gives.
[13:59:00 CEST] <mickie> Thanks nahsi, will do.
[13:59:04 CEST] <nahsi> np
[14:01:29 CEST] <mickie> Same thing happens.  mpv or vlc recognise the subtitles stream and allow me to enable it, but they won't display it.  :-/
[14:04:12 CEST] <mickie> Hmm ... vlc shows some vdpau_display vout errors. Not sure if it is a red herring
[14:04:44 CEST] <mickie> something about 'VdpVideoSurface of a different size'
[14:05:11 CEST] <mickie> Thanks again, need to run.
[15:37:28 CEST] <zetax> has ffmpeg some issue with opus audio conversation? result sounds horrible, vorbis is fine.
[15:37:46 CEST] <DHE> did you specify a good quality or bitrate setting?
[15:38:05 CEST] <zetax> just standard quality 5 on vbr
[16:23:34 CEST] <kepstin> opus doesn't have a 'quality' setting
[16:26:51 CEST] <kepstin> that said, the default setting for opus is 96kbps vbr, which should sound quite good
[16:27:39 CEST] <kepstin> (obviously you want to make sure you have the latest libopus too, since there's quality improvements in each version)
[16:31:55 CEST] <iive> ffmpeg have internal opus encoder, too.
[16:39:05 CEST] <kepstin> yeah, but using libopus is recommended for the time being. The internal encoder's still marked experimental, even
[16:40:08 CEST] <zack_s_> how can I convert a 3D video to 2D?
[16:40:18 CEST] <zack_s_> its a top-bottom videos
[16:40:20 CEST] <furq> close one eye
[16:40:31 CEST] <kepstin> zack_s_: crop it
[16:40:53 CEST] <kepstin> I mean, the internal opus encoder works, and it is *faster* than libopus, and at sufficient bitrates it sounds fine.
[16:41:04 CEST] <furq> !filter stereo3d @zack_s_
[16:41:04 CEST] <nfobot> zack_s_: http://ffmpeg.org/ffmpeg-filters.html#stereo3d
[16:41:07 CEST] <c_14> zack_s_: use the stereo3d filter with ml or mr as out format
[16:41:12 CEST] <furq> ^
[16:41:36 CEST] <furq> although i don't see what benefit that has over cropping
[16:42:19 CEST] <c_14> eeeeeh
[16:42:22 CEST] <c_14> more complicated = better ?
[16:42:27 CEST] <furq> this is true
[16:44:32 CEST] <furq> zack_s_: also if this is a vr video and you want to map it to a 2d plane, then i don't think ffmpeg does that
[16:44:52 CEST] <zack_s_> its a 3d video
[16:44:55 CEST] <zack_s_> no vr
[16:44:58 CEST] <furq> ok good
[16:48:17 CEST] <zack_s_> ffmpeg -i input.mkv -vf stereo3d=abl output.mkv
[16:48:24 CEST] <zack_s_> this seems to work
[16:48:48 CEST] <zack_s_> but why does it make it the video to 2d?
[16:48:54 CEST] <zack_s_> where is the command for that?
[16:49:09 CEST] <zack_s_> and I am not satisified with the encoding profile used, different then input
[16:49:24 CEST] <zack_s_> and the bitrate and so on
[16:50:41 CEST] <zack_s_> furq: ?
[16:51:40 CEST] <furq> er
[16:51:48 CEST] <furq> that command will convert to arcd
[16:51:57 CEST] <furq> also you didn't provide any encoder settings so it's using the defaults for mkv
[16:52:33 CEST] <zack_s_> I have an mp4 video
[16:52:35 CEST] <zack_s_> as input
[16:52:51 CEST] <zack_s_> how to I specifiy that the input encoding profile is used as output encoding profile?
[16:52:54 CEST] <zack_s_> furq: ?
[16:59:05 CEST] <kepstin> by profile you mean https://en.wikipedia.org/wiki/H.264/MPEG-4_AVC#Profiles - like, restrictions so it'll play on particular devices?
[16:59:33 CEST] <kepstin> just set it yourself, if you want to apply restrictions on the output, there's nothing to 'copy' it.
[17:00:45 CEST] <kepstin> but you obviously also need to set bitrate and quality settings as appropriate, "copying" them doesn't make sense.
[17:05:16 CEST] <zack_s_> kepstin: I want all input settings, also be the output settings
[17:05:24 CEST] <zack_s_> the encoding profile
[17:05:37 CEST] <zack_s_> such as level, bitrate, GOP
[17:05:38 CEST] <kepstin> but that doesn't make sense, you're removing half the video and maybe even using a different encoder
[17:05:39 CEST] <zack_s_> and so one
[17:06:00 CEST] <zack_s_> I convert a 3D mp4 video to 2D mp4 video
[17:06:52 CEST] <kepstin> yes, so now you need to do a new encoder of this now significantly modified video - so you have to pick new settings that are appropriate for how you want to use the result.
[17:07:52 CEST] <zack_s_> okay, so it doesnt work with ffmpeg
[17:08:10 CEST] <zack_s_> anyway, setting everything again manually, I start with the profile: ffmpeg -i input.mkv -vf stereo3d=abl -profile:v high -level 4.1 output.mkv
[17:08:13 CEST] <zack_s_> doesnt work
[17:08:23 CEST] <zack_s_> "Error initializing output stream 0:0 -- Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height"
[17:08:48 CEST] <kepstin> there should be an earlier line in the output saying exactly what is wrong
[17:11:43 CEST] <kepstin> but you're also not setting any bitrate or quality settings in that command line, so you're going to get the defaults, which are kind of ... mediumish.
[17:12:48 CEST] <zack_s_> fflogger: https://paste.ee/p/i0cPg#Wr7miFkisqF9qMEh8JCwXXUf9TotKs47
[17:14:53 CEST] <kepstin> huh, weird, the stereo3d filter must have converted that do a different pixel format
[17:15:13 CEST] <kepstin> really, try just using crop instead, if it's above/below.
[17:15:57 CEST] <kepstin> alternatively, add "-pix_fmt yuv420p" output option to make it reconvert back to a pixel format allowed in the h264 profile you picked (this will be slower).
[17:17:20 CEST] <zack_s_> kepstin: do you have a command, how to use crop?
[17:19:13 CEST] <kepstin> if your input is above/below, and you want the output to be 1080p, this should work: "-vf crop=1920:540,scale=1920:1080"
[17:20:43 CEST] <zack_s_> kepstin: na doesnt work
[17:20:51 CEST] <zack_s_> the output is one eye
[17:20:55 CEST] <zack_s_> but it is cut in half
[17:21:27 CEST] <zack_s_> its displaced
[17:22:08 CEST] <kepstin> lets see, you say 'stereo3d=abl' works?
[17:22:13 CEST] Action: kepstin looks up what that does
[17:22:52 CEST] <zack_s_> yes
[17:22:55 CEST] <zack_s_> this worked
[17:23:44 CEST] <kepstin> ... I don't think that does what you think it does. "setereo3d=abl" turns above/below content into anaglyph red/cyan
[17:24:36 CEST] Action: kepstin is kind of surprised that the crop didn't work, but he hasn't seen the actual video you have, so...
[17:26:09 CEST] <kepstin> the command output says the input is 1920x1080 with sar 1:2, so that should be correct :/
[17:27:32 CEST] <kepstin> that said, you can also try doing -vf stereo3d=abl:ml
[17:27:47 CEST] <kepstin> which might avoid the color space issue, since it won't do the anaglyph conversion
[17:31:39 CEST] <zack_s_> kepstin: now I can set the level 4.1
[17:32:59 CEST] <zack_s_> kepstin: how can I set the bitrate?
[17:33:09 CEST] <fred1807> can ffmpeg interpret 4m02s ?
[17:33:28 CEST] <fred1807> or just 00:04:02
[17:33:29 CEST] <kepstin> fred1807: no, that's not a supported time format for any of the options
[17:34:11 CEST] <kepstin> zack_s_: do you actually need a specific bitrate? with x264 encoder, it's usually better to set a -crf value instead to get a single-pass constant quality encode.
[17:34:40 CEST] <kepstin> (the default is -crf 23, i think; use a lower value to get higher quality)
[17:35:02 CEST] <kepstin> most people consider around -crf 18 and below to be difficult to distinguish from the input
[17:35:59 CEST] <zack_s_> kepstin: why is crf better then settings constant bitrate?
[17:36:23 CEST] <kepstin> zack_s_: because with constant bitrate, the quality changes over time depending on how 'hard' each frame is to encode
[17:37:15 CEST] <kepstin> (the workaround to this is to do a 2-pass encode instead - but with crf you only need 1 pass)
[17:38:17 CEST] <zack_s_> kepstin: ahh crf is a variable bitrate
[17:40:02 CEST] <kepstin> also note that x264 defaults to using "-preset medium" - you can get smaller files/better quality by using a slower preset (e.g. "-preset veryslow") instead, but the encode will take longer.
[17:40:24 CEST] <kepstin> or, the opposite, use a faster preset if you need it done sooner and don't mind bigger files :)
[17:40:28 CEST] <zack_s_> kepstin: can ffmpeg use also hardware encoding?
[17:40:48 CEST] <zack_s_> with intel hardware for example?
[17:41:03 CEST] <kepstin> yes, but you should only do that if your cpu is way too slow or if you're e.g. screen capturing a game or something
[17:41:16 CEST] <zack_s_> how can I do it?
[17:41:17 CEST] <kepstin> the hardware encoders generally have lower quality than software encoders
[17:42:59 CEST] <kepstin> what os?
[17:43:25 CEST] Action: kepstin notes that getting the intel hw encoder working is sometimes a bit of a pain on linux, and he has no idea how to do it on windows.
[17:43:40 CEST] <zack_s_> kepstin: windows
[17:43:48 CEST] <kepstin> not worth the trouble to get lower quality encodes, in general :/
[17:47:37 CEST] <zack_s_> kepstin: adding -h encoder=h264_qsv
[17:47:41 CEST] <zack_s_> seems not to work
[17:49:02 CEST] <zack_s_> ok I am out
[17:49:06 CEST] <zack_s_> kepstin: bye
[17:49:13 CEST] <zack_s_> thanks for the help
[17:49:44 CEST] <hexhaxtron> Can I convert 3D MKV to MP4?
[17:50:00 CEST] <fred1807> I am having a strange issue with a bash script and ffmpeg.  I have this video that I can command      ffmpeg -i input.mp4 -c copy -ss 00:00:24 -t 00:04:34 output.mp4 without any problem.       But when I run this command inside a bash script, I am getting error: Invalid duration specification for t: 00:04:34
[17:50:34 CEST] <fred1807> the duration is not invalid, because I can command this on this same video
[17:50:57 CEST] <fred1807> this error only happens when inside a bash script  (the duration is passed as a argument, but it is the same duration)
[18:04:23 CEST] <kepstin> fred1807: it's probably a syntax or escaping issue in your script then :/ not really something we can help with unless we can see it.
[18:06:12 CEST] <tdr>   
[18:12:55 CEST] <PaoloP> Hello. It seems that the mpegts muxer wants TWO adts-aac frames (av_write_frame()), before producing output. Do you know why?
[18:13:16 CEST] <PaoloP> and if it's a way to reduce that to one frame...
[18:17:44 CEST] <PaoloP> and if is there a way to reduce that to one frame...
[18:42:25 CEST] <rev0n> Anyone had issues piping data to ffmpeg?
[18:45:41 CEST] <Blubberbub_> what kind of issues?
[18:48:14 CEST] <rev0n> I get webm chunks from user with getUserMedia() (js), and send them to Python tornado server. When I try to pipe the data to ffmpeg I get bunch of errors, ffmpeg looks like stuck. When I write binary data from the socket to a file with file.write() I can successfully convert the video to any format. Which does not work while piping. It's exact same data!
[19:02:44 CEST] <Blubberbub_> are you sure there is no additional data piped to ffmpeg?
[19:03:05 CEST] <Blubberbub_> so compare to what happens if you pipe to a file isntead of using file.write
[19:19:18 CEST] <ioan> hi. Is there a way to save a rtsp stream localy AND break it in ... multiple files (by time or by size)?
[19:30:05 CEST] <DHE> there is a `tee` muxer that could split it into multiple outputs
[19:30:50 CEST] <ioan> I found the answer on stackoverflow, I'm trying it right now
[19:32:10 CEST] <ioan> actually on superuser and it works: ffmpeg -i rtmp://source.com/live/stream -c copy -flags +global_header -f segment -segment_time 60 -segment_format_options movflags=+faststart -reset_timestamps 1 test%d.mp4
[19:40:23 CEST] <DHE> oh, I thought you wanted a split version and a solid version at the same time...
[19:41:28 CEST] <rev0n> Blubberbub_: it looks like there's no additional data. Not sure why there would be
[20:01:45 CEST] <mickie> Hi All, I've been trying to convert an mp4 containing h264 video and aac audio into a ts container with mpeg2 video and mp2 audio.  I also have subtitles in a .srt (subrip) file.  I am not sure how I can embed the .srt subtitles into a dvbsub format.
[20:02:10 CEST] <mickie> Do I need to use overlay?
[20:02:45 CEST] <kepstin> I thought dvbsub was a teletext format, not image-based.
[20:02:49 CEST] <Blubberbub_> overlay sounds like embedding the subtitles directly into the video stream, which si not what you want?
[20:03:10 CEST] <mickie> Right, I want a separate stream with the subtitles in it.
[20:03:17 CEST] <kepstin> It should in theory be as simple as setting -c:s dvbsub but I dunno if ffmpeg actually supports that.
[20:03:44 CEST] <kepstin> er, wait, no, it is an image based format
[20:03:46 CEST] <kepstin> never mind
[20:03:57 CEST] <mickie> That's what I've tried ... but it didn't work when I tried to convert the .ts file to a .rec file using ProjectX
[20:04:28 CEST] <mickie> ProjectX ignored the stream which had the dvbsub in it.
[20:04:49 CEST] <mickie> ALso, mpv/vlc do not show subtitles from the dvbsub stream
[20:05:04 CEST] <lindylex> why is this not using my font?  ffmpeg -i zoom1920.mp4 -vf "drawtext='fontfile=.\fonts\SoulMission.ttf':text=#MOTIONDESIGNSTUDIO FAILED:fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4  It defaults to this and ouputs this error >>>  [Parsed_drawtext_0 @ 0x5599f67e5140] Using "/usr/share/fonts/truetype/dejavu/DejaVuSans.tt
[20:05:04 CEST] <lindylex> f"
[20:05:39 CEST] <kepstin> lindylex: what os are you using?
[20:05:44 CEST] <lindylex> Linux
[20:05:56 CEST] <kepstin> so, change the \ to a /
[20:06:22 CEST] <kepstin> on linux, \ is either a special escape character or normal character, it's not a path separator...
[20:07:47 CEST] <lindylex> kepstin: sorry I knew this Imust have been experimenting,  I still get the same error.  When I use this   >>>  ffmpeg -i zoom1920.mp4 -vf "drawtext='fontfile=./fonts/SoulMission.ttf':text=#MOTIONDESIGNSTUDIO FAILED:fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4
[20:08:00 CEST] <lindylex> Or this ffmpeg -i zoom1920.mp4 -vf "drawtext=fontfile=/usr/share/fonts/truetype/SoulMission.ttf:text='#MOTIONDESIGNSTUDIO FAILED':fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4
[20:12:59 CEST] <kepstin> hmm, not sure why that wouldn't be working, unless for some reason fontconfig can't understand the font file format or something
[20:13:14 CEST] <kepstin> have you confirmed the font works in other applications?
[20:13:34 CEST] <kepstin> also consider installing it then loading it by name with the "font=" parameter, which will use fontconfig
[20:16:45 CEST] <mickie> OK, I've tried this: "ffmpeg -i My_video.ts -i My_video.srt -target pal-dvd -aspect 16:9 -codec:a mp2 -ar 48000 -b:a 256k -codec:s dvbsub -metadata:s:s:0 language=eng test.ts" but the subtitles in mpv are not recognised.  ffprobe shows: "Stream #0:0[0x1bf]: Data: dvd_nav_packet, Stream #0:1[0x1e0]: Video: mpeg2video (Main)[snip...], Stream #0:2[0x1c0]: Audio: mp2[snip...], Stream #0:3[0x20]: Subtitle:
[20:16:51 CEST] <mickie> dvd_subtitle".
[20:17:16 CEST] <mickie> Then mpv/vlc show Subtitle:no
[20:17:19 CEST] <mickie> :(
[20:19:58 CEST] <kepstin> lindylex: I downloaded the font you're using, installed it, and it worked perfectly in ffmpeg for me with the option "font=SoulMission"
[20:20:11 CEST] <kepstin> if you've put it into /usr/share/fonts, that should be sufficient.
[20:32:58 CEST] <lindylex> kepstin:  I can use the font in Libre Office.
[20:33:38 CEST] <lindylex> Are thinking something like this?
[20:33:39 CEST] <lindylex>   ffmpeg -i zoom1920.mp4 -vf "drawtext='fontfile=SoulMission':text=#MOTIONDESIGNSTUDIO FAILED:fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4
[20:35:07 CEST] <lindylex> kepstin:  This worked ffmpeg -i zoom1920.mp4 -vf "drawtext='font=SoulMission':text=#MOTIONDESIGNSTUDIO FAILED:fontcolor=0xFFFFFFFF:fontsize=99:x=20:y=10: #shadowcolor=0x000000EE:shadowx=2:shadowy=2" -c:v libx264 -preset slow -crf 18 -c:a copy -pix_fmt yuv420p -y zover.mp4
[20:35:12 CEST] <lindylex> Thanks
[20:44:56 CEST] <Blubberbub_> is someone familiar with the "silenceremove" filter? Because to me it looks like it does not do what it documentation says it does...
[21:21:10 CEST] <momomo> what is the best way to test a stream? if it works or not? ffmpeg or some other tool?
[21:22:37 CEST] <JEEB> ffprobe is usually pretty good for basic "is there anything in the input?" kind of testing
[21:23:25 CEST] <momomo> JEEB: Ok, I see the output format differs from the ffmpeg output format when you initially connect to a stream
[21:23:47 CEST] <JEEB> you can specify an expected output format for parsing with of
[21:23:48 CEST] <momomo> That would potentially force us to parse the output twice
[21:23:50 CEST] <JEEB> -of json for json
[21:23:57 CEST] <momomo> JEEB: nice let me try
[21:25:33 CEST] <momomo> cool!
[21:27:41 CEST] <momomo> When connecting with ffmpeg, you've get an initial output. Is there a way to get that in a particularly parsable format?
[21:28:29 CEST] <momomo> Here is the output for ffprobe in json: https://hastebin.com/zojecoduru.json
[21:28:40 CEST] <momomo> Here is the output using ffmpeg connection: https://hastebin.com/uraxukisol.md
[21:28:52 CEST] <momomo> For ffmpeg output, ignore the initial nubmers up to colon :
[21:29:13 CEST] <JEEB> what "initial output"?
[21:29:43 CEST] <momomo> JEEB: when yoou connect .. see the second link: https://hastebin.com/uraxukisol.md
[21:29:50 CEST] <momomo> It contains data about the stream
[21:29:54 CEST] <JEEB> no I mean which part
[21:30:02 CEST] <JEEB> because you can ask for various things from ffprobe
[21:30:22 CEST] <JEEB> and a lot of the stuff about the /input/ is already there
[21:30:28 CEST] <momomo> Here is what I am running: ffprobe -v error -show_format -of json -show_streams paht/to/url
[21:30:57 CEST] <JEEB> no I mean what do you /want/ from that thing rather than what you have now
[21:32:43 CEST] <momomo> Whatever good I can get. Ideally, later on, since some streams would contain multiple language files, i would like to download them separately .. i think you the data before you make the initial connection
[21:32:50 CEST] <JEEB> no, I mean what are you missing?
[21:32:51 CEST] <momomo> as of now, I just do -map 0:a:0 -map 0:v:0
[21:32:58 CEST] <JEEB> because you clearly noted that something's missing, no?
[21:33:02 CEST] <JEEB> by linking the ffmpeg output
[21:33:57 CEST] <PaoloP> Hello. It seems that the mpegts muxer wants TWO adts-aac frames (av_write_frame()), before producing output. Do you know why and/or if is there a way to avoid this buffering?
[21:33:58 CEST] <momomo> JEEB: I am just saying they have different outputs. I can't afford to run ffprobe prior to ffmpeg everytime since that will slow things down, so rather I would like to be able to update the once a day run ffprobe generated data as I connect to ffmpeg
[21:34:19 CEST] <JEEB> momomo: sounds like you rather want to write a custom app using the APIs then
[21:34:28 CEST] <JEEB> if you need some specific data etc
[21:34:31 CEST] <momomo> So I'd like to see a coherent consistent looking output
[21:34:44 CEST] <momomo> Well, the output fromm ffprobe is good
[21:34:45 CEST] <JEEB> ffmpeg.c command line output is not meant for parsing. QED
[21:35:26 CEST] <JEEB> so yea, sounds like sooner than later you will want a custom API client that provides you exactly what you want
[21:35:32 CEST] <momomo> JEEB: is there a way to run ffbropbe at the same time to get the output without incurring potential additional connection costs ?
[21:35:41 CEST] <momomo> "custom api client" ?
[21:35:57 CEST] <JEEB> something that utilizes the FFmpeg API libraries (libav*)
[21:36:12 CEST] <JEEB> that way you can get exactly what you need without opening additional connections or anything else
[21:36:25 CEST] <momomo> ooh , damn .. is that complex to pull off ?
[21:36:28 CEST] <JEEB> no
[21:36:44 CEST] <JEEB> docs/examples has examples and then you just start setting your own logic
[21:37:02 CEST] <JEEB> I find it generally makes more sense to make a proper API client for your use case then hacking around
[21:37:15 CEST] <momomo> do you know if there similar tools/plugins available  already? althouhg i like the idea of taking control
[21:37:17 CEST] <JEEB> I do also agree that ffmpeg.c lets you get scary far
[21:38:10 CEST] <JEEB> momomo: a whole massload of apps or libraries use libav* libraries in the background but I'm not sure if anything is doing exactly what you need
[21:38:59 CEST] <momomo> any direct link I can start looking, ffmpeg.c is ?
[21:39:48 CEST] <JEEB> ffmpeg.c is the command line application (which is also an API client)
[21:40:09 CEST] <JEEB> docs/examples under the FFmpeg git repository is where the various examples reside
[21:46:21 CEST] <momomo> JEEB: thanks, i look into that. that code looks like a nightmare for someone not familiar with the base libraries :(
[21:46:45 CEST] <JEEB> momomo: ffmpeg.c is a nightmare, yes
[21:47:03 CEST] <JEEB> it's a pile of hacks on top of hacks and an immense amount of variable functionality
[21:47:15 CEST] <JEEB> what you should instead do is look at the examples
[21:47:24 CEST] <JEEB> since what you need is a thing that does one thing and one thing well
[21:47:40 CEST] <Blubberbub_> i would say: one problem with trying to understand ffmpeg.c is, that one has to first know that a lot of functionality is actually in different files :D
[21:47:47 CEST] <JEEB> that too
[21:47:53 CEST] <JEEB> demux_decode being the first thing and transcoding example being another
[21:48:01 CEST] <JEEB> I'd rather look at those and starting to play with the libraries
[21:48:20 CEST] <JEEB> first you learn how to open your input and then you learn to read packets
[21:48:27 CEST] <JEEB> and then you start decoding those packets into frames
[21:48:29 CEST] <JEEB> etc etc
[23:28:12 CEST] <momomo> is there a "quickest" way to execute ffprobe? like if asking for minimal amount of data, would result in faster response?
[23:33:05 CEST] <JEEB> probe- and analyzeduration are a thing
[23:55:25 CEST] <momomo> Thanks, I'll look into that
[00:00:00 CEST] --- Sat Jul 29 2017


More information about the Ffmpeg-devel-irc mailing list