Recherche avancée

Médias (91)

Autres articles (9)

  • Emballe Médias : Mettre en ligne simplement des documents

    29 octobre 2010, par

    Le plugin emballe médias a été développé principalement pour la distribution mediaSPIP mais est également utilisé dans d’autres projets proches comme géodiversité par exemple. Plugins nécessaires et compatibles
    Pour fonctionner ce plugin nécessite que d’autres plugins soient installés : CFG Saisies SPIP Bonux Diogène swfupload jqueryui
    D’autres plugins peuvent être utilisés en complément afin d’améliorer ses capacités : Ancres douces Légendes photo_infos spipmotion (...)

  • Contribute to a better visual interface

    13 avril 2011

    MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
    Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

Sur d’autres sites (3048)

  • FFMPEG RTMP not working in my red5pro module on Ubuntu 14.0.4

    24 janvier 2018, par Atul

    This following command not working in my java module (this takes snap from live stream and save it)
    Runtime.getRuntime().exec("ffmpeg -i \"rtmp ://127.0.0.1:1935/live/mytest live=1 timeout=2\" -f image2 -vframes 1 /snaps/testo.jpg") ;

    If I use same command on Ubuntu 14.0.4 console it works. Same command working in my red5pro module on Window but not on Ubuntu.

    When I use
    String[] execStr = "/usr/local/bin/ffmpeg","-i","rtmp ://127.0.0.1:1935/live/mytest","live=1","timeout=2","-f","image2","-vframes","1","/snaps/tt.jpg" ;
    ProcessBuilder pb = new ProcessBuilder("ffmpeg -i rtmp ://localhost/live/mytest live=1 timeout=2 -f image2 -vframes 1 /snaps/testo.jpg") ;

    It always throw stream not found ( in red5pro console)

  • ffmpeg doesn't work when the script is launched by cron - No protocol specified, Cannot open display :0.0

    14 janvier 2024, par a k

    ffmpeg in my script doesn't work when the script is launched by cron of the root

    


    Error : No protocol specified, Cannot open display :0.0

    


    OS : Ubuntu 20.04

    


    #!/bin/bash
log=/var/log/log2/log2.txt

echo ______________ $(date) >> "$log"
echo "$""DISPLAY" "=      "  "$DISPLAY" >> "$log" ;
echo whoami '         ' $(whoami) >> "$log" 
echo pwd '            ' $(pwd) >> "$log" 
echo "$""USER" "=" '        ' "$USER" >> "$log"
echo PATH '           ' "$PATH" >> "$log"
echo which ffmpeg '   ' $(which ffmpeg)>> "$log" 
echo whereis ffmpeg ' ' $(whereis ffmpeg) >> "$log" 
echo "\nls -l /bin/* | grep ffmpeg" '        ' >> "$log"
ls -l /usr/bin/* | grep ffmpeg >> "$log"
echo "ls -l /var/log | grep log2" ' '>> "$log"
ls -l /var/log | grep log2 >> "$log"

ffmpeg -y -f x11grab -s 1366x768 -i :0.0 -r 25 /var/log/log2/test.mp4 -loglevel error 2>>"$log" &

echo "pid ffmpeg ""$""!"" = " "$!" >> "$log" 
sleep 5
kill "$!"
echo exit >> "$log"
exit


    


    When Cron (Cron of the root) launches the script, ffmpeg shows the error "No protocol specified, Cannot open display :0.0"

    


    /var/log/log2/log2.txt :

    


    ______________ ven. 05 mai 2023 04:10:01 CEST
$DISPLAY =       
whoami           root
pwd              /root
$USER =          
PATH             /usr/bin:/bin
which ffmpeg     /usr/bin/ffmpeg
whereis ffmpeg   ffmpeg: /usr/bin/ffmpeg /usr/share/ffmpeg /usr/share/man/man1/ffmpeg.1.gz
ls -l /usr/bin/* | grep ffmpeg  
-rwxr-xr-x 1 root   root      284976 mai   18  2022 /usr/bin/ffmpeg
ls -l /var/log | grep log2  
drwxrwxrwx  2 root              root               4096 mai    5 04:09 log2
pid ffmpeg $! =  74590
No protocol specified
[x11grab @ 0x56244aa06740] Cannot open display :0.0, error 1.
:0.0: Input/output error
exit


    


    When I launch the script manually as a not-root user (with sudo), everything work correctly :

    


    ______________ ven. 05 mai 2023 04:10:47 CEST
$DISPLAY =       :0
whoami           root
pwd              /home/an
$USER =          root
PATH             /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
which ffmpeg     /usr/bin/ffmpeg
whereis ffmpeg   ffmpeg: /usr/bin/ffmpeg /usr/share/ffmpeg /usr/share/man/man1/ffmpeg.1.gz
ls -l /usr/bin/* | grep ffmpeg  
-rwxr-xr-x 1 root   root      284976 mai   18  2022 /usr/bin/ffmpeg
ls -l /var/log | grep log2  
drwxrwxrwx  2 root              root               4096 mai    5 04:09 log2
pid ffmpeg $! =  74618
exit


    


    When I launch the script manually as the root, everything works correctly :

    


    ______________ ven. 05 mai 2023 04:11:27 CEST
$DISPLAY =       :0
whoami           root
pwd              /root
$USER =          root
PATH             /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin
which ffmpeg     /usr/bin/ffmpeg
whereis ffmpeg   ffmpeg: /usr/bin/ffmpeg /usr/share/ffmpeg /usr/share/man/man1/ffmpeg.1.gz
ls -l /usr/bin/* | grep ffmpeg  
-rwxr-xr-x 1 root   root      284976 mai   18  2022 /usr/bin/ffmpeg
ls -l /var/log | grep log2  
drwxrwxrwx  2 root              root               4096 mai    5 04:11 log2
pid ffmpeg $! =  74683
exit


    


    When crontab of an ordinary user launches the script, it works correctly :

    


    $DISPLAY =       
whoami           an
pwd              /home/an
$USER =          
PATH             /usr/bin:/bin
which ffmpeg     /usr/bin/ffmpeg
whereis ffmpeg   ffmpeg: /usr/bin/ffmpeg /usr/share/ffmpeg /usr/share/man/man1/ffmpeg.1.gz
ls -l /usr/bin/* | grep ffmpeg  
-rwxr-xr-x 1 root   root      284976 mai   18  2022 /usr/bin/ffmpeg
ls -l /var/log | grep log2  
drwxrwxrwx  2 root              root               4096 mai    5 05:05 log2
pid ffmpeg $! =  77601
exit


    


    I have tried to put into the script :

    


    export DISPLAY=":0"

    


    export DISPLAY=":0.0"

    


    export DISPLAY=":1"

    


  • Overlaying a large image onto a small video like snapchat

    22 mai 2019, par Tabassum Latif

    I want to add full screen overlay image on different size of video,
    I used ffmpeg it work fine if overlay and video has same scale ratio (same width and height).
    Overlay image squeezed if video height and width size is smaller than overlay image but i want to apply like snap chat video they add black view on top and bottom

    Ffmpeg command is

    String[]{"-y", "-i", filePath, "-i",
               overlayPath,
               "-preset", "ultrafast",
               "-filter_complex",
               "[1][0]scale2ref[i][m];[m][i]overlay[v]", "-map",
               "[v]", "-map", "0:a?", "-ac", "2", output};

    I want following output link is mention below.

    Snapchat output

    My editing result output