Recherche avancée

Médias (1)

Mot : - Tags -/ticket

Autres articles (111)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

  • Ajouter des informations spécifiques aux utilisateurs et autres modifications de comportement liées aux auteurs

    12 avril 2011, par

    La manière la plus simple d’ajouter des informations aux auteurs est d’installer le plugin Inscription3. Il permet également de modifier certains comportements liés aux utilisateurs (référez-vous à sa documentation pour plus d’informations).
    Il est également possible d’ajouter des champs aux auteurs en installant les plugins champs extras 2 et Interface pour champs extras.

  • Que fait exactement ce script ?

    18 janvier 2011, par

    Ce script est écrit en bash. Il est donc facilement utilisable sur n’importe quel serveur.
    Il n’est compatible qu’avec une liste de distributions précises (voir Liste des distributions compatibles).
    Installation de dépendances de MediaSPIP
    Son rôle principal est d’installer l’ensemble des dépendances logicielles nécessaires coté serveur à savoir :
    Les outils de base pour pouvoir installer le reste des dépendances Les outils de développements : build-essential (via APT depuis les dépôts officiels) ; (...)

Sur d’autres sites (11116)

  • FFMPEG - Convert MKV to MP4 with all streams (subtitles) and watermark

    24 juillet 2016, par ShinJii

    I spent few hours researching and still have problem...
    I want to convert .mkv file to .mp4 with watermark and subtitles (from mkv).

    I tried few commands but always error or success with watermark without subtitles.
    Here are some commands I tried (not all) :

    Partial Success - some files are converted with subtitles, but I have 153 files that are converted without subtitles... (both from .mkv to .mp4) :

    ffmpeg -i 025.mkv -vf "movie=logovideo2.png [watermark]; [in][watermark] overlay=main_w-overlay_w-10:10,subtitles=025.mkv [out]" 25.mp4

    ffmpeg -i 001.mkv -i logovideo2.png -filter_complex "[0:v][1:v]overlay=0:0,subtitles=001.mkv[out]" -map "[out]" -map 0:a -c:s ass 001.mp4

    Fail - command with error :

    ffmpeg -i 001.mkv -i logovideo2.png -filter_complex "[0:v][1:v]overlay=0:0[out]" -map "[out]" -map 0:a -map 0:s -c:s ass 001.mp4

    CODE (with error) :

    ffmpeg version N-81036-g2b14204 Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 4.8.5 (GCC) 20150623 (Red Hat 4.8.5-4)
     configuration: --prefix=/root/ffmpeg_build --extra-cflags=-I/root/ffmpeg_build/include --extra-ldflags=-L/root/ffmpeg_build/lib --bindir=/root/bin --pkg-config-flags=--static --enable-gpl --enable-nonfree --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libass
     libavutil      55. 28.100 / 55. 28.100
     libavcodec     57. 50.100 / 57. 50.100
     libavformat    57. 42.100 / 57. 42.100
     libavdevice    57.  0.102 / 57.  0.102
     libavfilter     6. 47.100 /  6. 47.100
     libswscale      4.  1.100 /  4.  1.100
     libswresample   2.  1.100 /  2.  1.100
     libpostproc    54.  0.100 / 54.  0.100
    Input #0, matroska,webm, from '001.mkv':
     Metadata:
       title           : DB
       encoder         : libebml v1.2.1 + libmatroska v1.1.1
       creation_time   : 2011-09-15 16:44:37
     Duration: 00:24:39.37, start: 0.000000, bitrate: 1429 kb/s
       Stream #0:0(jpn): Audio: vorbis, 48000 Hz, stereo, fltp (default)
       Stream #0:1: Video: h264 (High), yuv420p, 720x540 [SAR 1:1 DAR 4:3], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
       Stream #0:2(pol): Subtitle: ass (default)
       Metadata:
         title           : Grupa
    Input #1, png_pipe, from 'logovideo2.png':
     Duration: N/A, bitrate: N/A
       Stream #1:0: Video: png, rgba(pc), 235x50 [SAR 2835:2835 DAR 47:10], 25 tbr, 25 tbn, 25 tbc
    File '001.mp4' already exists. Overwrite ? [y/N] y
    [libx264 @ 0x43c7a80] using SAR=1/1
    [libx264 @ 0x43c7a80] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
    [libx264 @ 0x43c7a80] profile High, level 3.0
    [libx264 @ 0x43c7a80] 264 - core 148 r2 3f5ed56 - 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=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=23 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
    **[mp4 @ 0x442c9e0] Using AVStream.codec to pass codec parameters to muxers is deprecated, use AVStream.codecpar instead.
       Last message repeated 2 times
    [mp4 @ 0x442c9e0] Could not find tag for codec ass in stream #2, codec not currently supported in container**
    Output #0, mp4, to '001.mp4':
     Metadata:
       title           : DB
       encoder         : Lavf57.42.100
       Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 720x540 [SAR 1:1 DAR 4:3], q=-1--1, 23.98 fps, 24k tbn, 23.98 tbc (default)
       Metadata:
         encoder         : Lavc57.50.100 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
       Stream #0:1(jpn): Audio: aac (LC) ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
       Metadata:
         encoder         : Lavc57.50.100 aac
       Stream #0:2(pol): Subtitle: ass (default)
       Metadata:
         title           : Grupa
         encoder         : Lavc57.50.100 ass
    Stream mapping:
     Stream #0:1 (h264) -> overlay:main (graph 0)
     Stream #1:0 (png) -> overlay:overlay (graph 0)
     overlay (graph 0) -> Stream #0:0 (libx264)
     Stream #0:0 -> #0:1 (vorbis (native) -> aac (native))
     Stream #0:2 -> #0:2 (ass (ssa) -> ass (native))
    **Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument**
    [aac @ 0x43bf600] Qavg: -nan
  • FFmpeg first frame byte size over 2x size compared to all other frames - w/ 100% keyframes

    22 juillet 2016, par Dustin Kerstein

    I’m encoding an h264 mp4 and am having a small issue with the output byte size of the first frame vs. all other frames. There’s no frame duplication happening, rather just that the first frame always ends up being 2x the byte size of other frames. My use-case requires that the first frame be very similar in size compared to other frame.

    Here are the ffmpeg encoding parameters :

    ffmpeg -framerate 60 -i "C:\Test%4d.jpg" -c:v libx264 -g 1 -vf "scale=3840:2160" -crf 19 -pix_fmt yuv420p C:\Test.mp4

    And the frame details using ffprobe :

    ffprobe C:\Test.mp4 -show_frames -of compact -show_entries frame=pict_type,pkt_size

    ffprobe version N-79143-g8ff0f6a Copyright (c) 2007-2016 the FFmpeg developers
     built with gcc 5.3.0 (GCC)
     configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libdcadec --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmfx --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-decklink --enable-zlib
     libavutil      55. 19.100 / 55. 19.100
     libavcodec     57. 30.100 / 57. 30.100
     libavformat    57. 29.101 / 57. 29.101
     libavdevice    57.  0.101 / 57.  0.101
     libavfilter     6. 40.102 /  6. 40.102
     libswscale      4.  0.100 /  4.  0.100
     libswresample   2.  0.101 /  2.  0.101
     libpostproc    54.  0.100 / 54.  0.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'C:\users\dusti\downloads\Test.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf57.29.101
     Duration: 00:00:00.17, start: 0.000000, bitrate: 240225 kb/s
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 3840x2160 [SAR 9:16 DAR 1:1], 240662 kb/s, 60 fps, 60 tbr, 15360 tbn, 120 tbc (default)
       Metadata:
         handler_name    : VideoHandler
    frame|pkt_size=1377043|pict_type=I
    frame|pkt_size=406953|pict_type=I
    frame|pkt_size=407200|pict_type=I
    frame|pkt_size=406647|pict_type=I
    frame|pkt_size=405276|pict_type=I
    frame|pkt_size=404715|pict_type=I
    frame|pkt_size=403226|pict_type=I
    frame|pkt_size=401806|pict_type=I
    frame|pkt_size=400750|pict_type=I
    frame|pkt_size=400189|pict_type=I

    I’ve confirmed that it’s not just a reporting issue with ffprobe by converting the file with mp4box :

    mp4box.exe -dash 16.666 -frag 16.666 -rap c:\Test.mp4

    Which returns an MPD file :

    <initialization range="0-922"></initialization>
         <segmenturl mediarange="923-1378146" indexrange="923-966"></segmenturl>
         <segmenturl mediarange="1378147-1785280" indexrange="1378147-1378190"></segmenturl>
         <segmenturl mediarange="1785281-2192661" indexrange="1785281-1785324"></segmenturl>
         <segmenturl mediarange="2192662-2599489" indexrange="2192662-2192705"></segmenturl>
         <segmenturl mediarange="2599490-3004946" indexrange="2599490-2599533"></segmenturl>
         <segmenturl mediarange="3004947-3409842" indexrange="3004947-3004990"></segmenturl>
         <segmenturl mediarange="3409843-3813249" indexrange="3409843-3409886"></segmenturl>
         <segmenturl mediarange="3813250-4215236" indexrange="3813250-3813293"></segmenturl>
         <segmenturl mediarange="4215237-4616167" indexrange="4215237-4215280"></segmenturl>
         <segmenturl mediarange="4616168-5016537" indexrange="4616168-4616211"></segmenturl>
       

    I tried encoding a dummy black frame and it does seem to work around the issue but I’d really prefer to not do that. Here are the frame sizes with the first frame replaced by a pure black frame :

    frame|pkt_size=2173|pict_type=I
    frame|pkt_size=466255|pict_type=I
    frame|pkt_size=430179|pict_type=I
    frame|pkt_size=416652|pict_type=I
    frame|pkt_size=411401|pict_type=I
    frame|pkt_size=407174|pict_type=I
    frame|pkt_size=405377|pict_type=I
    frame|pkt_size=403207|pict_type=I
    frame|pkt_size=401588|pict_type=I
    frame|pkt_size=401200|pict_type=I

    Anyone have any clues on how to control this behavior ? I imagine it might have something to do with the CRF quality algorithm but really have no idea. Any help would be appreciated.

    Thanks,
    Dustin

    Update 7/22/16
    Upon a little more digging I can see that ffmpeg is using a lower QP for the first frame :

    [libx264 @ 05380b60] frame=   0 QP=14.92 NAL=3 Slice:I Poc:0   I:32400 P:0    SKIP:0    size=1485053 bytes
    [libx264 @ 05380b60] frame=   1 QP=29.48 NAL=3 Slice:I Poc:0   I:32400 P:0    SKIP:0    size=361196 bytes
    [libx264 @ 05380b60] frame=   2 QP=29.48 NAL=3 Slice:I Poc:0   I:32400 P:0    SKIP:0    size=359406 bytes

    But I’ve still not found a way to avoid this behavior. I tried setting qpmin/qpmax to non-default values but that didn’t change anything. Per my comment below, two-pass encoding does not exhibit this behavior. Still looking for a way to use CRF encoding without this large initial frame.

  • Adding the Transform video filter to ffmpeg

    1er août 2016, par aaeim

    first off I’m new to ffmpeg, and stackoverflow. so sorry If I’m doing something wrong.

    Earlier I commented on a post related to this but it got deleted because it was not an answer or something. So I’m asking my own question here.

    I followed this instructions https://trac.ffmpeg.org/wiki/CompilationGuide/Ubuntu

    up untill Unzipping the ffmpeg file. Then I followed the facebook instructions

    1. Checkout the source for ffmpeg
    2. Copy vf_transform.c to the libavfilter subdirectory in ffmpeg source
    3. Edit libavfilter/allfilters.c and register the filter by adding the line : REGISTER_FILTER(TRANSFORM, transform, vf) ; in the video filter registration section
    4. Edit libavfilter/Makefile and add the filter to adding the line : OBJS-$(CONFIG_TRANSFORM_FILTER) += vf_transform.o in the filter section
    5. Configure and build ffmpeg as usual

    and finally I ran the remaining instructions from the compilation guide.

    I did the whole process a couple times but The result is always the same when I try to test.

    ffmpeg version N-80901-gfebc862 Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04.3)
     configuration: --extra-libs=-ldl --prefix=/opt/ffmpeg --mandir=/usr/share/man --enable-avresample --disable-debug --enable-nonfree --enable-gpl --enable-version3 --enable-libopencore-amrnb --enable-libopencore-amrwb --disable-decoder=amrnb --disable-decoder=amrwb --enable-libpulse --enable-libfreetype --enable-gnutls --enable-libx264 --enable-libx265 --enable-libfdk-aac --enable-libvorbis --enable-libmp3lame --enable-libopus --enable-libvpx --enable-libspeex --enable-libass --enable-avisynth --enable-libsoxr --enable-libxvid --enable-libvidstab
     libavutil      55. 28.100 / 55. 28.100
     libavcodec     57. 48.101 / 57. 48.101
     libavformat    57. 41.100 / 57. 41.100
     libavdevice    57.  0.102 / 57.  0.102
     libavfilter     6. 47.100 /  6. 47.100
     libavresample   3.  0.  0 /  3.  0.  0
     libswscale      4.  1.100 /  4.  1.100
     libswresample   2.  1.100 /  2.  1.100
     libpostproc    54.  0.100 / 54.  0.100
    Unknown filter 'transform'.

    I’m on elementary OS.
    Thx and sorry if the post is all wrong.