Recherche avancée

Médias (0)

Mot : - Tags -/images

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (53)

  • Amélioration de la version de base

    13 septembre 2013

    Jolie 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 (...)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

  • Le plugin : Gestion de la mutualisation

    2 mars 2010, par

    Le plugin de Gestion de mutualisation permet de gérer les différents canaux de mediaspip depuis un site maître. Il a pour but de fournir une solution pure SPIP afin de remplacer cette ancienne solution.
    Installation basique
    On installe les fichiers de SPIP sur le serveur.
    On ajoute ensuite le plugin "mutualisation" à la racine du site comme décrit ici.
    On customise le fichier mes_options.php central comme on le souhaite. Voilà pour l’exemple celui de la plateforme mediaspip.net :
    < ?php (...)

Sur d’autres sites (2956)

  • How to add BGM when pipe opencv images to ffmpeg - python

    23 mars 2020, par karobben

    Basically, I know how to stream by Pipe opencv to ffmpeg using python.
    But my problem is I can’t add an audio file (BGM) for it. Does anyone know how to make it with python ?

    my python code is :

    import cv2 as cv
    import subprocess as sp

    # ffmpeg command

    command = ['ffmpeg',
           #'-re', '-stream_loop', '-1',
           #'-i', '/home/pi/scrpt/Blive/StarBucks_BGN.mp3',
           '-y',
           '-f', 'rawvideo',
           '-vcodec','rawvideo',
           '-pix_fmt', 'bgr24',
           '-s', "{}x{}".format(width, height),
           '-r', str(fps),
           '-i', '-',
           '-c:v', 'libx264',
           '-pix_fmt', 'yuv420p',
           '-preset', 'ultrafast',
           '-f', 'flv',
           rtmpUrl]

    I know that I can achieve this by :

    sudo raspivid -o - -t 0 -w 1280 -h 720 -fps 24 -b 1000000 |
                   ffmpeg  -re -stream_loop -1 -i  "/home/pi/scrpt/Blive/StarBucks_BGN.mp3" \
           -f h264 -i - -vcodec copy -r 30 -acodec aac -b:a 100k -preset ultrafast \
           -tune zerolatency -f flv "rtmp://"

    So, I tried to add -re -stream_loop -1 -i  "/home/pi/scrpt/Blive/StarBucks_BGN.mp3" into the python pipe, but it crashed with :

    [libx264 @ 0x1952aa0] using cpu capabilities: ARMv6 NEON
    [libx264 @ 0x1952aa0] profile Constrained Baseline, level 3.1
    [libx264 @ 0x1952aa0] 264 - core 148 r2748 97eaef2 - H.264/MPEG-4 AVC codec - Copyleft 2003-2016 - 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=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 keyint_min=25 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
    [flv @ 0x1951d00] FLV does not support sample rate 48000, choose from (44100, 22050, 11025)
    [flv @ 0x1951d00] Audio codec mp3 not compatible with flv
    Could not write header for output file #0 (incorrect codec parameters ?): Function not implementedStream mapping:
     Stream #1:0 -> #0:0 (rawvideo (native) -> h264 (libx264))
     Stream #0:0 -> #0:1 (mp3 (native) -> mp3 (libmp3lame))
       Last message repeated 1 times
    Traceback (most recent call last):
     File "With_BG.py", line 57, in <module>
       p.stdin.write(BG.tostring())
    BrokenPipeError: [Errno 32] Broken pipe
    </module>
  • ffmpeg stream segmenting loses some frames after initialization

    17 février 2020, par zerociudo

    I use this ffmep command to get stream from usb camera and segment videos of 1 seconds

    ffmpeg -i /dev/video0 -pix_fmt yuv420p -vcodec libx264 \
                     -r 15 -x264opts keyint=15:min-keyint=15 -crf 19 \
                     -vf drawtext='expansion=strftime:fontfile='/usr/share/fonts/cantarell/Cantarell-Light.otf':fontsize=28:fontcolor=white:shadowcolor=black:shadowx=2:shadowy=1:text='%Y-%m-%d\ %H\\\\:%m\\\\:%S':x=200:y=200'" \
                     -f segment -reset_timestamps 1 -segment_time 1 -segment_format mp4 \
                     -strftime 1 -map 0 output/%Y-%m-%d-%H:%M:%S.mp4 \

    The output that I get is

    Parsed_drawtext_0 @ 0x5633950a66c0] Using "/usr/share/fonts/truetype/dejavu/DejaVuSans.ttf"
    [Parsed_drawtext_0 @ 0x5633950a66c0] expansion=strftime is deprecated.
    [libx264 @ 0x5633950a1680] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
    [libx264 @ 0x5633950a1680] profile High, level 3.1
    [libx264 @ 0x5633950a1680] 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=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=10 keyint_min=6 scenecut=40 intra_refresh=0 rc_lookahead=10 rc=crf mbtree=1 crf=19.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
    [segment @ 0x56339509fac0] Opening 'output/2020-02-17-13:39:14.mp4' for writing
    Output #0, segment, to 'output/%Y-%m-%d-%H:%M:%S.mp4':
     Metadata:
       encoder         : Lavf58.20.100
       Stream #0:0: Video: h264 (libx264), yuv420p, 1280x720, q=-1--1, 10 fps, 10240 tbn, 10 tbc
       Metadata:
         encoder         : Lavc58.35.100 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
    [segment @ 0x56339509fac0] Opening 'output/2020-02-17-13:39:18.mp4' for writing
    [segment @ 0x56339509fac0] Opening 'output/2020-02-17-13:39:19.mp4' for writing
    [segment @ 0x56339509fac0] Opening 'output/2020-02-17-13:39:20.mp4' for writing

    You can clearly see that first video is output/2020-02-17-13:39:14.mp4, then something happens and the next video is output/2020-02-17-13:39:18.mp4. After this I lose 3 seconds and my whole videos are delayed by 3 seconds.

    Is my command incorrect or is there something else could cause it ?

  • How to solve the incremental delay in ffplay streaming ?

    26 avril 2021, par Nilton Garcia

    Problem : Incremental streaming runtime delay with FFPLAY

    &#xA;

    Question : Is there a way to clear the delay buffer at run time ?

    &#xA;

    I'm using FFPLAY to play an RTP stream. In the first few minutes the delay is constant however, after 1h the delay increases by a few milliseconds generating in the end seconds of delayed increases.

    &#xA;

    I have tested several protocols : SRT, RTP and UDP, RTMP and the behavior is the same with FFPLAY.

    &#xA;

    Command used to play an RTP audio stream :

    &#xA;

    ffplay -max_delay 100000 -flags low_delay -probesize 32 -fflags nobuffer&#x2B;fastseek&#x2B;flush_packets -analyzeduration 0 -protocol_whitelist file,rtp,udp -i audio.sdp -loglevel info -nodisp&#xA;

    &#xA;

    I have tested and made several combinations of flags and so far without success.

    &#xA;

    Arquivo .SDP

    &#xA;

    SDP:&#xA;v=0&#xA;o=- 0 0 IN IP4 10.50.50.14&#xA;s=FONTE DE AUDIO&#xA;c=IN IP4 10.50.50.14&#xA;t=0 0&#xA;a=tool:libavformat 58.29.100&#xA;m=audio 3029 RTP/AVP 127&#xA;b=AS:1536&#xA;a=rtpmap:127 L16/32000/2&#xA;

    &#xA;

    My version FFPLAY

    &#xA;

    ffplay version 4.2.2-0york0~18.04 Copyright (c) 2003-2019 the FFmpeg developers&#xA;  built with gcc 7 (Ubuntu 7.4.0-1ubuntu1~18.04.1)&#xA;  configuration: --prefix=/usr --extra-version=&#x27;0york0~18.04&#x27; --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&#xA;  libavutil      56. 31.100 / 56. 31.100&#xA;  libavcodec     58. 54.100 / 58. 54.100&#xA;  libavformat    58. 29.100 / 58. 29.100&#xA;  libavdevice    58.  8.100 / 58.  8.100&#xA;  libavfilter     7. 57.100 /  7. 57.100&#xA;  libavresample   4.  0.  0 /  4.  0.  0&#xA;  libswscale      5.  5.100 /  5.  5.100&#xA;  libswresample   3.  5.100 /  3.  5.100&#xA;  libpostproc    55.  5.100 / 55.  5.100&#xA;

    &#xA;