From 6651b6f5f6ddf530ee463b454608f25c75d24865 Mon Sep 17 00:00:00 2001 From: Josh Allmann Date: Wed, 31 Jul 2024 07:30:47 +0000 Subject: [PATCH] ffmpeg: Estimate duration for some audio formats in GetCodecInfoBytes --- data/audio.mp3 | Bin 0 -> 11853 bytes data/audio.ogg | Bin 0 -> 17783 bytes ffmpeg/extras.c | 4 +++ ffmpeg/extras.h | 2 ++ ffmpeg/ffmpeg.go | 22 +++++++++++++++ ffmpeg/ffmpeg_test.go | 62 ++++++++++++++++++++++++++++++++++-------- 6 files changed, 79 insertions(+), 11 deletions(-) create mode 100644 data/audio.mp3 create mode 100644 data/audio.ogg diff --git a/data/audio.mp3 b/data/audio.mp3 new file mode 100644 index 0000000000000000000000000000000000000000..8fa9262745f11766eb9a46132f47063fac3b7009 GIT binary patch literal 11853 zcmciIRajJAxB%b*1{hL6Kw^dlDUp^^YUu8kP6g>yx?fDqRUK`tI{?*E?t z?*%xw8UR6Y|7@X2QJ{f{3VI&OU?7AZBK6`v?+;N|_iZ5q!&41nVq$(cTxt}!@`A$; zZd;vsocv8YI$8tKAdz7j#6;Zy0Knnwkx>tKV-Olq_Zq4YKhyzcA-u!?cXHbE2ms<< zQTX+MF#7wa!fAlJ{^1IIl0Zp`;!07i9 zG*1`|;=G@O6Ojbh(V1d)pI!H9SpVw@-Bncp8KHY2#|dzxWtA1s-cl5pC5$}ozRyf= zoyq)UJ>SBWD%Fi2^>b~yz7{?-yj2pOlSQTN8{ zogF8Crppk6X-?VC`tsWRkcK{@km}`N98p$oD-{>N$rurQKIFPH>---f{>x+SpFwjn zWP0ZTSDkx;k#Us-PUi9i)=|H(lOti+h{VU_I2~#oesBu$GexnpUJ(fa1v+M)c(HK^ zJIEg8A)u}2EiPS=0FC2b*Zin+Z9S@v4Z|gdhYkuF-#GQpx?YX3?MMz6C(0fV9xT5W zD8PWv;_f%^vvk5ds9-O94vyuJ6D>S?f86Hr;@DFkVgY28$L!0JEQZtQvu{-14^d){ zfalR!G+o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2~S8e`6}K!7K$xfu>vo0)zUQVGl#594x>E2)Hq3X zsr^{$Um6a`*&0_k^(xY5$?-T7vkgL>zd9!2R~6|`9$AVm$}kj6Z+jU&iypbv4Pdls zH~EJDbLl=B0Dh$ZkhA)|mticWlr@+3fw&IX%(LMwBdQxdwo`s0^G zCw%QnALd%UXv@g$Llz%}>rxopX)Rf+==}aOD~pDeXxW0z{uF>Du4S`+Uz@ilowOvx z`<3})&V))z_d{2^Uk^7eu}VISa9*gu66FMuZ?#|bluHM=sICfN!**^=L0o%#AHJ%y zxyAUYV8q)US8uo*mUygCqdW!BvHc3&-q21%n)9pUahZ6MM4XqlCH-xKqC`&<^*=L= z%zfRZldsdb3Q%GM0DHSFUSzYt^w4~J94k3T?GjLuR8ZX1mlyRYxG<?k9 z^5VCRO}%_}r!CbNAT;3@xjof2}Iz(K)WszPN+Tc6DT|RSdiC zQl5V5M%ILL!X9gO7BVGQ=^%kmrXLFxg)>T06ua;<*l{DRVldQRqC7p+eu!jU^UzKg zGu?G8Vzxf5f_ijq>xh?G0o%nvMXRLeEA=Wk#3rCG*hj4&(9(RjjWG&mfefX2Y8 z%qrk)Jht?j>Wg}Q4t_i^GSAKJa&Pb!sGq%CG(Bfg?+q$Gz{IBz5i1A|2JelrKQ_I@ zB^Rb0LuH`_!C@%RZ`$BKZEZgyW$+mS0>fWqU&+KGpXZ2_0jJ=xD@&@#@S#4MuK0f` WD9<4+UQ|A>gsjB>OO5|`CI18J!gbaF literal 0 HcmV?d00001 diff --git a/data/audio.ogg b/data/audio.ogg new file mode 100644 index 0000000000000000000000000000000000000000..83e99628a45af1cf61393136334e7fa2ea452fae GIT binary patch literal 17783 zcmV)kK%l=*XJ=CY0ssI2000000Mu9`6951J00t(|H~|w+aCLJ?Wnp9i0XPA`T>t<8 z002*CXHx(G0000000000)L0`E0RR91fYRG{0X|P~b#qiasVDgOtbu&KYEou8kmpqrwisfpx&iJqdLps}8sm5z&= z{{eIVF`S{~{B{1B{|K3oiJ_V7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X{fCQ|DbDBOccx zx`GrzS)J)mUSO%(-5U3|Qs$(YF(`@5P*qlqK&_<|iB9P)%OgXa`@|IuZA~MpIK48c zfZ1{f%1sTG(prmq`uvehiT&!9AhtB7E#}l@O6*!(sB4k#a{iPvYVG8BS0URyM>ZHC1DFGI!-+3+}YhLh$81O-b;3NpQQe+_zQ)O`U<$ z*x7jLASjoB-SU-LLW8ynvk6$C;{cRz<7KmW9 z3}qZ2v;J|5Aj#YH*7;NSdCj3R`O2@}q7>9tcN@W}b>Y|yfP~4uG0T=G}v{303l)J%N3mQWPqp@mjrWzN#2+ghQ^TN zJGiJ{<$_^b{8{<@u?yPMra!A+%*3Q3wEk#3`zP(fVRNl879K{blYw_h+^joQ7>kRd zxh$}v$rGk2@{re80pCRz{kXCvFVK8fu3R7THMto}2#bOWo6yw{Ja|}h5;|xId-Vr1 zp8uR1Ob%?pJ&pizIeu)aj?uAUttN!`hFwVb^I3Dz>%& zZNk zIBfkiLUT@5ud`rlmz?idB^f6rbq-3o+F6yYmhm0JDapj@m{hSyCmBz3_}=*niBp6c!(fzg`=v zrIfw~cpG*)8A4!+jxK_=RsS>8&THVBM`(o+b2QU>p^fdc$t}Tqotzm!SMFG+E!7vy zSVCAmO{PTj*7O+aa>mL?k^2VVXsN?Fb^2f%aqh?YB%52HpCbl74=$ zU!g#3kH|4*n$HT6C{fK_xYw$jlVPukf~vWHJ(gFcpj?2VmnIdI4e~ox^0UhA%f*=_ OG`GN_jigrb_R>&GsBwe< literal 0 HcmV?d00001 diff --git a/ffmpeg/extras.c b/ffmpeg/extras.c index 82a7609e1e..3d93734058 100644 --- a/ffmpeg/extras.c +++ b/ffmpeg/extras.c @@ -168,6 +168,9 @@ int lpms_get_codec_info(char *fname, pcodec_info out) out->dur = ic->duration / AV_TIME_BASE; } // Return + if (ic->iformat && ic->iformat->name) { + strncpy(out->format_name, ic->iformat->name, MIN(strlen(out->format_name), strlen(ic->iformat->name)) + 1); + } if (video_present && vc->name) { strncpy(out->video_codec, vc->name, MIN(strlen(out->video_codec), strlen(vc->name))+1); // If video track is present extract pixel format info @@ -186,6 +189,7 @@ int lpms_get_codec_info(char *fname, pcodec_info out) } if (audio_present && ac->name) { strncpy(out->audio_codec, ac->name, MIN(strlen(out->audio_codec), strlen(ac->name))+1); + out->audio_bit_rate = ic->streams[astream]->codecpar->bit_rate; } else { // Indicate failure to extract audio codec from given container out->audio_codec[0] = 0; diff --git a/ffmpeg/extras.h b/ffmpeg/extras.h index b06b0903ac..3b7467fab7 100644 --- a/ffmpeg/extras.h +++ b/ffmpeg/extras.h @@ -2,8 +2,10 @@ #define _LPMS_EXTRAS_H_ typedef struct s_codec_info { + char * format_name; char * video_codec; char * audio_codec; + int audio_bit_rate; int pixel_format; int width; int height; diff --git a/ffmpeg/ffmpeg.go b/ffmpeg/ffmpeg.go index 94d9ff33d6..96eb9fa4e9 100755 --- a/ffmpeg/ffmpeg.go +++ b/ffmpeg/ffmpeg.go @@ -242,11 +242,13 @@ const ( ) type MediaFormatInfo struct { + Format string Acodec, Vcodec string PixFormat PixelFormat Width, Height int FPS float32 DurSecs int64 + AudioBitrate int } func (f *MediaFormatInfo) ScaledHeight(width int) int { @@ -261,15 +263,21 @@ func GetCodecInfo(fname string) (CodecStatus, MediaFormatInfo, error) { format := MediaFormatInfo{} cfname := C.CString(fname) defer C.free(unsafe.Pointer(cfname)) + fmtname := C.CString(strings.Repeat("0", 255)) acodec_c := C.CString(strings.Repeat("0", 255)) vcodec_c := C.CString(strings.Repeat("0", 255)) + defer C.free(unsafe.Pointer(fmtname)) defer C.free(unsafe.Pointer(acodec_c)) defer C.free(unsafe.Pointer(vcodec_c)) var params_c C.codec_info + params_c.format_name = fmtname params_c.video_codec = vcodec_c params_c.audio_codec = acodec_c params_c.pixel_format = C.AV_PIX_FMT_NONE status := CodecStatus(C.lpms_get_codec_info(cfname, ¶ms_c)) + if C.strlen(fmtname) < 255 { + format.Format = C.GoString(fmtname) + } if C.strlen(acodec_c) < 255 { format.Acodec = C.GoString(acodec_c) } @@ -281,6 +289,7 @@ func GetCodecInfo(fname string) (CodecStatus, MediaFormatInfo, error) { format.Height = int(params_c.height) format.FPS = float32(params_c.fps) format.DurSecs = int64(params_c.dur) + format.AudioBitrate = int(params_c.audio_bit_rate) return status, format, nil } @@ -300,6 +309,19 @@ func GetCodecInfoBytes(data []byte) (CodecStatus, MediaFormatInfo, error) { } fname := fmt.Sprintf("pipe:%d", or.Fd()) status, format, err = GetCodecInfo(fname) + + // estimate duration from bitrate and filesize for audio + // some formats do not have built-in track duration metadata, + // and pipes do not have a filesize on their own which breaks ffmpeg's own + // duration estimates. So do the estimation calculation ourselves + // NB : mpegts has the same problem but may contain video so let's not handle that + // some other formats, eg ogg, show zero bitrate + // + // ffmpeg estimation of duration from bitrate: + // https://github.com/FFmpeg/FFmpeg/blob/8280ec7a3213c9b7bad88aac3695be2dedd2c00b/libavformat/demux.c#L1798 + if format.DurSecs == 0 && format.AudioBitrate > 0 && (format.Format == "mp3" || format.Format == "wav" || format.Format == "aac") { + format.DurSecs = int64(len(data) * 8 / format.AudioBitrate) + } return status, format, err } diff --git a/ffmpeg/ffmpeg_test.go b/ffmpeg/ffmpeg_test.go index fa2f822523..3256d4c479 100644 --- a/ffmpeg/ffmpeg_test.go +++ b/ffmpeg/ffmpeg_test.go @@ -1987,28 +1987,68 @@ func TestDurationFPS_GetCodecInfo(t *testing.T) { ffprobe -loglevel warning -show_format test.m4a | grep duration=2.042993 ffmpeg -loglevel warning -i test-short.mp4 -vn -c:a flac test.flac ffprobe -loglevel warning -show_format test.flac | grep duration=2.043356 + + ffmpeg -loglevel warning -i test.mp4 -vn -c:a copy stereo-audio.aac + ffprobe -show_entries stream=channels,channel_layout -of csv stereo-audio.aac | grep stream,2,stereo + ffprobe -show_format stereo-audio.aac | grep duration=52.440083 + + ffmpeg -i test.mp4 -vn stereo-audio.wav + ffprobe -show_format stereo-audio.wav | grep duration=60.139683 + + cp $1/../data/audio.mp3 test.mp3 + ffprobe -show_format test.mp3 | grep duration=1.968000 + + cp $1/../data/audio.ogg test.ogg + ffprobe -show_format test.ogg | grep duration=1.974500 ` run(cmd) files := []struct { Filename string + Format string Duration int64 FPS float32 + + // skip check if bytes version is known to fail duration + BytesSkipDuration bool }{ - {Filename: "test-short.mp4", Duration: 2, FPS: 24}, - {Filename: "test.ts", Duration: 2, FPS: 30.0}, - {Filename: "test.flac", Duration: 2, FPS: 0.0}, - {Filename: "test.webm", Duration: 2, FPS: 24}, - {Filename: "test.m4a", Duration: 2, FPS: 0.0}, + {Filename: "test-short.mp4", Format: "mov,mp4,m4a,3gp,3g2,mj2", Duration: 2, FPS: 24}, + {Filename: "test.ts", Format: "mpegts", Duration: 2, FPS: 30.0, BytesSkipDuration: true}, + {Filename: "test.flac", Format: "flac", Duration: 2}, + {Filename: "test.webm", Format: "matroska,webm", Duration: 2, FPS: 24}, + {Filename: "test.m4a", Format: "mov,mp4,m4a,3gp,3g2,mj2", Duration: 2}, + {Filename: "stereo-audio.aac", Format: "aac", Duration: 52}, + {Filename: "stereo-audio.wav", Format: "wav", Duration: 60}, + {Filename: "test.mp3", Format: "mp3", Duration: 1}, + {Filename: "test.ogg", Format: "ogg", Duration: 1, BytesSkipDuration: true}, } for _, file := range files { t.Run(file.Filename, func(t *testing.T) { - assert := assert.New(t) - status, format, err := GetCodecInfo(path.Join(dir, file.Filename)) - assert.Nil(err, "getcodecinfo error") - assert.Equal(CodecStatusOk, status, "status not ok") - assert.Equal(file.Duration, format.DurSecs, "duration mismatch") - assert.Equal(file.FPS, format.FPS, "fps mismatch") + fname := path.Join(dir, file.Filename) + // use 'bytes' prefix to prevent test runner regex matching + for _, tt := range []string{"GetCodecInfo", "BytesGetCodecInfo"} { + t.Run(tt, func(t *testing.T) { + assert := assert.New(t) + f := func() (CodecStatus, MediaFormatInfo, error) { + if tt == "GetCodecInfo" { + return GetCodecInfo(fname) + } + d, err := os.ReadFile(fname) + assert.Nil(err, "reading file") + return GetCodecInfoBytes(d) + } + status, format, err := f() + assert.Nil(err, "getcodecinfo error") + assert.Equal(CodecStatusOk, status, "status not ok") + assert.Equal(file.Format, format.Format, "format mismatch") + if tt == "BytesGetCodecInfo" && file.BytesSkipDuration { + assert.Equal(int64(0), format.DurSecs, "special duration mismatch") + } else { + assert.Equal(file.Duration, format.DurSecs, "duration mismatch") + } + assert.Equal(file.FPS, format.FPS, "fps mismatch") + }) + } }) } }