
Recherche avancée
Autres articles (77)
-
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...)
Sur d’autres sites (10351)
-
muxing DVB subtitles into transport stream with ffmpeg
28 novembre 2019, par user3439130So i have H264 video + AAC audio muxed inside transport stream (*.ts). To achive evenly spread PCR values i added muxrate tag to my command.
ffmpeg -analyzeduration 20000000 -probesize 20M -loglevel verbose -i 1135084.m4v -i 1135084.m4a -c copy -muxrate 7982K -map 0:v:0 -map 1:a:0 -metadata:s:a:0 language=eng -metadata:s:a:0 tms_track_id=169451954 TEMP0.ts
Since our client need DVB substitles we convert SRT to DVD with subtitle edit and then encode them to DVB with ffmpeg with this command :
ffmpeg -analyzeduration 20000000 -probesize 20M -loglevel verbose -i TEMP0.ts -i out.da.idx -map 0 -c copy -muxrate 7992K -map 1:s -c:s:0 dvbsub -metadata:s:s:0 language=dan TEMP1.ts
here is output from ffmpeg command :
ffmpeg version git-2019-11-18-d831edc Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 9.2.1 (GCC) 20191010
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt --enable-amf
libavutil 56. 36.100 / 56. 36.100
libavcodec 58. 62.100 / 58. 62.100
libavformat 58. 35.100 / 58. 35.100
libavdevice 58. 9.101 / 58. 9.101
libavfilter 7. 66.100 / 7. 66.100
libswscale 5. 6.100 / 5. 6.100
libswresample 3. 6.100 / 3. 6.100
libpostproc 55. 6.100 / 55. 6.100
[h264 @ 000002bf7460d400] non-existing SPS 0 referenced in buffering period
[h264 @ 000002bf7460d400] SPS unavailable in decode_picture_timing
[h264 @ 000002bf7460d400] non-existing SPS 0 referenced in buffering period
[h264 @ 000002bf7460d400] SPS unavailable in decode_picture_timing
[h264 @ 000002bf7460d400] Reinit context to 1920x1088, pix_fmt: yuv420p
[mpegts @ 000002bf7460ae00] max_analyze_duration 20000000 reached at 20000000 microseconds st:0
[mpegts @ 000002bf7460ae00] start time for stream 2 is not set in estimate_timings_from_pts
Input #0, mpegts, from 'TEMP1.ts':
Duration: 01:51:54.48, start: 1.440000, bitrate: 7992 kb/s
Program 1
Metadata:
service_name : Service01
service_provider: FFmpeg
Stream #0:0[0x100]: Video: h264 (High), 1 reference frame ([27][0][0][0] / 0x001B), yuv420p(progressive, left), 1920x1080 (1920x1088) [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
Stream #0:1[0x101](eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, stereo, fltp, 254 kb/s
Stream #0:2[0x102](dan): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006)
[vobsub @ 000002bf75d65940] IDX/SUB: out.fi.idx -> out.fi.sub
Input #1, vobsub, from 'out.fi.idx':
Duration: N/A, bitrate: N/A
Stream #1:0[0x0](fi): Subtitle: dvd_subtitle, 1920x1080 (default)
File 'TEMP2.ts' already exists. Overwrite? [y/N] y
[mpegts @ 000002bf74634f00] service 1 using PCR in pid=256, pcr_period=20ms
[mpegts @ 000002bf74634f00] muxrate 8002000, sdt every 500 ms, pat/pmt every 100 ms
Output #0, mpegts, to 'TEMP2.ts':
Metadata:
encoder : Lavf58.35.100
Stream #0:0: Video: h264 (High), 1 reference frame ([27][0][0][0] / 0x001B), yuv420p(progressive, left), 1920x1080 (0x0) [SAR 1:1 DAR 16:9], q=2-31, 25 fps, 25 tbr, 90k tbn, 90k tbc
Stream #0:1(eng): Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, stereo, fltp, 254 kb/s
Stream #0:2(dan): Subtitle: dvb_subtitle ([6][0][0][0] / 0x0006)
Stream #0:3(fin): Subtitle: dvb_subtitle (dvbsub), 1920x1080 (default)
Metadata:
encoder : Lavc58.62.100 dvbsub
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Stream #0:2 -> #0:2 (copy)
Stream #1:0 -> #0:3 (dvd_subtitle (dvdsub) -> dvb_subtitle (dvbsub))
Press [q] to stop, [?] for help
No more output streams to write to, finishing.me=01:51:46.51 bitrate=7990.2kbits/s speed=18.2x
frame=167862 fps=456 q=-1.0 Lsize= 6558750kB time=01:51:54.47 bitrate=8002.0kbits/s speed=18.2x
video:5738580kB audio:212004kB subtitle:10989kB other streams:0kB global headers:0kB muxing overhead: 10.017118%
Input file #0 (TEMP1.ts):
Input stream #0:0 (video): 167862 packets read (5876305439 bytes);
Input stream #0:1 (audio): 314742 packets read (217092443 bytes);
Input stream #0:2 (subtitle): 1740 packets read (5578504 bytes);
Total: 484344 packets (6098976386 bytes) demuxed
Input file #1 (out.fi.idx):
Input stream #1:0 (subtitle): 855 packets read (6881158 bytes); 854 frames decoded;
Total: 855 packets (6881158 bytes) demuxed
Output file #0 (TEMP2.ts):
Output stream #0:0 (video): 167862 packets muxed (5876305439 bytes);
Output stream #0:1 (audio): 314742 packets muxed (217092443 bytes);
Output stream #0:2 (subtitle): 1740 packets muxed (5578504 bytes);
Output stream #0:3 (subtitle): 1708 frames encoded; 1708 packets muxed (5673736 bytes);
Total: 486052 packets (6104650122 bytes) muxed
[AVIOContext @ 000002bf7463c280] Statistics: 0 seeks, 25621 writeouts
[AVIOContext @ 000002bf74613f80] Statistics: 6728300448 bytes read, 2 seeks
[AVIOContext @ 000002bf75efde40] Statistics: 7852032 bytes read, 0 seeks
[AVIOContext @ 000002bf74f30e40] Statistics: 40275 bytes read, 0 seeksSo i have video/audio and two dvb tracks inside one TS.
Now im adding third subtitle and i get this warning :
frame=32351 fps=869 q=-1.0 size= 1255936kB time=00:21:33.99 bitrate=7951.1kbits/s speed=34.8x
[mpegts @ 0x2994600] Non-monotonous DTS in output stream 0:3; previous: 116868609, current: 116868607; changing to 116868610. This may result in incorrect timestamps in the output file.
frame=33416 fps=886 q=-1.0 size= 1297408kB time=00:22:16.56 bitrate=7952.0kbits/s speed=35.4xBy this warning it seems that something is not right with DVB (0:3) Finish track.
Playing back the file with VLC i can see that Finish subtitles (between 21:33 and 22:16) are not showing up.Dumping packets from 0:3 track i see that 4 packets have the same DTS/PTS values.
#stream#, dts, pts, duration, size, hash
0, 111258000, 111258000, 0, 6979, 6215f060, S=1, 1, 67d220bc
0, 111689100, 111689100, 0, 25, e60e94fa, S=1, 1, 67d220bc
0, 113230800, 113230800, 0, 4423, f811be62, S=1, 1, 67d220bc
0, 113561550, 113561550, 0, 25, 6db8d81f, S=1, 1, 67d220bc
0, 113788800, 113788800, 0, 8247, 8b494779, S=1, 1, 67d220bc
0, 114191190, 114191190, 0, 25, a205e183, S=1, 1, 67d220bc
0, 116868607, 116868607, 0, 1119, e5d11188, S=1, 1, 67d220bc
0, 116868607, 116868607, 0, 28, 11e09861, S=1, 1, 67d220bc
0, 116868607, 116868607, 0, 1122, 8320a3f5, S=1, 1, 67d220bc
0, 116868607, 116868607, 0, 28, e896fa37, S=1, 1, 67d220bc
0, 117205200, 117205200, 0, 3583, 47b23f27, S=1, 1, 67d220bc
0, 117611640, 117611640, 0, 25, e5ae32ed, S=1, 1, 67d220bc
0, 117709200, 117709200, 0, 1119, 208b4f80, S=1, 1, 67d220bc
0, 117830970, 117830970, 0, 25, 2a130b71, S=1, 1, 67d220bc
0, 117846000, 117846000, 0, 3105, f179a4f0, S=1, 1, 67d220bc
0, 118148040, 118148040, 0, 25, 29b3ad66, S=1, 1, 67d220bc
0, 120146410, 120146410, 0, 1119, 714ef5d1, S=1, 1, 67d220bc
0, 120146410, 120146410, 0, 28, bbad7fed, S=1, 1, 67d220bc
0, 120708000, 120708000, 0, 2060, 703084f7, S=1, 1, 67d220bc
0, 120855420, 120855420, 0, 25, 6db8d81f, S=1, 1, 67d220bc
0, 121122000, 121122000, 0, 2184, 04a7be71, S=1, 1, 67d220bc
0, 121395330, 121395330, 0, 25, a205e183, S=1, 1, 67d220bcThes are the lines from SRT file where the warning happens :
146
00:21:34,840 --> 00:21:36,600
Make!
147
00:21:42,280 --> 00:21:46,800
Make! Hei, Make. Make!
148
00:21:47,880 --> 00:21:49,240
Make!
149
00:21:49,400 --> 00:21:52,760
Odota minua, Make!
150
00:22:00,400 --> 00:22:01,760
Make!Sometimes muxing subtitles in different order (for example Finish before Danish and then Swedish) would solve this problem, but i would like to know why such things are happening.
-
FFMPEG recording get an error when camera is turned off
29 novembre 2019, par Bogdan RudnytskyiI have a video recording service using ffmpeg.
When the camera is turned off, I don’t get an error and the service freezes.
Please help me how I can configure recording so that this service crashes with an error ? (and I will use Supervisor).
Maybe I need to insert some flag ?ffmpeg -rtsp_transport tcp -i 'rtsp://...' -reconnect 1 -c:v copy -c:a copy -flags -global_header -hls_time 5 -hls_list_size 0 -strftime 1 -hls_segment_filename '%Y%m%d%H%M%S.ts' archive.m3u8 -nostats
logs
ffmpeg started on 2019-11-28 at 10:23:14 Report written to "ffmpeg-20191128-102314.log" Command line: "C:\\ffmpeg\\bin\\ffmpeg.exe" -report -rtsp_transport tcp -i "rtsp://..." -reconnect 1 -c:v copy -c:a copy -flags -global_header
-hls_time 5 -hls_list_size 0 -strftime 1 -hls_segment_filename "%Y%m%d%H%M%S.ts" archive.m3u8 ffmpeg version N-94150-g231d0c819f Copyright (c) 2000-2019 the FFmpeg developers built with gcc 9.1.1 (GCC) 20190621 configuration: --enable-gpl --enable-version3
--enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt libavutil 56. 30.100 / 56. 30.100 libavcodec 58. 53.101 /
58. 53.101 libavformat 58. 28.101 / 58. 28.101 libavdevice 58. 7.100 / 58. 7.100 libavfilter 7. 55.100 / 7. 55.100 libswscale 5. 4.101 / 5. 4.101 libswresample 3. 4.100 /
3. 4.100 libpostproc 55. 4.100 / 55. 4.100 Splitting the commandline. Reading option '-report' ... matched as option 'report' (generate a report) with argument '1'. Reading option '-rtsp_transport' ... matched as AVOption 'rtsp_transport' with argument 'tcp'. Reading option '-i' ... matched as input url with argument 'rtsp://...'. Reading option '-reconnect' ... matched as AVOption 'reconnect' with argument '1'. Reading option '-c:v' ... matched as option 'c' (codec name) with argument 'copy'. Reading option '-c:a' ... matched as option 'c' (codec name) with argument 'copy'. Reading option '-flags' ... matched as AVOption 'flags' with argument '-global_header'. Reading option '-hls_time' ... matched as AVOption 'hls_time' with argument '5'. Reading option '-hls_list_size' ... matched as AVOption 'hls_list_size' with argument '0'. Reading option '-strftime' ... matched as AVOption 'strftime' with argument '1'. Reading option '-hls_segment_filename' ... matched as AVOption 'hls_segment_filename' with argument '%Y%m%d%H%M%S.ts'. Reading option 'archive.m3u8' ... matched as output url. Finished splitting the commandline. Parsing a group of options: global . Applying option report (generate a report) with argument 1. Successfully parsed a group of options. Parsing a group of options: input url 'rtsp://...'. Successfully parsed a group of options. Opening an input file: 'rtsp://...'. [tcp @ 0000025972ecd180] No default whitelist set [tcp @ 0000025972ecd180] Original list of addresses: [tcp @ 0000025972ecd180] Address 0.0.0.0 port 999 [tcp @ 0000025972ecd180] Interleaved list of addresses: [tcp @ 0000025972ecd180] Address 0.0.0.0 port 999 [tcp @ 0000025972ecd180] Starting connection attempt to 0.0.0.0 port 999 [tcp @ 0000025972ecd180] Successfully connected to 0.0.0.0 port 999 [rtsp @ 0000025972ecca80] SDP: v=0
o=- 1574936594324879 1574936594324879 IN IP4 10.10.1.65
s=Media Presentation
e=NONE
b=AS:5050
t=0 0
a=control:'rtsp://...'
m=video 0 RTP/AVP 96
c=IN IP4 0.0.0.0
b=AS:5000
a=recvonly
a=x-dimensions:1920,1080
a=control:'rtsp://...'
a=rtpmap:96 H264/90000
a=fmtp:96 profile-level-id=420029; packetization-mode=1; sprop-parameter-sets=Z00AKZpkA8ARPy4C3AQEBQAAAwPoAADDUOhgAP84AAP80rvLjQwAH+cAAH+aV3lwoA==,aO48gA==
a=Media_header:MEDIAINFO=494D4B48010200000400000100000000000000000000000000000000000000000000000000000000;
a=appversion:1.0
[rtsp @ 0000025972ecca80] video codec set to: h264 [rtsp @ 0000025972ecca80] RTP Profile IDC: 42 Profile IOP: 0 Level: 29 [rtsp @ 0000025972ecca80] RTP Packetization Mode: 1 [rtsp @ 0000025972ecca80] Extradata set to 0000025972ed0600 (size: 61) [rtsp @ 0000025972ecca80] setting jitter buffer size to 0 [rtsp @ 0000025972ecca80] hello state=0 [h264 @ 0000025972ed0080] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 8(PPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 8(PPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 8(PPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 5(IDR), nal_ref_idc: 3 [h264 @ 0000025972ed0080] Format yuvj420p chosen by get_format(). [h264 @ 0000025972ed0080] Reinit context to 1920x1088, pix_fmt: yuvj420p [h264 @ 0000025972ed0080] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 8(PPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 5(IDR), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 7(SPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 8(PPS), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 5(IDR), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 3 [h264 @ 0000025972ed0080] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 3 [rtsp @ 0000025972ecca80] All info found Input #0, rtsp, from 'rtsp://...': Metadata:
title : Media Presentation Duration: N/A, start: 0.240000, bitrate: N/A
Stream #0:0, 28, 1/90000: Video: h264 (Main), yuvj420p(pc, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc Successfully opened the file. Parsing a group of options: output url archive.m3u8. Applying option c:v (codec name) with argument copy. Applying option c:a (codec name) with argument copy. Successfully parsed a group of options. Opening an output file: archive.m3u8. Successfully opened the file. [hls @ 0000025972f977c0] Opening '20191128102316.ts' for writing [file @ 0000025975633ec0] Setting default whitelist 'file,crypto' [mpegts @ 00000259756333c0] muxrate VBR, pcr every 2 pkts, sdt every 2147483647, pat/pmt every 2147483647 pkts Output #0, hls, to 'archive.m3u8': Metadata:
title : Media Presentation
encoder : Lavf58.28.101
Stream #0:0, 0, 1/90000: Video: h264 (Main), yuvj420p(pc, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 25 fps, 25 tbr, 90k tbn, 25 tbc Stream mapping: Stream #0:0 -> #0:0 (copy) Press [q] to stop, [?] for help cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless if it occurs once at the start per stream) [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 0, current: -18000; changing to 1. This may result in incorrect timestamps in the output file. [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 1, current: -14400; changing to 2. This may result in incorrect timestamps in the output file. [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 2, current: -10800; changing to 3. This may result in incorrect timestamps in the output file. [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 3, current: -7200; changing to 4. This may result in incorrect timestamps in the output file. [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 4, current: -3600; changing to 5. This may result in incorrect timestamps in the output file. [hls @ 0000025972f977c0] Non-monotonous DTS in output stream 0:0; previous: 5, current: 0; changing to 6. This may result in incorrect timestamps in the output file. frame= 48 fps=0.0 q=-1.0 size=N/A time=00:00:01.68 bitrate=N/A speed=3.13x frame= 61 fps= 58 q=-1.0 size=N/A time=00:00:02.20 bitrate=N/A speed= 2.1x frame= 74 fps= 47 q=-1.0 size=N/A time=00:00:02.72 bitrate=N/A speed=1.74x frame= 87 fps= 41 q=-1.0 size=N/A time=00:00:03.24 bitrate=N/A speed=1.54x frame= 100 fps= 38 q=-1.0 size=N/A time=00:00:03.76 bitrate=N/A speed=1.44x frame= 113 fps= 36 q=-1.0 size=N/A time=00:00:04.27 bitrate=N/A speed=1.37x frame= 125 fps= 34 q=-1.0 size=N/A time=00:00:04.75 bitrate=N/A speed=1.31x frame= 138 fps= 33 q=-1.0 size=N/A time=00:00:05.27 bitrate=N/A speed=1.28x frame= 151 fps= 32 q=-1.0 size=N/A time=00:00:05.79 bitrate=N/A speed=1.24x [AVIOContext @ 0000025972ecbe80] Statistics: 0 seeks, 15 writeouts [hls @ 0000025972f977c0] Opening '20191128102321.ts' for writing [file @ 0000025972f9ef00] Setting default whitelist 'file,crypto' [hls @ 0000025972f977c0] Opening 'archive.m3u8.tmp' for writing [file @ 000002597562ff40] Setting default whitelist 'file,crypto' EXT-X-MEDIA-SEQUENCE:0 [AVIOContext @ 0000025972ecbfc0] Statistics: 0 seeks, 1 writeouts frame= 165 fps= 32 q=-1.0 size=N/A time=00:00:06.35 bitrate=N/A speed=1.22x frame= 178 fps= 31 q=-1.0 size=N/A time=00:00:06.87 bitrate=N/A speed= 1.2x frame= 192 fps= 31 q=-1.0 size=N/A time=00:00:07.43 bitrate=N/A speed=1.18x frame= 204 fps= 30 q=-1.0 size=N/A time=00:00:07.91 bitrate=N/A speed=1.17x frame= 218 fps= 30 q=-1.0 size=N/A time=00:00:08.47 bitrate=N/A speed=1.16x frame= 231 fps= 29 q=-1.0 size=N/A time=00:00:08.99 bitrate=N/A speed=1.15x frame= 244 fps= 29 q=-1.0 size=N/A time=00:00:09.51 bitrate=N/A speed=1.14x frame= 255 fps= 29 q=-1.0 size=N/A time=00:00:09.95 bitrate=N/A speed=1.11x frame= 272 fps= 29 q=-1.0 size=N/A time=00:00:10.63 bitrate=N/A speed=1.12x frame= 285 fps= 28 q=-1.0 size=N/A time=00:00:11.15 bitrate=N/A speed=1.11x frame= 299 fps= 28 q=-1.0 size=N/A time=00:00:11.71 bitrate=N/A speed=1.11x [AVIOContext @ 0000025972ecbe80] Statistics: 0 seeks, 12 writeouts [hls @ 0000025972f977c0] Opening '20191128102327.ts' for writing [file @ 0000025975633ec0] Setting default whitelist 'file,crypto' [hls @ 0000025972f977c0] Opening 'archive.m3u8.tmp' for writing [file @ 0000025975630780] Setting default whitelist 'file,crypto' EXT-X-MEDIA-SEQUENCE:0 [AVIOContext @ 0000025972ecbfc0] Statistics: 0 seeks, 1 writeouts frame= 305 fps= 28 q=-1.0 size=N/A time=00:00:11.95 bitrate=N/A speed=1.08x frame= 325 fps= 28 q=-1.0 size=N/A time=00:00:12.75 bitrate=N/A speed= 1.1x frame= 338 fps= 28 q=-1.0 size=N/A time=00:00:13.27 bitrate=N/A speed=1.09x frame= 351 fps= 28 q=-1.0 size=N/A time=00:00:13.79 bitrate=N/A speed=1.09x frame= 364 fps= 28 q=-1.0 size=N/A time=00:00:14.31 bitrate=N/A speed=1.09x frame= 377 fps= 28 q=-1.0 size=N/A time=00:00:14.83 bitrate=N/A speed=1.08x frame= 390 fps= 27 q=-1.0 size=N/A time=00:00:15.35 bitrate=N/A speed=1.08x frame= 403 fps= 27 q=-1.0 size=N/A time=00:00:15.87 bitrate=N/A speed=1.08x [AVIOContext @ 0000025972ecbe80] Statistics: 0 seeks, 8 writeouts [hls @ 0000025972f977c0] Opening '20191128102331.ts' for writing [file @ 0000025975633ec0] Setting default whitelist 'file,crypto' [hls @ 0000025972f977c0] Opening 'archive.m3u8.tmp' for writing [file @ 0000025975630240] Setting default whitelist 'file,crypto' EXT-X-MEDIA-SEQUENCE:0 [AVIOContext @ 0000025972ecbfc0] Statistics: 0 seeks, 1 writeouts frame= 416 fps= 27 q=-1.0 size=N/A time=00:00:16.39 bitrate=N/A speed=1.08x frame= 428 fps= 27 q=-1.0 size=N/A time=00:00:16.87 bitrate=N/A speed=1.07x frame= 442 fps= 27 q=-1.0 size=N/A time=00:00:17.43 bitrate=N/A speed=1.07x frame= 454 fps= 27 q=-1.0 size=N/A time=00:00:17.91 bitrate=N/A speed=1.07x -
ffmpeg -to flag not always correctly recognized when processing the same file and different time ranges
10 novembre 2019, par SebastianI have a file that I wanted to cut into few pieces. The problem is my command not always works :
ffmpeg -ss 00:00:05 -i 4.DeepPurpleJag_robocze.mp4 -to 01:00:21 -c:v copy -c:a copy testing.mp4
produces properly cut video with the output :ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
built with Apple clang version 11.0.0 (clang-1100.0.33.8)
configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.1_2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags='-I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include/darwin -fno-stack-check' --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '4.DeepPurpleJag_robocze.mp4':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
creation_time : 2019-11-09T13:18:48.000000Z
encoder : HandBrake 1.2.2 2019022300
Duration: 03:05:31.33, start: 0.000000, bitrate: 1045 kb/s
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m/bt470bg/bt709), 350x480 [SAR 65535:35816 DAR 764575:573056], 904 kb/s, SAR 14801:8089 DAR 518035:388272, 25 fps, 25 tbr, 90k tbn, 180k tbc (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 134 kb/s (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : SoundHandler
File 'testing.mp4' already exists. Overwrite ? [y/N] y
Output #0, mp4, to 'testing.mp4':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf58.29.100
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m/bt470bg/bt709), 350x480 [SAR 14801:8089 DAR 518035:388272], q=2-31, 904 kb/s, 25 fps, 25 tbr, 90k tbn, 90k tbc (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 134 kb/s (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : SoundHandler
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame=23390 fps=0.0 q=-1.0 size= 122880kB time=00:15:35.35 bitrate=1076.2kbits/s sframe=47377 fps=47167 q=-1.0 size= 259584kB time=00:31:34.83 bitrate=1122.3kbits/sframe=74437 fps=49477 q=-1.0 size= 401664kB time=00:49:37.22 bitrate=1105.2kbits/sframe=90531 fps=47477 q=-1.0 Lsize= 518987kB time=01:00:20.98 bitrate=1174.1kbits/s speed=1.9e+03x
video:457170kB audio:59123kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.521705%However when I try to cut the same source with different ss and to like this
ffmpeg -ss 01:40:05 -i 4.DeepPurpleJag_robocze.mp4 -to 02:19:21 -c:v copy -c:a copy testing2.mp4
I got output file that is over 1,5h long instead of 39 minutes - the flag -to is ignored and file is cut till the end. output is :ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
built with Apple clang version 11.0.0 (clang-1100.0.33.8)
configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.1_2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags='-I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include/darwin -fno-stack-check' --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '4.DeepPurpleJag_robocze.mp4':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
creation_time : 2019-11-09T13:18:48.000000Z
encoder : HandBrake 1.2.2 2019022300
Duration: 03:05:31.33, start: 0.000000, bitrate: 1045 kb/s
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m/bt470bg/bt709), 350x480 [SAR 65535:35816 DAR 764575:573056], 904 kb/s, SAR 14801:8089 DAR 518035:388272, 25 fps, 25 tbr, 90k tbn, 180k tbc (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 134 kb/s (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : SoundHandler
File 'testing2.mp4' already exists. Overwrite ? [y/N] y
Output #0, mp4, to 'testing2.mp4':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf58.29.100
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuv420p(tv, smpte170m/bt470bg/bt709), 350x480 [SAR 14801:8089 DAR 518035:388272], q=2-31, 904 kb/s, 25 fps, 25 tbr, 90k tbn, 90k tbc (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 134 kb/s (default)
Metadata:
creation_time : 2019-11-09T13:18:48.000000Z
handler_name : SoundHandler
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame=31213 fps=0.0 q=-1.0 size= 122624kB time=00:20:45.83 bitrate= 806.3kbits/s sframe=61164 fps=61143 q=-1.0 size= 267264kB time=00:40:43.87 bitrate= 895.9kbits/sframe=91215 fps=60795 q=-1.0 size= 414464kB time=01:00:45.90 bitrate= 931.3kbits/sframe=117850 fps=58914 q=-1.0 size= 541440kB time=01:18:31.28 bitrate= 941.5kbits/frame=128220 fps=58002 q=-1.0 Lsize= 581509kB time=01:25:26.26 bitrate= 929.3kbits/s speed=2.32e+03x
video:493385kB audio:84316kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.659221%I have no idea what is going on, when I try to cut the movie using handbrake everything is ok. I can provide the file if necessary.