
Recherche avancée
Médias (2)
-
Granite de l’Aber Ildut
9 septembre 2011, par
Mis à jour : Septembre 2011
Langue : français
Type : Texte
-
Géodiversité
9 septembre 2011, par ,
Mis à jour : Août 2018
Langue : français
Type : Texte
Autres articles (79)
-
L’espace de configuration de MediaSPIP
29 novembre 2010, parL’espace de configuration de MediaSPIP est réservé aux administrateurs. Un lien de menu "administrer" est généralement affiché en haut de la page [1].
Il permet de configurer finement votre site.
La navigation de cet espace de configuration est divisé en trois parties : la configuration générale du site qui permet notamment de modifier : les informations principales concernant le site (...) -
Organiser par catégorie
17 mai 2013, parDans MédiaSPIP, une rubrique a 2 noms : catégorie et rubrique.
Les différents documents stockés dans MédiaSPIP peuvent être rangés dans différentes catégories. On peut créer une catégorie en cliquant sur "publier une catégorie" dans le menu publier en haut à droite ( après authentification ). Une catégorie peut être rangée dans une autre catégorie aussi ce qui fait qu’on peut construire une arborescence de catégories.
Lors de la publication prochaine d’un document, la nouvelle catégorie créée sera proposée (...) -
Récupération d’informations sur le site maître à l’installation d’une instance
26 novembre 2010, parUtilité
Sur le site principal, une instance de mutualisation est définie par plusieurs choses : Les données dans la table spip_mutus ; Son logo ; Son auteur principal (id_admin dans la table spip_mutus correspondant à un id_auteur de la table spip_auteurs)qui sera le seul à pouvoir créer définitivement l’instance de mutualisation ;
Il peut donc être tout à fait judicieux de vouloir récupérer certaines de ces informations afin de compléter l’installation d’une instance pour, par exemple : récupérer le (...)
Sur d’autres sites (5542)
-
FFmpeg wrong duration(double) when convert mp4
13 novembre 2017, par crazymxmThe output file has the double duration :
Source video duration :00:01:58.88
output video duration :00:03:57.76
(video’s duration is double ,audio’s duration is correct. So, the video looks like played twice, with no sound in the second half )
here is the log:
./ffmpeg -i /Volumes/LANKEXIN/1383.mp4 out.mp4
ffmpeg version N-82977-g8fd3e02-tessus Copyright (c) 2000-2016 the FFmpeg developers
built with Apple LLVM version 8.0.0 (clang-800.0.42.1)
configuration : —cc=/usr/bin/clang —prefix=/opt/ffmpeg —extra-version=tessus —enable-avisynth —enable-fontconfig —enable-gpl —enable-libass —enable-libbluray —enable-libfreetype —enable-libgsm —enable-libmodplug —enable-libmp3lame —enable-libopencore-amrnb —enable-libopencore-amrwb —enable-libopus —enable-libschroedinger —enable-libsnappy —enable-libsoxr —enable-libspeex —enable-libtheora —enable-libvidstab —enable-libvo-amrwbenc —enable-libvorbis —enable-libvpx —enable-libwavpack —enable-libx264 —enable-libx265 —enable-libxavs —enable-libxvid —enable-libzmq —enable-version3 —disable-ffplay —disable-indev=qtkit —disable-indev=x11grab_xcblibavutil 55. 43.100 / 55. 43.100
libavcodec 57. 70.100 / 57. 70.100
libavformat 57. 61.100 / 57. 61.100
libavdevice 57. 2.100 / 57. 2.100
libavfilter 6. 68.100 / 6. 68.100
libswscale 4. 3.101 / 4. 3.101
libswresample 2. 4.100 / 2. 4.100
libpostproc 54. 2.100 / 54. 2.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/Volumes/LANKEXIN/1383.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp42isom
creation_time : 2017-10-30T14:58:05.000000Z
encoder : mp4creator 1.6.1d
Duration: 00:01:58.88, start: 0.000000, bitrate: 1918 kb/s
Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], 1729 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc (default)
Metadata:
creation_time : 2017-10-30T14:58:05.000000Z
encoder : VC Coding
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 189 kb/s (default)
Metadata:
creation_time : 2017-10-30T14:58:05.000000Z
File 'out.mp4' already exists. Overwrite ? [y/N] y
[libx264 @ 0x7fbaca003c00] using SAR=1/1
[libx264 @ 0x7fbaca003c00] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
[libx264 @ 0x7fbaca003c00] profile High, level 3.1
[libx264 @ 0x7fbaca003c00] 264 - core 148 - H.264/MPEG-4 AVC codec - Copyleft 2003-2016 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to 'out.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp42isom
encoder : Lavf57.61.100
Stream #0:0(eng): Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 1280x720 [SAR 1:1 DAR 16:9], q=-1--1, 25 fps, 12800 tbn, 25 tbc (default)
Metadata:
creation_time : 2017-10-30T14:58:05.000000Z
encoder : Lavc57.70.100 libx264
Side data:
cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream #0:1(eng): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
Metadata:
creation_time : 2017-10-30T14:58:05.000000Z
encoder : Lavc57.70.100 aac
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Stream #0:1 -> #0:1 (aac (native) -> aac (native))
Press [q] to stop, [?] for help
frame= 46 fps=0.0 q=0.0 size= 0kB time=00:00:00.93 bitrate= 0.0kbits/sframe= 64 fps= 45 q=28.0 size= 137kB time=00:00:01.66 bitrate= 672.2kbits/frame= 85 fps= 44 qframe= 5944 fps= 33 q=-1.0 Lsize= 38746kB time=00:03:57.64 bitrate=1335.7kbits/s speed=1.33x 4kB time=00:00:02.94 bitrate= 818.0kbits/s speed= 1.2x
video:36779kB audio:1846kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.311413%
[libx264 @ 0x7fbaca003c00] frame I:24 Avg QP:19.49 size: 67090
[libx264 @ 0x7fbaca003c00] frame P:1806 Avg QP:21.65 size: 14304
[libx264 @ 0x7fbaca003c00] frame B:4114 Avg QP:25.42 size: 2484
[libx264 @ 0x7fbaca003c00] consecutive B-frames: 2.2% 8.1% 25.5% 64.2%
[libx264 @ 0x7fbaca003c00] mb I I16..4: 20.6% 55.8% 23.6%
[libx264 @ 0x7fbaca003c00] mb P I16..4: 5.2% 9.3% 0.8% P16..4: 36.0% 9.9% 4.2% 0.0% 0.0% skip:34.5%
[libx264 @ 0x7fbaca003c00] mb B I16..4: 0.5% 1.0% 0.0% B16..8: 27.2% 1.8% 0.2% direct: 0.9% skip:68.5% L0:48.6% L1:47.6% BI: 3.8%
[libx264 @ 0x7fbaca003c00] 8x8 transform intra:60.9% inter:78.2%
[libx264 @ 0x7fbaca003c00] coded y,uvDC,uvAC intra: 38.3% 61.5% 12.3% inter: 6.6% 11.3% 0.6%
[libx264 @ 0x7fbaca003c00] i16 v,h,dc,p: 22% 35% 10% 33%
[libx264 @ 0x7fbaca003c00] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 21% 24% 21% 5% 6% 6% 6% 5% 6%
[libx264 @ 0x7fbaca003c00] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 24% 33% 11% 4% 7% 6% 6% 4% 4%
[libx264 @ 0x7fbaca003c00] i8c dc,h,v,p: 43% 30% 20% 7%
[libx264 @ 0x7fbaca003c00] Weighted P-Frames: Y:0.3% UV:0.2%
[libx264 @ 0x7fbaca003c00] ref P L0: 73.5% 9.0% 13.8% 3.7% 0.0%
[libx264 @ 0x7fbaca003c00] ref B L0: 92.4% 6.6% 1.1%
[libx264 @ 0x7fbaca003c00] ref B L1: 97.7% 2.3%
[libx264 @ 0x7fbaca003c00] kb/s:1267.21
[aac @ 0x7fbaca021800] Qavg: 897.576 -
Recording Camlink 4k feed with ffmpeg
5 août 2020, par Nitzan Yogevits my first question ! awesome !
so im new to python, and im working on some program for work
I have the Elgato CamLink 4k connected to Sony A7III.
im looking for the best way to record a video file from the camlink feed using python
I know that ffmpeg is a good way to record webcam feed. but im having trouble with it
here is my code.


import ffmpeg

(
 ffmpeg
 .input('0', format='avfoundation', pix_fmt='nv12', framerate=25)
 .output('test.mp4', pix_fmt='nv12', vframes=125)
 .overwrite_output()
 .run()
)



im using this ffmpeg-python module


im getting a output file with only the first frame and nothing more


here is what im getting in the run terminal


ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
 built with Apple clang version 11.0.3 (clang-1103.0.32.62)
 configuration: --prefix=/usr/local/Cellar/ffmpeg/4.3.1 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libdav1d --enable-libmp3lame --enable-libopus --enable-librav1e --enable-librubberband --enable-libsnappy --enable-libsrt --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --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. 51.100 / 56. 51.100
 libavcodec 58. 91.100 / 58. 91.100
 libavformat 58. 45.100 / 58. 45.100
 libavdevice 58. 10.100 / 58. 10.100
 libavfilter 7. 85.100 / 7. 85.100
 libavresample 4. 0. 0 / 4. 0. 0
 libswscale 5. 7.100 / 5. 7.100
 libswresample 3. 7.100 / 3. 7.100
 libpostproc 55. 7.100 / 55. 7.100
[avfoundation @ 0x7ff043814600] Stream #0: not enough frames to estimate rate; consider increasing probesize
Input #0, avfoundation, from '0':
 Duration: N/A, start: 6247.240967, bitrate: N/A
 Stream #0:0: Video: rawvideo (NV12 / 0x3231564E), nv12, 3840x2160, 1000k tbr, 1000k tbn, 1000k tbc
Stream mapping:
 Stream #0:0 -> #0:0 (rawvideo (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[mp4 @ 0x7ff043856c00] Frame rate very high for a muxer not efficiently supporting it.
Please consider specifying a lower framerate, a different muxer or -vsync 2
[libx264 @ 0x7ff043868000] MB rate (32400000000) > level limit (16711680)
[libx264 @ 0x7ff043868000] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0x7ff043868000] profile High, level 6.2, 4:2:0, 8-bit
[libx264 @ 0x7ff043868000] 264 - core 160 r3011 cde9a93 - H.264/MPEG-4 AVC codec - Copyleft 2003-2020 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=18 lookahead_threads=3 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to 'test.mp4':
 Metadata:
 encoder : Lavf58.45.100
 Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), nv12, 3840x2160, q=-1--1, 1000k fps, 1000k tbn, 1000k tbc
 Metadata:
 encoder : Lavc58.91.100 libx264
 Side data:
 cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: N/A
frame= 125 fps= 30 q=-1.0 Lsize= 788kB time=00:00:00.00 bitrate=52509528.5kbits/s dup=124 drop=1 speed=2.99e-05x 
video:786kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.290685%
[libx264 @ 0x7ff043868000] frame I:1 Avg QP:19.49 size:588332
[libx264 @ 0x7ff043868000] frame P:31 Avg QP:20.24 size: 4202
[libx264 @ 0x7ff043868000] frame B:93 Avg QP:33.28 size: 922
[libx264 @ 0x7ff043868000] consecutive B-frames: 0.8% 0.0% 0.0% 99.2%
[libx264 @ 0x7ff043868000] mb I I16..4: 2.8% 86.0% 11.3%
[libx264 @ 0x7ff043868000] mb P I16..4: 0.0% 0.0% 0.0% P16..4: 6.9% 0.3% 0.5% 0.0% 0.0% skip:92.3%
[libx264 @ 0x7ff043868000] mb B I16..4: 0.0% 0.0% 0.0% B16..8: 4.4% 0.0% 0.0% direct: 0.0% skip:95.6% L0:19.0% L1:81.0% BI: 0.0%
[libx264 @ 0x7ff043868000] 8x8 transform intra:86.0% inter:88.3%
[libx264 @ 0x7ff043868000] coded y,uvDC,uvAC intra: 93.8% 87.1% 55.6% inter: 0.1% 1.5% 0.0%
[libx264 @ 0x7ff043868000] i16 v,h,dc,p: 9% 10% 9% 72%
[libx264 @ 0x7ff043868000] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 15% 14% 34% 6% 5% 5% 6% 7% 7%
[libx264 @ 0x7ff043868000] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 18% 16% 9% 8% 7% 8% 7% 6%
[libx264 @ 0x7ff043868000] i8c dc,h,v,p: 48% 26% 20% 6%
[libx264 @ 0x7ff043868000] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x7ff043868000] ref P L0: 82.6% 0.1% 14.0% 3.3%
[libx264 @ 0x7ff043868000] ref B L0: 99.8% 0.2% 0.0%
[libx264 @ 0x7ff043868000] ref B L1: 76.2% 23.8%
[libx264 @ 0x7ff043868000] kb/s:51475456.00



if im plugging the camlink off I get a video from my macbook internal camera. so I know this should somehow work


-
FFMpeg - Split Window RTMP - Delay on Second Stream
22 février 2016, par Nick SmitI’m trying to combine two live
RTMP
sources into one split screen output with combined audio. The output is then sent on to a receivingRTMP
server.Using the following command, which uses the same
RTMP
input for both feeds, I’ve managed to get the above working, however the input on the left is delayed by about 2 seconds from the one on the right.ffmpeg -re -i rtmp://myserver.tld/live/stream_key -re -i rtmp://myserver.tld/live/stream_key \
-filter_complex "\
nullsrc=size=1152x720 [base];\
[0:v] crop=576:720 [upperleft];\
[1:v] crop=576:720 [upperright];\
[base][upperleft] overlay=shortest=1 [tmp1];\
[tmp1][upperright] overlay=shortest=1:x=576;\
[0:a][1:a]amix \
" -c:a libfdk_aac -ar 44100 -threads 32 -c:v libx264 -g 50 -preset ultrafast -tune zerolatency -f flv rtmp://myserver.tld/live/new_stream_keyOutput :
ffmpeg version N-76137-gb0bb1dc Copyright (c) 2000-2015 the FFmpeg developers
built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04)
configuration: --prefix=/home/ubuntu/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/home/ubuntu/ffmpeg_build/include --extra-ldflags=-L/home/ubuntu/ffmpeg_build/lib --bindir=/home/ubuntu/bin --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree
libavutil 55. 4.100 / 55. 4.100
libavcodec 57. 7.100 / 57. 7.100
libavformat 57. 8.102 / 57. 8.102
libavdevice 57. 0.100 / 57. 0.100
libavfilter 6. 12.100 / 6. 12.100
libswscale 4. 0.100 / 4. 0.100
libswresample 2. 0.100 / 2. 0.100
libpostproc 54. 0.100 / 54. 0.100
[flv @ 0x3a0e940] video stream discovered after head already parsed
Input #0, flv, from 'rtmp://myserver.tld/live/stream_key':
Metadata:
Server : NGINX RTMP (github.com/arut/nginx-rtmp-module)
displayWidth : 1152
displayHeight : 720
fps : 29
profile :
level :
Duration: 00:00:00.00, start: 5.717000, bitrate: N/A
Stream #0:0: Audio: aac (LC), 48000 Hz, stereo, fltp, 163 kb/s
Stream #0:1: Video: h264 (High), yuv420p, 1152x720, 30.30 fps, 29.97 tbr, 1k tbn, 59.94 tbc
[flv @ 0x3a49e00] video stream discovered after head already parsed
Input #1, flv, from 'rtmp://myserver.tld/live/stream_key':
Metadata:
Server : NGINX RTMP (github.com/arut/nginx-rtmp-module)
displayWidth : 1152
displayHeight : 720
fps : 29
profile :
level :
Duration: 00:00:00.00, start: 9.685000, bitrate: N/A
Stream #1:0: Audio: aac (LC), 48000 Hz, stereo, fltp, 163 kb/s
Stream #1:1: Video: h264 (High), yuv420p, 1152x720, 30.30 fps, 29.97 tbr, 1k tbn, 59.94 tbc
[libx264 @ 0x3a9cd60] Application has requested 32 threads. Using a thread count greater than 16 is not recommended.
[libx264 @ 0x3a9cd60] using SAR=1/1
[libx264 @ 0x3a9cd60] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x3a9cd60] profile Constrained Baseline, level 3.1
[libx264 @ 0x3a9cd60] 264 - core 142 r2389 956c8d8 - H.264/MPEG-4 AVC codec - Copyleft 2003-2014 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=11 lookahead_threads=11 sliced_threads=1 slices=11 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=50 keyint_min=5 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=0
Output #0, flv, to 'rtmp://myserver.tld/live/new_stream_key':
Metadata:
Server : NGINX RTMP (github.com/arut/nginx-rtmp-module)
displayWidth : 1152
displayHeight : 720
fps : 29
profile :
level :
encoder : Lavf57.8.102
Stream #0:0: Video: h264 (libx264) ([7][0][0][0] / 0x0007), yuv420p, 1152x720 [SAR 1:1 DAR 8:5], q=-1--1, 25 fps, 1k tbn, 25 tbc (default)
Metadata:
encoder : Lavc57.7.100 libx264
Stream #0:1: Audio: aac (libfdk_aac) ([10][0][0][0] / 0x000A), 44100 Hz, stereo, s16, 128 kb/s (default)
Metadata:
encoder : Lavc57.7.100 libfdk_aac
Stream mapping:
Stream #0:0 (aac) -> amix:input0
Stream #0:1 (h264) -> crop
Stream #1:0 (aac) -> amix:input1
Stream #1:1 (h264) -> crop
overlay -> Stream #0:0 (libx264)
amix -> Stream #0:1 (libfdk_aac)
Press [q] to stop, [?] for help
[flv @ 0x3a0e940] Thread message queue blocking; consider raising the thread_queue_size option (current value: 512)
frame= 81 fps= 20 q=15.0 size= 674kB time=00:00:03.24 bitrate=1703.3kbits/frame= 102 fps= 22 q=22.0 size= 945kB time=00:00:04.08 bitrate=1896.4kbits/Is there any way to force
FFMpeg
to read bothRTMP
inputs at the same time ?