Recherche avancée

Médias (91)

Autres articles (90)

  • Mise à jour de la version 0.1 vers 0.2

    24 juin 2013, par

    Explications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
    Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

Sur d’autres sites (11430)

  • Why duration of the mp4 file created with ffmpeg from png files is smaller than expected ?

    17 août 2021, par qwark97

    I'm trying to concatenate a bunch of png files into one mp4 file using ffmpeg. I use following command :

    


    ffmpeg -f concat -i concat.txt -f mp4 out.mp4


    


    The "description file" (concat.txt) looks like this :

    


    file screen_001.png
duration 0.14538311958312988
file screen_002.png
duration 0.11382007598876953
file screen_003.png
duration 2.543360710144043
...
file screen_036.png
duration 0.15303301811218262
file screen_037.png
duration 0.160630464553833
file screen_038.png
duration 3.2751874923706055


    


    Given command works, I'm able to create desired mp4 file. The problem is, the duration of the output file is smaller than sum of the duration lines from concat.txt. I expect mp4 file 22.48s long but I get 19.20s long file.

    


    What am I doing wrong ? Maybe I'm not using some flag I should ? Is it even possible to do what I want ? I'm kind a newbie with ffmpeg and video manipulation at all so any help would be appreciated.

    


    Output of the ffmpeg, maybe will be useful :

    


    root@65181939e08e:/files/tmp# ffmpeg -f concat -i concat.txt -f mp4 out.mp4
ffmpeg version 4.1.6-1~deb10u1 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 8 (Debian 8.3.0-6)
  configuration: --prefix=/usr --extra-version='1~deb10u1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-avresample --disable-filter=resample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librsvg --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libx264 --enable-shared
  libavutil      56. 22.100 / 56. 22.100
  libavcodec     58. 35.100 / 58. 35.100
  libavformat    58. 20.100 / 58. 20.100
  libavdevice    58.  5.100 / 58.  5.100
  libavfilter     7. 40.101 /  7. 40.101
  libavresample   4.  0.  0 /  4.  0.  0
  libswscale      5.  3.100 /  5.  3.100
  libswresample   3.  3.100 /  3.  3.100
  libpostproc    55.  3.100 / 55.  3.100
Input #0, concat, from 'concat.txt':
  Duration: 00:00:22.48, start: 0.000000, bitrate: 0 kb/s
    Stream #0:0: Video: png, rgba(pc), 1366x768, 25 tbr, 25 tbn, 25 tbc
Stream mapping:
  Stream #0:0 -> #0:0 (png (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[libx264 @ 0x5651f1a6e8c0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0x5651f1a6e8c0] profile High 4:4:4 Predictive, level 3.2, 4:4:4 8-bit
[libx264 @ 0x5651f1a6e8c0] 264 - core 155 r2917 0a84d98 - H.264/MPEG-4 AVC codec - Copyleft 2003-2018 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x1:0x111 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=4 threads=12 lookahead_threads=2 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:
    encoder         : Lavf58.20.100
    Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv444p, 1366x768, q=-1--1, 25 fps, 12800 tbn, 25 tbc
    Metadata:
      encoder         : Lavc58.35.100 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
frame=  483 fps=199 q=-1.0 Lsize=     258kB time=00:00:19.20 bitrate= 110.2kbits/s dup=445 drop=0 speed=7.89x    
video:252kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 2.564829%
[libx264 @ 0x5651f1a6e8c0] frame I:5     Avg QP: 7.86  size: 28761
[libx264 @ 0x5651f1a6e8c0] frame P:121   Avg QP:14.58  size:   729
[libx264 @ 0x5651f1a6e8c0] frame B:357   Avg QP:13.34  size:    70
[libx264 @ 0x5651f1a6e8c0] consecutive B-frames:  1.2%  0.0%  1.9% 96.9%
[libx264 @ 0x5651f1a6e8c0] mb I  I16..4: 88.2%  0.0% 11.8%
[libx264 @ 0x5651f1a6e8c0] mb P  I16..4:  1.3%  0.0%  0.3%  P16..4:  0.2%  0.0%  0.0%  0.0%  0.0%    skip:98.1%
[libx264 @ 0x5651f1a6e8c0] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  0.9%  0.0%  0.0%  direct: 0.0%  skip:99.1%  L0:59.4% L1:40.6% BI: 0.0%
[libx264 @ 0x5651f1a6e8c0] coded y,u,v intra: 7.9% 0.7% 1.3% inter: 0.0% 0.0% 0.0%
[libx264 @ 0x5651f1a6e8c0] i16 v,h,dc,p: 81% 18%  1%  0%
[libx264 @ 0x5651f1a6e8c0] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 33% 28% 22%  2%  3%  3%  3%  3%  3%
[libx264 @ 0x5651f1a6e8c0] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x5651f1a6e8c0] ref P L0: 72.5% 11.9% 12.4%  3.1%
[libx264 @ 0x5651f1a6e8c0] ref B L0: 50.4% 48.1%  1.4%
[libx264 @ 0x5651f1a6e8c0] ref B L1: 98.9%  1.1%
[libx264 @ 0x5651f1a6e8c0] kb/s:106.45


    


    Thanks for your help !

    


  • ffmpeg Produces unplayable MP4 File From avi files

    25 août 2021, par Manngo

    A have a hand full of .avi files which I would like to convert to .mp4. Cobbling together everything I have found on the Internet, I end up with something like this :

    


    ffmpeg -i something.avi -c:v copy -c:a copy something.mp4


    


    What I get is playable on VLC player, but, of course, that will play anything I through at it. However, I cannot play it using QuickLook in the Finder or with the QuickTime player.

    


    In some cases I get video, but no sound. In some other cases I get garbled video.

    


    I am guessing that the audio or video codec inside the .avi file is incompatible with MacOS, and that the copy instruction above is not appropriate. In that case I guess that I would actually need to reencode the audio or video.

    


    If this sounds incoherent, I admit I know very little about video files.

    


    What would be the best settings to try to produce an MP4 which works natively on MacOS ?

    


  • Download multiple files with ffmpeg, keep one stream from each (according to default stream selection), and then mux them into single file ?

    23 août 2021, par Bernard

    With ffmpeg, I can download m3u8 streams with the following command :

    


    ffmpeg -i http://example.com/test.m3u8 -c copy output.mp4


    


    The above command will keep the best quality video and audio (to some definition of 'best').

    


    However, I'm faced with a situation where I have several m3u8 streams, all of them possibly containing zero or more video or audio streams. I would like to take at most one video and audio from each url (according to ffmpeg's definition of 'best'), and mux them together into the final mp4 file.

    


    This is essentially what I want :

    


    ffmpeg -i http://example.com/test0.m3u8 -c copy output0.mp4
ffmpeg -i http://example.com/test1.m3u8 -c copy output1.mp4
ffmpeg -i http://example.com/test2.m3u8 -c copy output2.mp4
ffmpeg -i output0.mp4 -i output1.mp4 -i output2.mp4 -map 0 -map 1 -map 2 -c copy output.mp4


    


    Is there any way to do it without the temporary files ?